[armedbear-devel] Adjustable arrays and Java
Theam Yong Chew
senatorzergling at gmail.com
Wed Jul 20 12:44:20 UTC 2011
On 7/20/11, Erik Huelsmann <ehuels at gmail.com> wrote:
[[...]]
> I might have found an interop issue with adjustable arrays. First create
an
>> adjustable array with some "empty unfilled space".
[[...]]
>> CL-USER> (jcall "getText" (jnew "javax.swing.JButton" *arr*))
>> "abcd^@^@^@"
>> CL-USER> (jcall "getText" (jnew "javax.swing.JButton" (copy-seq *arr*)))
>> "abcd"
>>
>> I've hand edited the above -- the ^@ character is actually a #\Null
>> of course.
>>
>
> I think you're right. Could you try this patch to see if that solves your
> issue:
>
> Index: ComplexString.java
> ===================================================================
> --- ComplexString.java (revision 13405)
> +++ ComplexString.java (working copy)
> @@ -330,7 +330,7 @@
> @Override
> public Object javaInstance()
> {
> - return new String(chars());
> + return new String(getStringValue());
> }
>
> @Override
>
>
> If it does, I'll commit and backport to 0.26.1.
>
Yes, this seems to work. Thanks for the rapid response!
Yong.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/armedbear-devel/attachments/20110721/217d51c6/attachment.html>
More information about the armedbear-devel
mailing list