Skip to content
Snippets Groups Projects
Commit a9b39aaf authored by Wilke Pierre's avatar Wilke Pierre
Browse files

Nouveaux tests pour commentaires multi-lignes (et meilleure regexp)

parent 7e8b34aa
No related branches found
No related tags found
No related merge requests found
...@@ -103,9 +103,11 @@ let list_regexp = ...@@ -103,9 +103,11 @@ let list_regexp =
fun s -> None); fun s -> None);
(Cat(keyword_regexp "/*", (Cat(keyword_regexp "/*",
Cat( Cat(
Star (Alt (char_range (List.filter (fun c -> c <> '*') alphabet), Star (Alt (
Cat (char_regexp '*', char_range (List.filter (fun c -> c <> '*') alphabet),
char_range (List.filter (fun c -> c <> '/') alphabet)))), Cat (Star(char_regexp '*'),
plus(char_range (List.filter (fun c -> c <> '/' && c <> '*') alphabet)))
)),
keyword_regexp "*/")), keyword_regexp "*/")),
fun s -> None); fun s -> None);
(Cat (char_regexp '\'', (Cat (char_regexp '\'',
......
/** /**/
/** Commentaire ! */
main(){
return 23;
}
{"output": "", "error": null, "retval": 23}
\ No newline at end of file
{"output": "", "error": null, "retval": 23}
\ No newline at end of file
main(){
x = 8;
y = 15;
z = 4 * x + y;
return 1;
}
{"output": "", "error": null, "retval": 1}
\ No newline at end of file
{"output": "", "error": null, "retval": 1}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment