java/1330: Forward initializer references not checked

bryce@albatross.co.nz bryce@albatross.co.nz
Wed Dec 20 12:25:00 GMT 2000


>Number:         1330
>Category:       java
>Synopsis:       Forward initializer references not checked
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    apbianco
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Dec 20 12:19:05 PST 2000
>Closed-Date:    
>Last-Modified:  
>Originator:     Bryce McKinlay
>Release:        unknown-1.0
>Organization:
>Environment:
any
>Description:
The following code is illegal because initializers are 
are supposed to run in declared order and arn't allowed to 
forward reference each other. gcj does not detect this 
error.

class InitOrder
{
  static int foo = bar;
  static int bar = 5;
}
>How-To-Repeat:
Compile the test case.
>Fix:

>Release-Note:
>Audit-Trail:

Formerly PR gcj/306

>Unformatted:



More information about the Gcc-prs mailing list