[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #44882] java arrays are not automatically conv
From: |
Philip Nienhuis |
Subject: |
[Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types |
Date: |
Fri, 24 Apr 2015 09:39:57 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:36.0) Gecko/20100101 Firefox/36.0 SeaMonkey/2.33 |
Follow-up Comment #16, bug #44882 (project octave):
With a fresh clone incl. the new Java patches I see 8 FAILS with "make
check":
>>>>> processing
/home/philip/devel/octdev/oct40/libinterp/octave-value/ov-java.cc-tst
***** assert (javaMethod ("binarySearch", "java.util.Arrays", uint8 ([90 100
255]), uint8 (255)) < 0)
!!!!! test failed
[java] java.lang.ClassCastException: org.octave.OctaveReference cannot be cast
to java.lang.Byte
***** assert (javaMethod ("binarySearch", "java.util.Arrays", uint8 ([90 100
128]), uint8 (128)) < 0)
!!!!! test failed
[java] java.lang.ClassCastException: org.octave.OctaveReference cannot be cast
to java.lang.Byte
***** assert (javaMethod ("binarySearch", "java.util.Arrays", uint8 ([90 100
127]), uint8 (127)), 2)
!!!!! test failed
[java] java.lang.ClassCastException: org.octave.OctaveReference cannot be cast
to java.lang.Byte
***** assert (javaMethod ("binarySearch", "java.util.Arrays", uint16 ([90 100
128]), uint16 (128)), 2)
!!!!! test failed
[java] java.lang.ClassCastException: org.octave.OctaveReference cannot be cast
to java.lang.Short
***** assert (class (javaObject ("java.lang.Byte", uint8 (1))),
"java.lang.Byte");
!!!!! test failed
[java] java.lang.NoSuchMethodException: java.lang.Byte
***** assert (class (javaObject ("java.lang.Byte", int8 (1))),
"java.lang.Byte");
!!!!! test failed
[java] java.lang.NoSuchMethodException: java.lang.Byte
***** assert (class (javaObject ("java.lang.Short", uint16 (1))),
"java.lang.Short");
!!!!! test failed
[java] java.lang.NoSuchMethodException: java.lang.Short
***** assert (class (javaObject ("java.lang.Short", int16 (1))),
"java.lang.Short");
!!!!! test failed
[java] java.lang.NoSuchMethodException: java.lang.Short
All the Java-based io package spreadsheet I/O code works, however.
As to the last FAIL:
[java] java.lang.NoSuchMethodException: java.lang.Short
it looks like the constructor, doesn't accept any other input than doubles:
>> t = javaObject ("java.lang.Short", int16 (1))
error: [java] java.lang.NoSuchMethodException: java.lang.Short
>> t = javaObject ("java.lang.Short", 1)
t =
<Java object: java.lang.Short>
>> class (t)
ans = java.lang.Short
>> t = javaObject ("java.lang.Short", int8 (1))
error: [java] java.lang.NoSuchMethodException: java.lang.Short
>> t = javaObject ("java.lang.Short", int32 (1))
error: [java] java.lang.NoSuchMethodException: java.lang.Short
>> t = javaObject ("java.lang.Short", double (1))
t =
<Java object: java.lang.Short>
Is there something in the Javadocs outlining what argument types the
constructor of java.lang.Short is supposed to accept? Or is this all related
to conversion code in ov-java.cc / ov-java.h ?
(as you see, while I have written some Java-based code, I'm still a Java n00b
when it comes to the nitty-gritty :-) )
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?44882>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, (continued)
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Mike Miller, 2015/04/20
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Carnë Draug, 2015/04/21
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Philip Nienhuis, 2015/04/22
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Philip Nienhuis, 2015/04/22
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Carnë Draug, 2015/04/22
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Philip Nienhuis, 2015/04/22
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Carnë Draug, 2015/04/23
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Philip Nienhuis, 2015/04/23
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Philip Nienhuis, 2015/04/23
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Carnë Draug, 2015/04/23
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types,
Philip Nienhuis <=
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Carnë Draug, 2015/04/24
- [Octave-bug-tracker] [bug #44882] java arrays are not automatically converted to octave types, Carnë Draug, 2015/04/24