Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
cduce
cduce
Commits
0746e040
Commit
0746e040
authored
Oct 05, 2007
by
Pietro Abate
Browse files
[r2002-11-17 12:07:57 by cvscast] Empty log message
Original author: cvscast Date: 2002-11-17 12:07:57+00:00
parent
78df84c9
Changes
3
Hide whitespace changes
Inline
Side-by-side
parser/wlexer.ml
View file @
0746e040
...
...
@@ -98,38 +98,41 @@ let lex_tables = {
\005\000\254\255\014\000\013\000\001\000\004\000\253\255\255\255
\
\247\255\246\255\019\000\047\000\051\000\017\000\043\000\250\255
\
\027\000\010\000\001\000\022\000\016\000\249\255\248\255\250\255
\
\058\000\061\000\05
9
\000\06
3
\000\0
71
\000\0
73
\000\08
3
\000\08
1
\000
\
\
067
\000
"
;
\058\000\061\000\05
3
\000\06
5
\000\0
69
\000\0
81
\000\08
5
\000\0
9
8\000
\
\
102\000\074
\000
"
;
Lexing
.
lex_backtrk
=
"
\255\255\255\255\255\255\255\255\255\255\255\255\004\000\255\255
\
\002\000\255\255\004\000\002\000\004\000\004\000\255\255\255\255
\
\255\255\255\255\000\000\001\000\002\000\003\000\005\000\255\255
\
\005\000\005\000\005\000\005\000\005\000\255\255\255\255\255\255
\
\255\255\004\000\
255\255\
003\000\002\000\255\255\001\000\255\255
\
\000\000
"
;
\255\255\004\000\003\000\002\000\255\255\
002\000\
001\000\255\255
\
\001\000
\000\000
"
;
Lexing
.
lex_default
=
"
\023\000\005\000\005\000\005\000\000\000\000\000\255\255\000\000
\
\255\255\000\000\255\255\255\255\255\255\255\255\000\000\000\000
\
\000\000\000\000\255\255\255\255\255\255\255\255\255\255\000\000
\
\255\255\255\255\255\255\255\255\255\255\000\000\000\000\000\000
\
\255\255\255\255\
033\000
\255\255\255\255\
036\000
\255\255\
038\000
\
\255\255
"
;
\255\255\255\255\
255\255
\255\255\255\255\
255\255
\255\255\
255\255
\
\255\255
\255\255
"
;
Lexing
.
lex_trans
=
"
\016\000\017\000\017\000\018\000\019\000\020\000\021\000\019\000
\
\022\000\004\000\008\000\008\000\004\000\024\000\025\000\026\000
\
\027\000\026\000\004\000\011\000\011\000\015\000\04
0
\000\03
5
\000
\
\027\000\026\000\004\000\011\000\011\000\015\000\04
1
\000\03
4
\000
\
\031\000\028\000\012\000\009\000\026\000\031\000\029\000\031\000
\
\029\000\030\000\013\000\009\000\009\000\031\000\031\000\014\000
\
\031\000\014\000\007\000\010\000\009\000\009\000\032\000\033\000
\
\033\000\006\000\007\000\038\000\038\000\038\000\038\000\036\000
\
\036\000\036\000\036\000\255\255\039\000\032\000\033\000\033\000
\
\037\000\033\000\033\000\033\000\033\000\035\000\040\000\000\000
\
\255\255\255\255\034\000\036\000\036\000\036\000\036\000\038\000
\
\000\000\255\255\000\000\036\000\037\000\000\000\255\255\038\000
\
\038\000\038\000\038\000\000\000\000\000\033\000\255\255\000\000
\
\039\000\000\000\000\000\000\000\000\000\000\000\000\000\036\000
\
\033\000\006\000\007\000\038\000\038\000\038\000\038\000\035\000
\
\035\000\035\000\035\000\034\000\039\000\032\000\033\000\033\000
\
\036\000\033\000\033\000\033\000\033\000\035\000\035\000\035\000
\
\035\000\037\000\037\000\037\000\037\000\041\000\036\000\038\000
\
\000\000\000\000\000\000\035\000\000\000\037\000\037\000\037\000
\
\037\000\038\000\038\000\038\000\038\000\033\000\036\000\000\000
\
\000\000\035\000\039\000\000\000\000\000\037\000\040\000\040\000
\
\040\000\040\000\040\000\040\000\040\000\040\000\000\000\000\000
\
\000\000\037\000\000\000\039\000\000\000\038\000\000\000\000\000
\
\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000
\
\000\000\000\000\000\000\038\000\000\000
"
;
\000\000\000\000\040\000\000\000\000\000\000\000\040\000\000\000
\
"
;
Lexing
.
lex_check
=
"
\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000
\
\000\000\001\000\006\000\008\000\002\000\000\000\000\000\000\000
\
...
...
@@ -139,13 +142,16 @@ let lex_tables = {
\024\000\001\000\002\000\002\000\010\000\010\000\022\000\022\000
\
\022\000\003\000\003\000\019\000\019\000\019\000\019\000\020\000
\
\020\000\020\000\020\000\034\000\019\000\032\000\032\000\032\000
\
\020\000\033\000\033\000\033\000\033\000\035\000\040\000\255\255
\
\034\000\037\000\033\000\036\000\036\000\036\000\036\000\019\000
\
\255\255\039\000\255\255\020\000\036\000\255\255\037\000\038\000
\
\038\000\038\000\038\000\255\255\255\255\033\000\039\000\255\255
\
\038\000\255\255\255\255\255\255\255\255\255\255\255\255\036\000
\
\020\000\033\000\033\000\033\000\033\000\035\000\035\000\035\000
\
\035\000\036\000\036\000\036\000\036\000\041\000\035\000\019\000
\
\255\255\255\255\255\255\020\000\255\255\037\000\037\000\037\000
\
\037\000\038\000\038\000\038\000\038\000\033\000\037\000\255\255
\
\255\255\035\000\038\000\255\255\255\255\036\000\039\000\039\000
\
\039\000\039\000\040\000\040\000\040\000\040\000\255\255\255\255
\
\255\255\037\000\255\255\040\000\255\255\038\000\255\255\255\255
\
\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255\255
\
\255\255\255\255\255\255\038\000\255\255
"
\255\255\255\255\039\000\255\255\255\255\255\255\040\000\255\255
\
"
}
let
rec
token
engine
lexbuf
=
...
...
@@ -155,13 +161,13 @@ let rec token engine lexbuf =
token
engine
lexbuf
)
|
1
->
(
#
45
"parser/wlexer.mll"
let
s
=
Lexing
.
lexeme
lexbuf
in
if
Hashtbl
.
mem
keywords
s
then
""
,
s
else
"LIDENT"
,
s
)
|
2
->
(
#
49
"parser/wlexer.mll"
"UIDENT"
,
Lexing
.
lexeme
lexbuf
)
"UIDENT"
,
Lexing
.
lexeme
lexbuf
)
|
3
->
(
#
50
"parser/wlexer.mll"
"INT"
,
Lexing
.
lexeme
lexbuf
)
...
...
parser/wlexer.mll
View file @
0746e040
...
...
@@ -38,15 +38,15 @@ classes
}
let
identchar
=
lowercase
|
uppercase
|
ascii_digit
|
'
_'
|
'\''
|
'
:
'
[
^
'
:
'
]
let
identchar
=
lowercase
|
uppercase
|
ascii_digit
|
'
_'
|
'\''
rule
token
=
parse
blank
+
{
token
engine
lexbuf
}
|
(
lowercase
|
'
_'
)
identchar
*
{
|
(
lowercase
|
'
_'
)
identchar
*
(
'
:
'
identchar
+
)
*
{
let
s
=
Lexing
.
lexeme
lexbuf
in
if
Hashtbl
.
mem
keywords
s
then
""
,
s
else
"LIDENT"
,
s
}
|
uppercase
identchar
*
{
"UIDENT"
,
Lexing
.
lexeme
lexbuf
}
|
uppercase
identchar
*
(
'
:
'
identchar
+
)
*
{
"UIDENT"
,
Lexing
.
lexeme
lexbuf
}
|
ascii_digit
+
{
"INT"
,
Lexing
.
lexeme
lexbuf
}
|
"<"
blank
*
(
lowercase
|
uppercase
)
identchar
*
{
let
s
=
Lexing
.
lexeme
lexbuf
in
...
...
tests/stress_opt_arg.cd
View file @
0746e040
...
...
@@ -11,24 +11,24 @@ type T =
debug compile Any T;;
*)
debug compile T
({ a = a } | ( a:= `B)) &
({ b = b } | ( b:= `B)) &
({ c = c } | ( c:= `B)) &
({ d = d } | ( d:= `B)) &
({ e = e } | ( e:= `B))
(*
&
({ f = f } | ( f:= `B)) &
({ g = g } | ( g:= `B)) &
({ h = h } | ( h:= `B)) &
({ i = i } | ( i:= `B)) &
({ j = j } | ( j:= `B)) &
({ k = k } | ( k:= `B)) &
({ l = l } | ( l:= `B)) &
({ m = m } | ( m:= `B)) &
({ n = n } | ( n:= `B)) &
({ o = o } | ( o:= `B)) &
({ p = p } | ( p:= `B)) &
({ q = q } | ( q:= `B)) &
({ r = r } | ( r:= `B))
*)
({ a = a } | ( a
:= `B)) &
({ b = b } | ( b
:= `B)) &
({ c = c } | ( c
:= `B)) &
({ d = d } | ( d
:= `B)) &
({ e = e } | ( e
:= `B)) &
({ f = f } | ( f
:= `B)) &
({ g = g } | ( g
:= `B)) &
({ h = h } | ( h
:= `B)) &
({ i = i } | ( i
:= `B)) &
(*
({ j = j } | ( j
:= `B)) &
({ k = k } | ( k
:= `B)) &
({ l = l } | ( l
:= `B)) &
({ m = m } | ( m
:= `B)) &
({ n = n } | ( n
:= `B)) &
({ o = o } | ( o
:= `B)) &
({ p = p } | ( p
:= `B)) &
({ q = q } | ( q
:= `B)) &
*)
({ r = r } | ( r
:= `B))
;;
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment