Closed mars0i closed 3 years ago
I don't remember exactly what printer needs to be installed, but if you just do #require "core.top"
, then Sexp.t
values should be printed as s-expressions.
Yes, that's it. Thanks.
Tried to add to README.org for a PR, but I can't get the =...=
syntax to work right. I don't know what that system is. Here's my attempt, which I had inserted at the end of the paragraph that begins "If you're using ...".
In =utop=, you may need to =#require "core.top"= for s-expressions to display properly.
The #require "core.top"
doesn't display correctly.
(Note the existing text in that paragraph isn't formating Core
and Core.top
correctly within HTML links.)
It's org-mode (it comes from the emacs world). I'll try to get that to work.
OK, thanks much.
I think this probably belongs to the documentation of sexplib rather than ppx_sexp_conv because ppx_sexp_conv makes it relatively clear that it's merely generating values for the type provided by sexplib.
It looks like that further relies on Base.Pretty_printer module, which in turn relies on "core.top", which I have trouble even getting to work. I'll ask around to try to understand the whole story better before I add anything to the doc.
We added breadcrumbs in various places (sexplib, base). See dc124f2d2e646b28c2749e6c427160a5599fadb0 in sexplib and the accompanying commits in base.
The README is very thorough. Thanks. Something that it doesn't explain is how to get sexps to print as sexps in utop, i.e. as lisp-style embedded lists rather than OCaml lists with special sexplib type variants.
My guess is that there's some foo.top pretty-printer that needs to be installed to get outputs to display as they're shown in the README.