-_

Grammatical restrictions:

Argument Position Prohibited Expression
Argument 1 _×_
_÷_
_mod_
_+_
_-_
-_
«_‡max»
«_‡min»

Definitions:

extended integer's type
Source: /avail/Avail/Foundation/Math
Categories: Mathematics, Integers, Types
Compute and answer the negation of the specified integral type.
Position Name Type Description
Parameters
1 a extended integer's type
Returns extended integer's type The negation of the argument, e.g., the negation of [3..5] is [-5..-3].
number
Source: /avail/Avail/Foundation/Math
Categories: Mathematics, Numbers
Negate the argument. Avail's system dialect has no negative numeric literals, but the associated semantic restriction effectively overcomes this limitation (for literal arguments).
Position Name Type Description
Parameters
1 a number A number.
Returns number The negation of the argument.

Semantic restrictions:

extended integer's type's type
Source: /avail/Avail/Foundation/Math
Strangely, strengthen type-wise negation's own static type. This allows us to use type-wise negation of an integral type like natural number and get back something that is statically of (-∞..-1]'s type.
Type Description
Parameter Types
extended integer's type's type
extended integer's type
Source: /avail/Avail/Foundation/Math
Strengthen negation.
Type Description
Parameter Types
extended integer's type
number's type
Source: /avail/Avail/Foundation/Math
Compute and answer the strongest possible type of the argument. In particular, an instance type will result in a precise answer that has the same force as a literal.
Type Description
Parameter Types
number's type