Name:
fullparentheses
activates, deactivates or inspects the state variable controlling output with full parenthesising
Library names:
void sollya_lib_set_fullparentheses_and_print(sollya_obj_t);
void sollya_lib_set_fullparentheses(sollya_obj_t);
sollya_obj_t sollya_lib_get_fullparentheses();
Parameters:
- activation value represents on or off, i.e. activation or deactivation
Description:
- An assignment fullparentheses = activation value, where activation value
is one of on or off, activates respectively deactivates the output
of expressions with full parenthesising. In full parenthesising mode,
Sollya commands like print, write and the implicit command when an
expression is given at the prompt will output expressions with
parenthesising at all places where it is necessary for expressions
containing infix operators to be parsed back with the same
result. Otherwise parentheses around associative operators are
omitted.
If the assignment fullparentheses = activation value is followed by an
exclamation mark, no message indicating the new state is
displayed. Otherwise the user is informed of the new state of the
global mode by an indication.
Example 1:
> autosimplify = off!;
> fullparentheses = off;
Full parentheses mode has been deactivated.
> print(1 + 2 + 3);
1 + 2 + 3
> fullparentheses = on;
Full parentheses mode has been activated.
> print(1 + 2 + 3);
(1 + 2) + 3
Go back to the list of commands