File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -297,6 +297,7 @@ struct caml__roots_block {
297
297
*/
298
298
299
299
#define CAMLparam0 () \
300
+ int caml__missing_CAMLreturn = 0; \
300
301
struct caml__roots_block *caml__frame = Caml_state_field(local_roots)
301
302
302
303
#define CAMLparam1 (x ) \
@@ -456,7 +457,10 @@ struct caml__roots_block {
456
457
CAMLxparamN (x, (size))
457
458
458
459
459
- #define CAMLdrop Caml_state_field(local_roots) = caml__frame
460
+ #define CAMLdrop do { \
461
+ (void)caml__missing_CAMLreturn; \
462
+ Caml_state_field(local_roots) = caml__frame; \
463
+ } while (0)
460
464
461
465
#define CAMLreturn0 do{ \
462
466
CAMLdrop; \
@@ -471,7 +475,7 @@ struct caml__roots_block {
471
475
472
476
#define CAMLreturn (result ) CAMLreturnT(value, result)
473
477
474
- #define CAMLnoreturn ((void) caml__frame)
478
+ #define CAMLnoreturn ((void) caml__missing_CAMLreturn, (void) caml__frame)
475
479
476
480
477
481
/* convenience macro */
You can’t perform that action at this time.
0 commit comments