Re: Blobs and IEEE floating point

2016-04-19 Thread mt1957
Hi Timo, Thanks for the code snippets, I can use that too. There is already some code to test endianness see mail from David Warring at my question about Union. Date April 4 2016. Greetings, Marcel On 19/04/16 16:25, Elizabeth Mattijsen wrote: > I’ve been looking at nativecast, but haven’t

Re: Blobs and IEEE floating point

2016-04-19 Thread Timo Paulssen
On 19/04/16 16:25, Elizabeth Mattijsen wrote: I’ve been looking at nativecast, but haven’t been able to find an > example that I could apply to this? > Liz Right! I should have given a working example, or at least mention that CArray would probably be necessary to make this work. Here'

Re: Blobs and IEEE floating point

2016-04-19 Thread Elizabeth Mattijsen
> On 19 Apr 2016, at 12:03, Timo Paulssen wrote: > > On 19/04/16 01:58, Kevin Pye wrote: >> […] >> 2. Write a simple C function to take a pointer to a double and return >> the double, put that into a shared library and then use NativeCall. > >> […] > > > Fortunately, you don't have to use a li

Re: Blobs and IEEE floating point

2016-04-19 Thread Timo Paulssen
On 19/04/16 01:58, Kevin Pye wrote: […] > 2. Write a simple C function to take a pointer to a double and return > the double, put that into a shared library and then use NativeCall. > […] Fortunately, you don't have to use a library with a custom function. You can just use "nativecast" for t

Re: Blobs and IEEE floating point

2016-04-19 Thread Elizabeth Mattijsen
FWIW, I’ll take PR’s for the PackUnpack distribution to make ‘f’ and ‘d’ work :-) > On 19 Apr 2016, at 07:28, JuhiMarcel LangbroekTimmerman > wrote: > > Hi Kevin > > I've made something up for the time being. You can find it in the BSON > module. Look for the file lib/Document.pm6 and the s