Fix for OCaml 4.02 and compatibility with -safe-string