Skip to content

Commit

Permalink
c3.l grammar fixed.
Browse files Browse the repository at this point in the history
  • Loading branch information
lerno committed Oct 14, 2024
1 parent 31cd839 commit f37f176
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion resources/grammar/c3.l
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ HINT {H}(_?{H})*
OINT {O}(_?{O})*
BINT {B}(_?{B})*

%x COMMENT RAW_STRING
%x COMMENT CONTRACT_DOC RAW_STRING

%{
#include <stdio.h>
Expand Down Expand Up @@ -105,6 +105,12 @@ typedef struct {
[/] { }
\n { }
}
"<*" { BEGIN(CONTRACT_DOC); }
<CONTRACT_DOC>{
"*>" { BEGIN(INITIAL); }
"*" { }
[^*]+ { }
}
\/\/.* { }
"any" { return(ANY); }
"anyfault" { return(ANYFAULT); }
Expand Down

0 comments on commit f37f176

Please sign in to comment.