[wg-camlp4] getting bitstring to work with Core

Yaron Minsky yminsky at janestreet.com
Mon May 27 19:23:18 BST 2013

The basic issue is that Core is a new library, not an overlay on the
stdlib.  As such, it has its own interface conventions, and so we have
Char.to_int and Char.of_int rather than Char.code and Char.chr.

Hiding unsafe_set and unsafe_get is another issue, and I agree those
can just be shown.  And I don't even mind adding Char.code as a
temporary measure.  But in the end, there should be a way for syntax
extensions to refer to the standard library without confusion.
Namespaces I believe should help here.


On Mon, May 27, 2013 at 9:53 AM, Richard W.M. Jones <rich at annexia.org> wrote:
> On Mon, May 27, 2013 at 11:47:27AM +0100, Anil Madhavapeddy wrote:
>> Core currently hides two functions needed by the Bitstring syntax
>> extension: Char.code and String.unsafe_get.  I'm not sure what the
>> best way to work around this is. Possibilities are:
> I guess, *why* are they hidden?  Bitstring should use both functions
> in a safe way.
> Rich.
> --
> Richard Jones
> Red Hat
> _______________________________________________
> wg-camlp4 mailing list
> wg-camlp4 at lists.ocaml.org
> http://lists.ocaml.org/listinfo/wg-camlp4

More information about the wg-camlp4 mailing list