[Bug java/18147] Objects in instance initializer blocks are scoped too widely

2007-01-09 Thread tromey at gcc dot gnu dot org
--- Comment #3 from tromey at gcc dot gnu dot org 2007-01-09 20:46 --- All gcj front end bugs have been fixed by the gcj-eclipse branch merge. I'm mass-closing the affected PRs. If you believe one of these was closed in error, please reopen it with a note explaining why. Thanks. -- t

[Bug java/18147] Objects in instance initializer blocks are scoped too widely

2005-01-23 Thread pinskia at gcc dot gnu dot org
-- What|Removed |Added Keywords||rejects-valid Last reconfirmed|2004-10-25 18:49:33 |2005-01-24 00:57:56 date|

[Bug java/18147] Objects in instance initializer blocks are scoped too widely

2004-10-25 Thread tromey at gcc dot gnu dot org
--- Additional Comments From tromey at gcc dot gnu dot org 2004-10-25 18:55 --- As a workaround you can put an extra block inside the instance initializers: {{ Object foo = ... }} The bug here seems to be that gcj chains the statements of each initializer block together when making fin

[Bug java/18147] Objects in instance initializer blocks are scoped too widely

2004-10-25 Thread pinskia at gcc dot gnu dot org
--- Additional Comments From pinskia at gcc dot gnu dot org 2004-10-25 18:49 --- Confirmed, a workaround is to do something like this: import java.util.HashMap; class init { {{ Object foo = new Object();} } { Object foo = new Object(); } } The reduced testcase: import ja