Thread overview
Bug with .length property?
Dec 03, 2007
Mike
Dec 03, 2007
downs
Dec 04, 2007
Mike
December 03, 2007
I've got an array of dictionaries ...

char[][char[]][] temp;

If I now set the length to pre-allocate 4 entries ...

temp.length = 4;

... the program goes into an infinite loop. It doesn't allocate, just uses 50% CPU (one entire core) and doesn't respond anymore. Is this a bug or is there something else wrong?

-Mike
December 03, 2007
Mike wrote:
> I've got an array of dictionaries ...
> 
> char[][char[]][] temp;
> 
> If I now set the length to pre-allocate 4 entries ...
> 
> temp.length = 4;
> 
> ... the program goes into an infinite loop. It doesn't allocate, just uses 50% CPU (one entire core) and doesn't respond anymore. Is this a bug or is there something else wrong?
> 
> -Mike

It's a bug. I've encountered it before, way back. It is caused by AA.init.length being 0, throwing the initialization code into an infinite loop.
 --downs
December 04, 2007
downs Wrote:

> It's a bug. I've encountered it before, way back. It is caused by AA.init.length being 0, throwing the initialization code into an infinite loop.
>  --downs

I see. Good to know that.