Fix deprecation warnings on newer OCaml compiler.