Commits

Markus Mottl committed 27ad409

Fixed bin_prot test suite bug related to new Hashtbl implementation in OCaml 4.0

Comments (0)

Files changed (1)

base/bin_prot/lib_test/bin_prot_test.ml

 
         "hashtbl" >::
           (fun () ->
-            let htbl = Hashtbl.create 0 in
             let bindings = List.rev [(42, 3.); (17, 2.); (42, 4.)] in
+            let htbl = Hashtbl.create (List.length bindings) in
             List.iter (fun (k, v) -> Hashtbl.add htbl k v) bindings;
             check_all 28 "hashtbl"
               (Read.bin_read_hashtbl Read.bin_read_int Read.bin_read_float)
               (Write.bin_write_hashtbl Write.bin_write_int Write.bin_write_float)
               [
-                (htbl, "[(42, 3.); (17, 2.); (42., 4.)]", 28);
+                (htbl, "[(42, 3.); (17, 2.); (42, 4.)]", 28);
                 (Hashtbl.create 0, "[]", 1)
               ];
           );
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.