I have library foolib, which works fine in most cases, except when I also load type_conv in a certain way.
I install this library with opam, and load it:
$ utop
# #require "foolib";;
(* no error *)
Adding type_conv causes an error:
# #require "type_conv foolib";;
File "", line 1, characters 0-4:
Error: Parse error: illegal begin of top_phrase
Fatal error: exception Exit
Raised at file "
bytes.ml", line 220, characters 25-34
Furthermore, it depends on exactly when I load type_conv. The following works:
# #require "foolib";;
# #require "type_conv foolib";;
(* no error *)
I also tried loading type_conv, followed by loading the foolib.cma directly, and that also works fine.
The location referred to in the
bytes.ml file isn't helping me much. It is an out-of-bounds error, but I have no idea how one would get there.
Any idea how to debug a problem like this?