File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -519,6 +519,23 @@ t ~name:(spf "line %d" __LINE__) (fun () ->
519519 true )
520520;;
521521
522+ t ~name: (spf " line %d" __LINE__) (fun () ->
523+ let l = [ 1 ; 3 ; 10 ; 29 ; 55 ] in
524+ let v = init 120 (fun i -> List. mem i l) in
525+ assert_equal ~printer: (CCFormat. to_string ppli) l (to_sorted_list v);
526+ true )
527+ ;;
528+
529+ q ~name: (spf " line %d" __LINE__)
530+ Q. (small_list small_nat)
531+ (fun l ->
532+ let l = CCList. sort_uniq ~cmp: CCInt. compare l in
533+ let max = 1 + List. fold_left max 0 l in
534+ let v = init max (fun i -> List. mem i l) in
535+ assert_equal ~printer: (CCFormat. to_string ppli) l (to_sorted_list v);
536+ true )
537+ ;;
538+
522539t ~name: (spf " line %d" __LINE__) (fun () ->
523540 let bv = empty () in
524541 flip bv 0 ;
You can’t perform that action at this time.
0 commit comments