Hi,
I would like to play with / evaluate the "deriving" library:
http://code.google.com/p/deriving/wiki/Introduction
How can I:
- create a Ocaml top-level where I can play with it?
- compile programs which take advantage of this library?
I am on Fedora 16.
What I have tried is this:
$ sudo yum install ocaml-deriving-devel
$ rlwrap ocaml
# #use "topfind";;
# #require "deriving";;
No such package: %{camlp4} - Required by `deriving'
I am not sure how to proceed.
------------------------------------------------
Concerning linking against this library, I have tried this:
$ cat Main.ml
let s = Show.show<int> 3
$ ocamlc -I +deriving -pp "camlp4of -I `ocamlc -where`/deriving
nums.cma deriving.cma" deriving.cma Main.ml -o main
File "ghost-location", line 7, characters 8--144:
Error: Unbound value Show.show
make: *** [main] Error 2
where "Main.ml" is supposed to be a program that uses syntactic sugar
provided by "deriving" library.
What is the proper way to get things compiled? I have failed to find any
examples.
Thanks in advance for the help.
--
Caml-list mailing list. Subscription management and archives:
https://sympa-roc.inria.fr/wws/info/caml-list
Beginner's list:
http://groups.yahoo.com/group/ocaml_beginners
Bug reports:
http://caml.inria.fr/bin/caml-bugs