Re: [Xen-devel] [PATCH RFC] ocaml: Fix compile with ocaml 4.06, use unsafe strings

2018-01-30 Thread Christian Lindig
> On 28. Jan 2018, at 23:44, Michael Young wrote: > >> >> I do not know if caml-stubdom uses any of these files, but it seems to use >> ocaml-3.11.0? >> https://xenbits.xen.org/gitweb/?p=xen.git;a=blob;f=stubdom/configure;h=a7a0c0915440b7b351a7adf4f40c8f9ee8e739ef;hb=refs/heads/staging#l3534

Re: [Xen-devel] [PATCH RFC] ocaml: Fix compile with ocaml 4.06, use unsafe strings

2018-01-28 Thread Michael Young
On Fri, 26 Jan 2018, John Thomson wrote: On Fri, 26 Jan 2018, at 23:16, Christian Lindig wrote: using the -unsafe-string option (introduced in OCaml 4.02) to keep strings mutable to avoid code changes is not going to work in the long run. Okay, NAK my unsafe-string patch. On 26. Jan 2018, at

Re: [Xen-devel] [PATCH RFC] ocaml: Fix compile with ocaml 4.06, use unsafe strings

2018-01-26 Thread John Thomson
On Fri, 26 Jan 2018, at 23:16, Christian Lindig wrote: > using the -unsafe-string option (introduced in OCaml 4.02) to keep > strings mutable to avoid code changes is not going to work in the long > run. Okay, NAK my unsafe-string patch. On 26. Jan 2018, at 09:09, M A Young wrote: > The patch

Re: [Xen-devel] [PATCH RFC] ocaml: Fix compile with ocaml 4.06, use unsafe strings

2018-01-26 Thread Christian Lindig
> On 26. Jan 2018, at 12:00, Wei Liu wrote: > >> >> Reviewed-by: Christian Lindig >> > > Taking the above into consideration, does this tag still stand? Thanks for the clarification. My tag still stands as the code in the patch is IMHO fine. Regarding Andrew’s comment: the bytes type wa

Re: [Xen-devel] [PATCH RFC] ocaml: Fix compile with ocaml 4.06, use unsafe strings

2018-01-26 Thread Wei Liu
On Fri, Jan 26, 2018 at 11:47:34AM +, Christian Lindig wrote: > > > > On 26. Jan 2018, at 11:43, Wei Liu wrote: > > > > On Fri, Jan 26, 2018 at 09:29:20AM +, Christian Lindig wrote: > >> > >> > >>> On 26. Jan 2018, at 09:09, M A Young wrote: > >>> > >>> On Fri, 26 Jan 2018, John Tho

Re: [Xen-devel] [PATCH RFC] ocaml: Fix compile with ocaml 4.06, use unsafe strings

2018-01-26 Thread Christian Lindig
> On 26. Jan 2018, at 11:43, Wei Liu wrote: > > On Fri, Jan 26, 2018 at 09:29:20AM +, Christian Lindig wrote: >> >> >>> On 26. Jan 2018, at 09:09, M A Young wrote: >>> >>> On Fri, 26 Jan 2018, John Thomson wrote: >>> Use autoconf to test if ocaml version >= 4.02 If so, use -u

Re: [Xen-devel] [PATCH RFC] ocaml: Fix compile with ocaml 4.06, use unsafe strings

2018-01-26 Thread Andrew Cooper
On 26/01/18 11:43, Wei Liu wrote: > On Fri, Jan 26, 2018 at 09:29:20AM +, Christian Lindig wrote: >> >>> On 26. Jan 2018, at 09:09, M A Young wrote: >>> >>> On Fri, 26 Jan 2018, John Thomson wrote: >>> Use autoconf to test if ocaml version >= 4.02 If so, use -unsafe-string for ocamlo

Re: [Xen-devel] [PATCH RFC] ocaml: Fix compile with ocaml 4.06, use unsafe strings

2018-01-26 Thread Wei Liu
On Fri, Jan 26, 2018 at 09:29:20AM +, Christian Lindig wrote: > > > > On 26. Jan 2018, at 09:09, M A Young wrote: > > > > On Fri, 26 Jan 2018, John Thomson wrote: > > > >> Use autoconf to test if ocaml version >= 4.02 > >> If so, use -unsafe-string for ocamlopt and ocamlc > >> > >> Bytes

Re: [Xen-devel] [PATCH RFC] ocaml: Fix compile with ocaml 4.06, use unsafe strings

2018-01-26 Thread Christian Lindig
> On 26. Jan 2018, at 09:09, M A Young wrote: > > On Fri, 26 Jan 2018, John Thomson wrote: > >> Use autoconf to test if ocaml version >= 4.02 >> If so, use -unsafe-string for ocamlopt and ocamlc >> >> Bytes & safe-string were introduced in ocaml 4.02 (2015-07-27) >> >> With ocaml 4.06, -safe

Re: [Xen-devel] [PATCH RFC] ocaml: Fix compile with ocaml 4.06, use unsafe strings

2018-01-26 Thread M A Young
On Fri, 26 Jan 2018, John Thomson wrote: > Use autoconf to test if ocaml version >= 4.02 > If so, use -unsafe-string for ocamlopt and ocamlc > > Bytes & safe-string were introduced in ocaml 4.02 (2015-07-27) > > With ocaml 4.06, -safe-string is now default > This separates the types bytes (mutab

[Xen-devel] [PATCH RFC] ocaml: Fix compile with ocaml 4.06, use unsafe strings

2018-01-26 Thread John Thomson
Use autoconf to test if ocaml version >= 4.02 If so, use -unsafe-string for ocamlopt and ocamlc Bytes & safe-string were introduced in ocaml 4.02 (2015-07-27) With ocaml 4.06, -safe-string is now default This separates the types bytes (mutable string) and string ocaml 4.06 throws errors in compi