PreviousUpNext

10.5.2  Prefix, postfix, and circumfix operators

Within expressions Mythryl prefix, postfix and circumfix operators bind more tightly than any other syntactic construct in an expression.

The two major predefined prefix operators are unary - and *, which are by default respectiv bound to unary negation and unary dereference:

    linux$ my

    eval:  x = 4;

    4

    eval:  -x;

    -4

    eval:  x = REF 4;

    REF 4

    eval:  *x;

    4

The only Mythryl postfix operator with a default binding is !, bound to factorial:

    linux$ my

    eval:  7!

    5040

There are currently no Mythryl circumfix operators with default bindings.


Comments and suggestions to: bugs@mythryl.org

PreviousUpNext