This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 36956 - [JDK1.5.0] Main class contains two main methods
Summary: [JDK1.5.0] Main class contains two main methods
Status: VERIFIED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Unsupported (show other bugs)
Version: 3.x
Hardware: PC Windows XP
: P3 blocker (vote)
Assignee: issues@java
URL:
Keywords: JDK_SPECIFIC
Depends on:
Blocks:
 
Reported: 2003-10-31 10:53 UTC by Milan Kubec
Modified: 2007-09-26 09:14 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
scrshot of error msg (3.47 KB, image/png)
2003-10-31 10:53 UTC, Milan Kubec
Details
scrshot of editor (10.33 KB, image/png)
2003-10-31 10:54 UTC, Milan Kubec
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Milan Kubec 2003-10-31 10:53:00 UTC
[JDK 1.5.0 beta b26] Creating Java Main Class from
template creates main class with error annotation
over the main method. See first attachment for the
message.
Creating second and another Java Main Class
creates main class with two main methods and one
of them marked with the same error annotation. See
second attachment for the editor screenshot.

It seems to be some bug in JDK (happens from build
26), but without some testcase or at least some
way how to reproduce it outside of IDE, we cannot
file it to bugtraq.
Comment 1 Milan Kubec 2003-10-31 10:53:47 UTC
Created attachment 12028 [details]
scrshot of error msg
Comment 2 Milan Kubec 2003-10-31 10:54:31 UTC
Created attachment 12029 [details]
scrshot of editor
Comment 3 Milan Kubec 2003-10-31 10:56:22 UTC
[NetBeans build 200310291900]
Comment 4 Milan Kubec 2003-11-03 10:34:43 UTC
The problem seesm to be caused by changed signatures of java class
files in new JDK. If Parser boot classpath has been set to rt.jar from
JDK 1.4.2 the problem disapeared.
Comment 5 Tomas Hurka 2003-11-10 09:23:56 UTC
The root cause of the problem is incompatible changes to implementation of JSR-14 
aka 'Adding Generics to Java' between 1.4.x and 1.5.0. Because 1.4.x implementation 
of Generics is enabled for Java parser, parser cannot run correctly with rt.jar from JDK 
1.5.0.
Comment 6 Tomas Hurka 2003-11-10 09:32:54 UTC
Fixed in trunk. Generics are now disabled in Java parser.
Comment 7 Milan Kubec 2003-11-25 14:42:17 UTC
Verified.
Comment 8 Patrick Keegan 2003-12-19 18:09:24 UTC
This sounds like a release note issue to me. If I understand
correctly, users of NB 3.6 will not be able to develop java files with
generics on JDK 1.4.x?
Comment 9 Patrick Keegan 2004-03-04 22:08:24 UTC
removing RELNOTE keyword