:=
x := e
-- assign the value e to the new local variable x
f X := (x) -> (...)
-- install a method for the method function
f
acting on an argument of class X
.
X * Y := (x,y) -> (...)
-- install a method for the operator
*
applied to arguments of classes X
and Y
.
Many other operators are allowed: see operators.
This operator is schizophrenic in its function, as the installation
of a method has global effect if the classes involved are globally known,
as is typically the case, whereas the assignment of a value to a local
variable is never globally known.
Go to main index.
Go to concepts index.