I am attempting to use the Core
module in utop
, as originated by Jane Street and installed using opam
.
Here's the problem
utop # open Core.Std;;
Error: Unbound module Core
utop
does not seem to have the path to the Core
module.
How do you specify a path that can be found by utop
to access the Core
module? Is there a utop
init file that specifies library paths ?
I have the same error message from the OCaml 4.01.0 interpreter.
The only way I can avoid this error is actually changing directory to /Users/myname/.opam/system/lib/core
.
I had the same problem, the directions here got it working for me.
https://github.com/realworldocaml/book/wiki/Installation-Instructions#setting-up-and-using-utop
add the following lines to your ~/.ocamlinit file
#use "topfind";;
#thread;;
#camlp4o;;
#require "core.top";;
#require "core.syntax";;
Assuming that you have core properly installed through opam:
# require "core";;
open Core.Std;;
Should work.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With