public inbox for java-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug libgcj/16675] New: Null parameter values require explicit cast
@ 2004-07-22 19:47 richardl at redhat dot com
2004-07-22 20:17 ` [Bug java/16675] " mckinlay at redhat dot com
` (6 more replies)
0 siblings, 7 replies; 8+ messages in thread
From: richardl at redhat dot com @ 2004-07-22 19:47 UTC (permalink / raw)
To: java-prs
[richardl@conundrum src]$ rpm -qa | grep gcj
libgcj-3.4.0-7
libgcj-devel-3.4.0-7
The following program fails to compile with gcj:
public class Test {
public Test(Object obj) { }
public void someTestMethod() {
new Test(null) { };
}
public void someTestMethod2() {
new Test((Object) null) { };
}
}
[richardl@conundrum tmp]$ gcj -C Test.java
Test.java: In class `Test':
Test.java: In method `Test.someTestMethod()':
Test.java:4: error: No constructor matching `(Test,void)' found in class `Test'.
public void someTestMethod() {
^
Test.java: In class `Test$1':
Test.java: In constructor `(Test,void)':
Test.java:5: error: Can't find constructor `Test$1(V)' in type `Test$1'.
new Test(null) { };
^
2 errors
This compiles fine with javac. The workaround is to cast the null, as shown in
the second test method.
--
Summary: Null parameter values require explicit cast
Product: gcc
Version: 3.4.0
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: libgcj
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: richardl at redhat dot com
CC: gcc-bugs at gcc dot gnu dot org,java-prs at gcc dot gnu
dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16675
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug java/16675] Null parameter values require explicit cast
2004-07-22 19:47 [Bug libgcj/16675] New: Null parameter values require explicit cast richardl at redhat dot com
@ 2004-07-22 20:17 ` mckinlay at redhat dot com
2004-10-23 20:43 ` [Bug java/16675] Null parameter values for anonymous constructor invocation " pinskia at gcc dot gnu dot org
` (5 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: mckinlay at redhat dot com @ 2004-07-22 20:17 UTC (permalink / raw)
To: java-prs
------- Additional Comments From mckinlay at redhat dot com 2004-07-22 20:17 -------
Confirmed. Compiler bug, so moving to java category.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Component|libgcj |java
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2004-07-22 20:17:04
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16675
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug java/16675] Null parameter values for anonymous constructor invocation require explicit cast
2004-07-22 19:47 [Bug libgcj/16675] New: Null parameter values require explicit cast richardl at redhat dot com
2004-07-22 20:17 ` [Bug java/16675] " mckinlay at redhat dot com
@ 2004-10-23 20:43 ` pinskia at gcc dot gnu dot org
2004-11-11 21:24 ` [Bug java/16675] [4.0 Regression] " pinskia at gcc dot gnu dot org
` (4 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-10-23 20:43 UTC (permalink / raw)
To: java-prs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-10-23 20:43 -------
We now get an ICE on the mainline (which I think can almost considered a regression) :
Test.java: In class 'Test':
Test.java: In method 'Test.someTestMethod()':
Test.java:5: internal compiler error: in mangle_pointer_type, at java/mangle.c:402
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
--
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |ice-on-valid-code
Last reconfirmed|2004-07-22 20:17:04 |2004-10-23 20:43:15
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16675
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug java/16675] [4.0 Regression] Null parameter values for anonymous constructor invocation require explicit cast
2004-07-22 19:47 [Bug libgcj/16675] New: Null parameter values require explicit cast richardl at redhat dot com
2004-07-22 20:17 ` [Bug java/16675] " mckinlay at redhat dot com
2004-10-23 20:43 ` [Bug java/16675] Null parameter values for anonymous constructor invocation " pinskia at gcc dot gnu dot org
@ 2004-11-11 21:24 ` pinskia at gcc dot gnu dot org
2004-12-02 18:11 ` tromey at gcc dot gnu dot org
` (3 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-11-11 21:24 UTC (permalink / raw)
To: java-prs
--
What |Removed |Added
----------------------------------------------------------------------------
Summary|Null parameter values for |[4.0 Regression] Null
|anonymous constructor |parameter values for
|invocation require explicit |anonymous constructor
|cast |invocation require explicit
| |cast
Target Milestone|--- |4.0.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16675
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug java/16675] [4.0 Regression] Null parameter values for anonymous constructor invocation require explicit cast
2004-07-22 19:47 [Bug libgcj/16675] New: Null parameter values require explicit cast richardl at redhat dot com
` (2 preceding siblings ...)
2004-11-11 21:24 ` [Bug java/16675] [4.0 Regression] " pinskia at gcc dot gnu dot org
@ 2004-12-02 18:11 ` tromey at gcc dot gnu dot org
2004-12-02 19:38 ` cvs-commit at gcc dot gnu dot org
` (2 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: tromey at gcc dot gnu dot org @ 2004-12-02 18:11 UTC (permalink / raw)
To: java-prs
------- Additional Comments From tromey at gcc dot gnu dot org 2004-12-02 18:11 -------
I'm testing a patch
--
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |tromey at gcc dot gnu dot
|dot org |org
Status|NEW |ASSIGNED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16675
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug java/16675] [4.0 Regression] Null parameter values for anonymous constructor invocation require explicit cast
2004-07-22 19:47 [Bug libgcj/16675] New: Null parameter values require explicit cast richardl at redhat dot com
` (3 preceding siblings ...)
2004-12-02 18:11 ` tromey at gcc dot gnu dot org
@ 2004-12-02 19:38 ` cvs-commit at gcc dot gnu dot org
2004-12-02 19:41 ` cvs-commit at gcc dot gnu dot org
2004-12-02 19:44 ` tromey at gcc dot gnu dot org
6 siblings, 0 replies; 8+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-12-02 19:38 UTC (permalink / raw)
To: java-prs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2004-12-02 19:38 -------
Subject: Bug 16675
CVSROOT: /cvs/gcc
Module name: gcc
Changes by: tromey@gcc.gnu.org 2004-12-02 19:38:49
Modified files:
libjava : ChangeLog
Added files:
libjava/testsuite/libjava.compile: PR16675.java
Log message:
For PR java/16675:
* testsuite/libjava.compile/PR16675.java: New file.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libjava/ChangeLog.diff?cvsroot=gcc&r1=1.3257&r2=1.3258
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libjava/testsuite/libjava.compile/PR16675.java.diff?cvsroot=gcc&r1=NONE&r2=1.1
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16675
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug java/16675] [4.0 Regression] Null parameter values for anonymous constructor invocation require explicit cast
2004-07-22 19:47 [Bug libgcj/16675] New: Null parameter values require explicit cast richardl at redhat dot com
` (4 preceding siblings ...)
2004-12-02 19:38 ` cvs-commit at gcc dot gnu dot org
@ 2004-12-02 19:41 ` cvs-commit at gcc dot gnu dot org
2004-12-02 19:44 ` tromey at gcc dot gnu dot org
6 siblings, 0 replies; 8+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-12-02 19:41 UTC (permalink / raw)
To: java-prs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2004-12-02 19:41 -------
Subject: Bug 16675
CVSROOT: /cvs/gcc
Module name: gcc
Changes by: tromey@gcc.gnu.org 2004-12-02 19:41:03
Modified files:
gcc/java : ChangeLog parse.y
Log message:
PR java/16675:
* parse.y (craft_constructor): Special case null_pointer_node.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/java/ChangeLog.diff?cvsroot=gcc&r1=1.1511&r2=1.1512
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/java/parse.y.diff?cvsroot=gcc&r1=1.523&r2=1.524
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16675
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug java/16675] [4.0 Regression] Null parameter values for anonymous constructor invocation require explicit cast
2004-07-22 19:47 [Bug libgcj/16675] New: Null parameter values require explicit cast richardl at redhat dot com
` (5 preceding siblings ...)
2004-12-02 19:41 ` cvs-commit at gcc dot gnu dot org
@ 2004-12-02 19:44 ` tromey at gcc dot gnu dot org
6 siblings, 0 replies; 8+ messages in thread
From: tromey at gcc dot gnu dot org @ 2004-12-02 19:44 UTC (permalink / raw)
To: java-prs
------- Additional Comments From tromey at gcc dot gnu dot org 2004-12-02 19:44 -------
Fix checked in
--
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16675
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2004-12-02 19:44 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-07-22 19:47 [Bug libgcj/16675] New: Null parameter values require explicit cast richardl at redhat dot com
2004-07-22 20:17 ` [Bug java/16675] " mckinlay at redhat dot com
2004-10-23 20:43 ` [Bug java/16675] Null parameter values for anonymous constructor invocation " pinskia at gcc dot gnu dot org
2004-11-11 21:24 ` [Bug java/16675] [4.0 Regression] " pinskia at gcc dot gnu dot org
2004-12-02 18:11 ` tromey at gcc dot gnu dot org
2004-12-02 19:38 ` cvs-commit at gcc dot gnu dot org
2004-12-02 19:41 ` cvs-commit at gcc dot gnu dot org
2004-12-02 19:44 ` tromey at gcc dot gnu dot org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).