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 226105 - Java Freeform does not allow source level == 1.8
Summary: Java Freeform does not allow source level == 1.8
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Freeform (show other bugs)
Version: 7.4
Hardware: PC Linux
: P3 normal with 1 vote (vote)
Assignee: Jan Lahoda
URL:
Keywords: API, API_REVIEW_FAST
: 233227 (view as bug list)
Depends on:
Blocks:
 
Reported: 2013-02-14 10:13 UTC by Jan Lahoda
Modified: 2014-04-17 08:33 UTC (History)
6 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
An example project. (1.84 KB, application/zip)
2013-02-14 10:13 UTC, Jan Lahoda
Details
Proposed schema change (697 bytes, patch)
2013-04-30 10:05 UTC, Jan Lahoda
Details | Diff
Full patch including the implementation and full new schema. (40.23 KB, patch)
2013-04-30 10:07 UTC, Jan Lahoda
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Lahoda 2013-02-14 10:13:29 UTC
Created attachment 131378 [details]
An example project.

There is no way to specify source level 1.8 for a Java freeform project, as the most recent schema for compilation-unit mandates 1.3, 1.4, 1.5, 1.6 or 1.7. See e.g. the attached project - the Java file in it requires source level 1.8, but specifying the source level in project.xml will cause validation failures during project opening:
Error in project.xml: The value '1.8' of element 'source-level' is not valid.

Allowing source level 1.8 will probably require a new schema version.
Comment 1 Milos Kleint 2013-03-26 12:28:52 UTC
tzezula: you mentioned you want to do this/have it halfway done, reassigning.. if I misunderstood please reassign back
Comment 2 Jan Lahoda 2013-04-30 10:05:04 UTC
Created attachment 133964 [details]
Proposed schema change

I would like to propose changing the schema (by introducing a new version of it) so that is allows to specify source level as: 1.3-99 (e.g. 1.8, 1.9, 1.10). This is the patch that shows the diff between /3 and the newly proposed /4 version of the schema.
Comment 3 Jan Lahoda 2013-04-30 10:07:52 UTC
Created attachment 133966 [details]
Full patch including the implementation and full new schema.
Comment 4 Jan Lahoda 2013-04-30 10:08:24 UTC
Please review, thanks.
Comment 5 Jan Lahoda 2013-05-09 14:30:49 UTC
Integrated:
http://hg.netbeans.org/jet-main/rev/ed2352c2ce4b
Comment 6 Quality Engineering 2013-05-10 02:37:44 UTC
Integrated into 'main-golden', will be available in build *201305092300* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/ed2352c2ce4b
User: Jan Lahoda <jlahoda@netbeans.org>
Log: #226105: a new version of the Java Freeform schema, to allow source level >= 1.8
Comment 7 Milos Kleint 2013-07-23 12:53:59 UTC
*** Bug 233227 has been marked as a duplicate of this bug. ***
Comment 8 Quality Engineering 2013-11-23 04:27:14 UTC
Integrated into 'main-silver', will be available in build *201311230002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/4f2f7a42b1bd
User: Milos Kleint <mkleint@netbeans.org>
Log: #226105 once negotiated what namespace is necessary and what is used, always consistently use the existing namespace when creating elements
Comment 9 gugrim 2014-04-17 07:16:24 UTC
Reopening since the bug is back in NetBeans 8. See also https://netbeans.org/bugzilla/show_bug.cgi?id=243330
Comment 10 gugrim 2014-04-17 08:31:02 UTC
After reading the comments about schema version /4 I realized that this is fixed and I just have to change the schema version in my project.xml files.
Comment 11 Tomas Zezula 2014-04-17 08:33:11 UTC
Right you need to update the schema.
The old schema cannot be changed as it would be incompatible change,
so any such a change requires a new schema with higher version.