Olga Gryshchenko <gryshchenko.olg...@gmail.com> wrote on 12/18/2014
05:49:14 PM:

>
> 1. I'm changing the values assigned to keys this way:
> myMap.put(key1, value1);
> myMap.put(key1, value2);
> Is this the right way of doing it?

Yes.

>
> 2. When I keep putting new keys and respective values in the map at
> some point I get Exception:
> Uncaught exception at place 0: x10.lang.MultipleExceptions
> x10.lang.Exception: Your code has a concurrency bug! You updated the
> hashmap 9 times since you created the iterator.
>
> So I shouldn't update the hashmap? What exactly is the problem in such
case?
>

That looks like some how you are trying to iterate over the map while you
are also updating it.  This isn't allowed (similar to Java).

It is possible you are hitting a bug fixed by Olivier in June 2013 (svn
commit 25693) since X10 2.3.1 dates from March 2013.   His patch is here:
https://sourceforge.net/p/x10/code/25693, maybe you could attempt to apply
this fix to 2.3.1

hope this helps,

--dave
------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk
_______________________________________________
X10-users mailing list
X10-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/x10-users

Reply via email to