Skip to content
Rel
REFERENCE
Keywords and Symbols

Rel Keywords and Symbols

Tables of keywords and other lexical symbols for the Rel language.

Keywords

Keyword Description
and logical conjunction
as introduces a local name for a relation imported from another module
def begins the declaration of a relation
else separates the two branches of a conditional expression
end ends a conditional expression or a module
entity begins the declaration of an entity type (deprecated)
exists the existential quantifier
false boolean constant (the empty relation {})
for an alternative form of relational abstraction
forall the universal quantifier
from a variant of inverse relational abstraction
ic begins the declaration of an integrity constraint
if begins a conditional expression
iff boolean equivalence
implies logical implication
in binds a variable to the elements of a set of singletons
module begins the declaration of a module
not logical negation
or logical disjunction
then separates the condition and the first branch of a conditional expression
true boolean constant (the singleton relation {()})
use begins the list of names imported from another module
where binds variables to sets of values that satisfy a formula
with begins the declaration of imports from another module
xor logical “exclusive or”

General Language

Symbol Operator Name
.dot
splat
,comma
;semicolon
:colon
()parentheses (precedence)
()parentheses (application)
{}curly braces (precedence)
{}curly braces (definitions)
[]square brackets
=equal (definitions)
in
%

string interpolation in string constants

Logical Operations

Symbol Operator Name
or
and
¬not
exists
forall

, ,

xor

,

iff

,

implies
|for
()true
{}false

Data Type Constants

Symbol Data Type
0xUnsigned Integer

., e, E

Floating-point Number
:RelName
Character

, """

String

raw”, raw""",

raw string
%string interpolation

Mathematical Operations

Symbol Operator Name
+add
-subtract
*multiply
/divide
÷trunc_divide
%remainder
×cart
^power
=eq

, !=

neq

, >=

gt_eq

, <=

lt_eq
>gt
<lt
Σsum

Operations on Relations

Symbol Operator Name
union
intersect
proper_superset
proper_subset
superset
subset
++>right_override
<++left_override
:>suffix_join
<:prefix_join

Infix Symbols

User-defined Symbols

, , , , , , , , , , , ,

infix symbols