yallop / ocaml-ctypes

Library for binding to C libraries using pure OCaml
MIT License
369 stars 95 forks source link

Use Sys.opaque_identity to prevent the optimiser moving code across GCs. #683

Closed yallop closed 3 years ago

yallop commented 3 years ago

Fixes #682.

lthls commented 3 years ago

I can confirm that with this patch, the tests pass with the Flambda 2 compiler.

yallop commented 3 years ago

Thank you, @lthis!