mirror of
https://github.com/c-cube/ocaml-containers.git
synced 2025-12-06 03:05:28 -05:00
test: add regression test for #338
This commit is contained in:
parent
e16926fa5f
commit
43701e6726
1 changed files with 21 additions and 0 deletions
|
|
@ -401,3 +401,24 @@ include (Make(struct
|
|||
*)
|
||||
|
||||
let atom s : t = `Atom s
|
||||
|
||||
(* regression for #338 *)
|
||||
(*$R
|
||||
Printexc.record_backtrace true;
|
||||
let cases = [
|
||||
"\"\\256\"";
|
||||
"\"\\722\02622222\\\\\n\r<\\\\\\\\\"\\222222222\\\\\"\"\2032!2222\\\\\"\"";
|
||||
"\"\n\r<\\t\023\n\203\\622222222\\\\\"\"\2032!2222\\\\\"\"";
|
||||
"\"\n\r<@t\023\n\203\\2222D2\n\r22222\01622222222222222222222222\203\\292242\222 2\\\\\">K2";
|
||||
"\"\n\r<\\t\023\n\203\\272222222\\\\\"\"\2032\0042222\\\\\"\"";
|
||||
"\"\023\n\203\\5222\n\r<\\t\023\n\203\\52222222\\\\\"2\\\216\216\216\216\216\\\\\"\216\216\216\216\216\216\216\216\216222222222222222\147";
|
||||
"\"\\722\02622222\\\\\n\r<\\\\\\\\\"\\222222222\\\\\"\"\2032!2222\\\\\"\"";
|
||||
] in
|
||||
cases
|
||||
|> List.iter (fun s ->
|
||||
try ignore (parse_string s);
|
||||
with e ->
|
||||
let st = Printexc.get_backtrace() in
|
||||
print_endline @@ Printexc.to_string e ^ "\n" ^ st;
|
||||
assert false)
|
||||
*)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue