parameters: (self, context=None)
return_statement: return ans._fix(context)
docstring: Returns a copy with the sign switched.
  
          Rounds, if it has reason.
docstring_summary: Returns a copy with the sign switched.
docstring_tokens: Returns a copy with the sign switched .
function: def __neg__(self, context=None):
          """Returns a copy with the sign switched.
  
          Rounds, if it has reason.
          """
          if self._is_special:
              ans = self._check_nans(context=context)
              if ans:
                  return ans
  
          if context is None:
              context = getcontext()
  
          if not self and context.rounding != ROUND_FLOOR:
              # -Decimal('0') is Decimal('0'), not Decimal('-0'), except
              # in ROUND_FLOOR rounding mode.
              ans = self.copy_abs()
          else:
              ans = self.copy_negate()
  
          return ans._fix(context)
function_tokens: def __neg__ ( self , context = None ) : if self . _is_special : ans = self . _check_nans ( context = context ) if ans : return ans if context is None : context = getcontext ( ) if not self and context . rounding != ROUND_FLOOR : # -Decimal('0') is Decimal('0'), not Decimal('-0'), except # in ROUND_FLOOR rounding mode. ans = self . copy_abs ( ) else : ans = self . copy_negate ( ) return ans . _fix ( context )