X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Focaml%2Fmathql_test%2FmQGTopLexer.mll;h=7e69bccf6874f74de08b06dd1444c69668bf32cd;hb=65e3c9976212e04a4678ff9ce9e3c2f436d06d33;hp=cf116641bee81cbbf42b0cc7b009259be19966d9;hpb=48b9bb5e9504aba97cff28a9d7e2797feb42972e;p=helm.git diff --git a/helm/ocaml/mathql_test/mQGTopLexer.mll b/helm/ocaml/mathql_test/mQGTopLexer.mll index cf116641b..7e69bccf6 100644 --- a/helm/ocaml/mathql_test/mQGTopLexer.mll +++ b/helm/ocaml/mathql_test/mQGTopLexer.mll @@ -23,6 +23,9 @@ * http://cs.unibo.it/helm/. *) +(* AUTOR: Ferruccio Guidi + *) + { open MQGTopParser @@ -43,28 +46,26 @@ rule comm_token = parse | ['*' '('] { comm_token lexbuf } | [^ '*' '(']* { comm_token lexbuf } and string_token = parse - | '"' { DQ } - | '\\' _ { STR (String.sub (Lexing.lexeme lexbuf) 1 1) } - | QSTR { STR (Lexing.lexeme lexbuf) } - | eof { EOF } + | '"' { DQ } + | '\\' _ { STR (String.sub (Lexing.lexeme lexbuf) 1 1) } + | QSTR { STR (Lexing.lexeme lexbuf) } + | eof { EOF } and spec_token = parse - | "(*" { comm_token lexbuf; spec_token lexbuf } - | SPC { spec_token lexbuf } - | '"' { let str = qstr string_token lexbuf in - out ("STR " ^ str); STR str } - | '{' { out "LC"; LC } - | '}' { out "RC"; RC } - | ',' { out "CM"; CM } - | '$' { out "DL"; DL } - | "not" { out "NOT" ; NOT } - | "mustobj" { out "MOBJ" ; MOBJ } - | "mustsort" { out "MSORT" ; MSORT } - | "mustrel" { out "MREL" ; MREL } - | "sonlyobj" { out "SOBJ" ; SOBJ } - | "sonlysort" { out "SSORT" ; SSORT } - | "onlyrel" { out "OREL" ; OREL } - | "wonlyobj" { out "WOBJ" ; WOBJ } - | "wonlysort" { out "WSORT" ; WSORT } - | IDEN { let id = Lexing.lexeme lexbuf in - out ("ID " ^ id); ID id } - | eof { EOF } + | "(*" { comm_token lexbuf; spec_token lexbuf } + | SPC { spec_token lexbuf } + | '"' { let str = qstr string_token lexbuf in + out ("STR " ^ str); STR str } + | '{' { out "LC"; LC } + | '}' { out "RC"; RC } + | ',' { out "CM"; CM } + | '$' { out "DL"; DL } + | "mustobj" { out "MOBJ" ; MOBJ } + | "mustsort" { out "MSORT" ; MSORT } + | "mustrel" { out "MREL" ; MREL } + | "onlyobj" { out "OOBJ" ; OOBJ } + | "onlysort" { out "OSORT" ; OSORT } + | "onlyrel" { out "OREL" ; OREL } + | "universe" { out "UNIV" ; UNIV } + | IDEN { let id = Lexing.lexeme lexbuf in + out ("ID " ^ id); ID id } + | eof { EOF }