[ 
https://issues.apache.org/jira/browse/JEXL-144?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13813066#comment-13813066
 ] 

Henri Biestro commented on JEXL-144:
------------------------------------

Hi;
Nice addition!

Just to nitpick, it seems the boolean property isEmptyArrayValue could be 
"removed" since the emptyArrayComponentType is not null only when the other one 
is true (emptyArrayComponentType != null <=> isEmprtyArrayValue == true). I'm 
also wondering if there could be another way (from the JEXL3/Uberspect may be) 
to avoid adding this emptyComponentType in the setter when the property is 
actually not an array...

Btw, I've got many uncommitted JEXL3 modifications (no-one seemed interested in 
JEXL2+ and the release cycle/process was too long/costly for my sole/own 
usage); just let me know if JEXL3 is something you could consider using.
Cheers

> Empty array property setting fails
> ----------------------------------
>
>                 Key: JEXL-144
>                 URL: https://issues.apache.org/jira/browse/JEXL-144
>             Project: Commons JEXL
>          Issue Type: Bug
>            Reporter: Woonsan Ko
>             Fix For: 2.1.2, 3.0
>
>         Attachments: jexl2-empty-array-patch-2.txt, 
> jexl2-empty-array-patch.txt, jexl3-empty-array-patch-2.txt, 
> jexl3-empty-array-patch.txt
>
>
> Suppose a bean has an array property setter method (e.g, public void 
> setStrarr(String []) ).
> If I use an expression like this with an empty array, then it fails with the 
> error message, "inaccessible or unknown property strarr".
>   // example expression
>   bean.strarr = [ ];



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Reply via email to