Re: [PATCH v4 01/11] tools/ocaml/libs/{xb, mmap}: use Data_abstract_val wrapper

2022-12-19 Thread Edwin Torok
> On 16 Dec 2022, at 22:40, Andrew Cooper wrote: > > On 16/12/2022 6:25 pm, Edwin Török wrote: >> diff --git a/tools/ocaml/libs/mmap/mmap_stubs.h >> b/tools/ocaml/libs/mmap/mmap_stubs.h >> index 65e4239890..66f18d4406 100644 >> --- a/tools/ocaml/libs/mmap/mmap_stubs.h >> +++ b/tools/ocaml/lib

Re: [PATCH v4 01/11] tools/ocaml/libs/{xb, mmap}: use Data_abstract_val wrapper

2022-12-16 Thread Andrew Cooper
On 16/12/2022 6:25 pm, Edwin Török wrote: > diff --git a/tools/ocaml/libs/mmap/mmap_stubs.h > b/tools/ocaml/libs/mmap/mmap_stubs.h > index 65e4239890..66f18d4406 100644 > --- a/tools/ocaml/libs/mmap/mmap_stubs.h > +++ b/tools/ocaml/libs/mmap/mmap_stubs.h > @@ -30,4 +30,8 @@ struct mmap_interface >

[PATCH v4 01/11] tools/ocaml/libs/{xb, mmap}: use Data_abstract_val wrapper

2022-12-16 Thread Edwin Török
This is not strictly necessary since it is essentially a no-op currently: a cast to void* and value*, even in OCaml 5.0. However it does make it clearer that what we have here is not a regular OCaml value, but one allocated with Abstract_tag or Custom_tag, and follows the example from the manual m