@@ -147,7 +147,7 @@ let%expect_test "wrap_callback_strict" =
147147 (Js.Unsafe. callback_with_arity 2 cb3)
148148 {| (function(f){ return f(1 ,2 ,3 ) }) | };
149149 [% expect {|
150- Result : function#1 #1 | }];
150+ Result : function#1 #undefined | }];
151151 call_and_log
152152 (Js.Unsafe. callback_with_arity 2 cb3)
153153 ~cont: (fun g -> g 4 )
@@ -164,7 +164,7 @@ let%expect_test "wrap_callback_strict" =
164164 Result : 0 | }];
165165 call_and_log (Js.Unsafe. callback_with_arity 2 cb3) {| (function(f){ return f(1 ,2 ) }) | };
166166 [% expect {|
167- Result : function#1 #1 | }]
167+ Result : function#1 #undefined | }]
168168
169169let % expect_test " wrap_callback_strict" =
170170 call_and_log
@@ -291,7 +291,7 @@ let%expect_test "wrap_meth_callback_strict" =
291291 (Js.Unsafe. meth_callback_with_arity 2 cb4)
292292 {| (function(f){ return f.apply(" this" ,[1 ,2 ,3 ]) }) | };
293293 [% expect {|
294- Result : function#1 #1 | }];
294+ Result : function#1 #undefined | }];
295295 call_and_log
296296 (Js.Unsafe. meth_callback_with_arity 2 cb4)
297297 ~cont: (fun g -> g 4 )
@@ -309,7 +309,7 @@ let%expect_test "wrap_meth_callback_strict" =
309309 call_and_log
310310 (Js.Unsafe. meth_callback_with_arity 2 cb4)
311311 {| (function(f){ return f.apply(" this" ,[1 ,2 ]) }) | };
312- [% expect {| Result : function#1 #1 | }]
312+ [% expect {| Result : function#1 #undefined | }]
313313
314314let % expect_test " wrap_meth_callback_strict" =
315315 call_and_log
@@ -338,23 +338,21 @@ let%expect_test "over application, extra arguments are dropped" =
338338 (Js.Unsafe. meth_callback cb4)
339339 {| (function(f){ return f.apply(" this" ,[1 ,2 ,3 ,4 ]) }) | };
340340 [% expect {|
341- got this, 1 , 2 , 3 , done
342- Result : 0 | }]
341+ Result : function#1 #undefined | }]
343342
344343let % expect_test " partial application, extra arguments set to undefined" =
345344 call_and_log
346345 (Js.Unsafe. meth_callback cb4)
347346 {| (function(f){ return f.apply(" this" ,[1 ,2 ]) }) | };
348347 [% expect {|
349- got this, 1 , 2 , undefined, done
350- Result : 0 | }]
348+ Result : function#1 #undefined | }]
351349
352350(* caml_call_gen *)
353351
354352let % expect_test _ =
355353 call_and_log cb3 ~cont: (fun g -> g 1 ) {| (function(f){ return f }) | };
356354 [% expect {|
357- Result : function#2 # 2 | }]
355+ Result : function#1 #undefined | }]
358356
359357let % expect_test _ =
360358 call_and_log cb3 ~cont: (fun g -> g 1 2 3 4 ) {| (function(f){ return f }) | };
@@ -369,7 +367,7 @@ let%expect_test _ =
369367 | _ -> Printf. printf " Error: unknown"
370368 in
371369 f cb5;
372- [% expect {| Result : function#1 #1 | }];
370+ [% expect {| Result : function#1 #undefined | }];
373371 f cb4;
374372 [% expect {|
375373 got 1 , 1 , 2 , 3 , done
@@ -399,10 +397,10 @@ let%expect_test _ =
399397 Result : 0 | }];
400398 f (Obj. magic cb4);
401399 [% expect {|
402- Result : function#1 #1 | }];
400+ Result : function#1 #undefined | }];
403401 f (Obj. magic cb5);
404402 [% expect {|
405- Result : function#2 # 2 | }]
403+ Result : function#1 #undefined | }]
406404
407405let % expect_test _ =
408406 let open Js_of_ocaml in
0 commit comments