java/1866: Array initializer: undefined reference to `LJv0.0'

bryce@albatross.co.nz bryce@albatross.co.nz
Sat Feb 3 22:16:00 GMT 2001


>Number:         1866
>Category:       java
>Synopsis:       Array initializer: undefined reference to `LJv0.0'
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Feb 03 22:16:00 PST 2001
>Closed-Date:
>Last-Modified:
>Originator:     Bryce McKinlay
>Release:        unknown-1.0
>Organization:
>Environment:
gcc version 2.97 20010203 (experimental)
>Description:
The test case below produces the message:

Foo.java(.text+0x24): undefined reference to `LJv0.0'

when compiled with any level of optimization.

However, if Bar exists as a .class file, the problem does
not occur.
>How-To-Repeat:
final class Foo
{
  private int [] pat = 
    {0,0,1,0,0,0,1,0,1,0,1,0,0,0,1,1,0,0,0,1,1,1,1,1,1,1,0,0,0,1,1,0,0,0,1};

  public static void main(String[] args)
  {
  }

  void a()
  {
    double d = Bar.n;
  }
}

final class Bar
{
  static final double n = 0.1197;
}
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the Gcc-bugs mailing list