OutputFormToolsΒΆ

outform2.spad line 13 [edit on github]

This package implements tools form handling OutputForm

arguments: OutputForm -> List OutputForm

arguments(f) gives arguments of form f. Valid only when atom?(f) is false

atom?: OutputForm -> Boolean

atom?(f) checks if form f is atomic, false means composite

atom_to_string: OutputForm -> String

atom_to_string(f) converts f to string form.

construct: (OutputForm, List OutputForm) -> OutputForm

construct(op, la) creates OutputForm with operator op and arguments la

empty?: OutputForm -> Boolean

empty?(f) checks if form f is empty.

has_op?: (OutputForm, Symbol) -> Boolean

has_op?(f, s) returns true is f is a composite from with operator s, otherwise returns false

integer?: OutputForm -> Boolean

integer?(f) checks if f is an integer, this implies atom?(f)

integer: OutputForm -> Integer

integer(f) gives integer corresponding to f. Valid only when integer?(f) is true

is_symbol?: (OutputForm, Symbol) -> Boolean

is_symbol?(f, s) returns true if form is symbol s, otherwise returns false

operator: OutputForm -> OutputForm

operator(f) gives operator (head) of form f. Valid only when atom?(f) is false

precondition: OutputForm -> OutputForm

precondition(f) prepares form for formatting.

string?: OutputForm -> Boolean

string?(f) checks if f is a string, this implies atom?(f)

string: OutputForm -> String

string(f) gives string corresponding to f. Valid only when string?(f) is true

symbol?: OutputForm -> Boolean

symbol?(f) checks if f is a symbol, this implies atom?(f)

symbol: OutputForm -> Symbol

symbol(f) gives symbol corresponding to f. Valid only when symbol?(f) is true