Module OpamParserTypes
type relop
=[
|
`Eq
|
`Geq
|
`Gt
|
`Leq
|
`Lt
|
`Neq
]
type logop
=[
|
`And
|
`Or
]
type pfxop
=[
|
`Defined
|
`Not
]
type file_name
= string
type pos
= file_name * int * int
type env_update_op
=
|
Eq
|
PlusEq
|
EqPlus
|
ColonEq
|
EqColon
|
EqPlusEq
type value
=
|
Bool of pos * bool
|
Int of pos * int
|
String of pos * string
|
Relop of pos * relop * value * value
|
Prefix_relop of pos * relop * value
|
Logop of pos * logop * value * value
|
Pfxop of pos * pfxop * value
|
Ident of pos * string
|
List of pos * value list
|
Group of pos * value list
|
Option of pos * value * value list
|
Env_binding of pos * value * env_update_op * value
type opamfile_section
=
{
section_kind : string;
section_name : string option;
section_items : opamfile_item list;
}
and opamfile_item
=
|
Section of pos * opamfile_section
|
Variable of pos * string * value
type opamfile
=
{
file_contents : opamfile_item list;
file_name : file_name;
}