I curious as to what version of j64 you are using. Are the COM servers still embedded in j8.02?
On Mon, Aug 18, 2014 at 7:55 AM, bill lam <[email protected]> wrote: > I'm not an expert on C#, but it seems that int is always 4-byte whether on > 32 or 64 bit, so that you propably need int64[] for J64. > On Aug 18, 2014 8:16 PM, <[email protected]> wrote: > > > I have an issue with the 64-bit JDLLServer in relation to 64 integers. It > > seems that JDLLServer handles only the lower 32 bits of a 64 bit value. > The > > following test demonstrates this issue: > > > > Test (C#): > > var value = 1000 + ((Int64)1 << 32); > > _j.Do(String.Format("a =: {0}", value)); > > Assert.AreEqual(value, _j.GetB("a")); > > > > Results: > > Assert.AreEqual failed. Expected:<4294968296 (System.Int64)>. > Actual:<1000 > > (System.Int32)>. > > > > > > There is a similar problem to getting int arrays. The following test > fails: > > > > _j.Do("a =: 10 20 30"); > > > > var a = (int[])_j.GetB("a"); > > Assert.AreEqual(10, a[0]); > > Assert.AreEqual(20, a[1]); > > Assert.AreEqual(30, a[2]); > > > > The result of 'a' is not '10 20 30', but '10 0 20'. I guess, '0' stands > > for the higher 32 bits of the whole value '10 0'. > > > > What can I do to resolve these issues? > > I can not switch to the 32 bit J version, because I work with JD, that > > requires a 64 bit J. > > My current workaround is avoiding integers and only work with floats, but > > this is not a real solution. > > > > Any Ideas? > > > > PS: Sorry for my English :) > > > > ---------------------------------------------------------------------- > > For information about J forums see http://www.jsoftware.com/forums.htm > > > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm > -- John D. Baker [email protected] ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
