Parse Rules
Terms
term
let
rec
let-bindings
in
term
let-bindings
in
term
fun
term
->
term
match
term
with
|
pattern
->
term
|
simple-matching
pattern
->
term
|
simple-matching
function
|
pattern
->
term
|
simple-matching
pattern
->
term
|
simple-matching
try
term
with
|
pattern
->
term
|
simple-matching
pattern
->
term
|
simple-matching
if
term
then
term
else
term
while
term
do
term
done
for
binding
=
term
to
term
do
term
done
downto
term
do
term
done
(
term
)
[
term
]
{
term
}
begin
term
end
term
,
term
;
term
<-
term
==
term
=
term
*
term
mod
term
land
term
lor
term
lxor
term
lsl
term
lsr
term
asr
term
.
(
term
)
term
:
type
operator
term
term
let-bindings
binding
=
term
and
let-bindings
pattern
(
pattern
)
[
pattern
]
pattern
|
pattern
,
pattern
as
ident
operator
pattern
pattern
simple-matching
pattern
->
term
|
simple-matching
Types
type
(
type
type-arguments-tail
)
ident
)
ident
type
->
type
*
type
type
type-arguments-tail
,
type
type-arguments-tail
Definitions
definition
let
rec
let-bindings
let-bindings
type
typedefs
exception
constr-decls
#
ident
term
typedefs
typedef-lhs
typedef-rhs
and
typedefs
constr-decls
constr-decl
|
constr-decls
typedef-lhs
type-params
ident
typedef-rhs
=
variants
{
label-decls
}
==
type
constr-decl
ident
of
type
type-params
typevar
(
typevar
type-params-tail
)
variants
constr-decl
|
variants
label-decls
label-decl
;
label-decls
type-params-tail
,
typevar
type-params-tail
label-decl
label-name
:
type
label-name
ident
mutable
ident