Commit a9b39aaf authored by Wilke Pierre's avatar Wilke Pierre
Browse files

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

parent 7e8b34aa
......@@ -103,9 +103,11 @@ let list_regexp =
fun s -> None);
(Cat(keyword_regexp "/*",
Cat(
Star (Alt (char_range (List.filter (fun c -> c <> '*') alphabet),
Cat (char_regexp '*',
char_range (List.filter (fun c -> c <> '/') alphabet)))),
Star (Alt (
char_range (List.filter (fun c -> c <> '*') alphabet),
Cat (Star(char_regexp '*'),
plus(char_range (List.filter (fun c -> c <> '/' && c <> '*') alphabet)))
)),
keyword_regexp "*/")),
fun s -> None);
(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
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment