blob: 2aeb4b79f8bd32435d372d98fa9da337c51e510d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
|
exception TooMuchRParen
type raw_pos = int * int
type pos = string * int * int
type spaces =
| Space_0
| Space_1
| Space_n
| Space_cr
| Space_none
type context = I_scalar | I_hash | I_array | I_func | I_raw | I_star
type fromparser =
| Undef
| Ident of string option * string * pos
| Num of string * pos
| Raw_string of string * pos
| String of (string * fromparser) list * pos
| Ref of context * fromparser
| Deref of context * fromparser
| Deref_with of context * context * fromparser * fromparser (* from_context, to_context, ref, para *)
| Diamond of fromparser option
| List of fromparser list
| Block of fromparser list
| Call_op of string * fromparser list * pos
| Call of fromparser * fromparser list
| Method_call of fromparser * fromparser * fromparser list
| Anonymous_sub of fromparser * pos
| My_our of string * (context * string) list * pos
| Use of fromparser * fromparser list
| Sub_declaration of fromparser * string * fromparser (* name, prototype, body *)
| Package of fromparser
| Label of string
| Perl_checker_comment of string * pos
| Too_complex
| Semi_colon
type priority =
| P_tok
| P_tight
| P_mul
| P_add
| P_cmp
| P_eq
| P_expr
| P_tight_and
| P_tight_or
| P_ternary
| P_assign
| P_call_no_paren
| P_comma
| P_and
| P_or
| P_loose
| P_paren_wanted of priority
| P_paren of priority
|