JEP 186: Collection Literals

Per Bothner per at bothner.com
Tue Jan 14 14:48:49 PST 2014


On 01/14/2014 02:34 PM, Remi Forax wrote:
> We need new constant pool entries for arrays (like MSIL does), it's
> currently possible to encode arrays as a String (by example by
> uuencoding the values) but it's awkward.
> Then a collection literal can be encoded using invokedynamic.
> By example,
>     int a = ...
>     { 1, 2, a} as ArrayList (or any other syntax :)

>
> can be encoded like this:
>     iload 'a'
>     invokedynamic (int)ArrayList

I don't understand your proposal - it's a bit too vague/incomplete for me.
-- 
	--Per Bothner
per at bothner.com   http://per.bothner.com/


More information about the lambda-dev mailing list