Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 522603 - [9] Is modular label changes for JRE without any changes in its module properties
Summary: [9] Is modular label changes for JRE without any changes in its module proper...
Status: RESOLVED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.7   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 4.7.1a   Edit
Assignee: Stephan Herrmann CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 521666
Blocks:
  Show dependency tree
 
Reported: 2017-09-21 13:18 EDT by Noopur Gupta CLA
Modified: 2017-09-24 18:11 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Noopur Gupta CLA 2017-09-21 13:18:49 EDT
- Create a Java 9 project and open its Libraries tab on Java Build Path dialog.
- Expand JRE. It has the property: "Is modular".
- Click Edit on "Is modular".
- Click OK on Module Properties dialog w/o changing anything.
- The property now says: "Is modular (limits modules)".

Is this expected? Without any changes in Module Properties dialog, the label has changed.

Or, the OK button could be disabled when the dialog opens until some changes are done.
Comment 1 Stephan Herrmann CLA 2017-09-22 12:24:08 EDT
This is a consequence of commit cd3a5636d6fef999a2566de32bba8762a47c7cac which in turn adopts bug 522328 from JDT/Core.

Two things deserving improvement:

- when computing the label compare the current set in limit-modules against the standard set according to bug 522328 => don't show a modification if same list of modules.

- need another variant of the label to say s.t. like
   "Is modular (adds modules)"

We're now starting to get a combinatorial explosion we we also consider combinations of limit/add with "modifies encapsulation", so perhaps we should generalize add/limit modules messsages to "(modifies set of modules)" or similar.
Comment 2 Stephan Herrmann CLA 2017-09-24 14:52:59 EDT
Fixed via commit http://git.eclipse.org/c/jdt/eclipse.jdt.ui.git/commit/?h=BETA_JAVA9&id=03cfb6c4d47001541cacaff7c923ad3897ca7794

- When set of included modules is equal to the standard set per JEP 261, do not set a limit-modules attribute. This is then reflected in the label and also avoids unnecessary limit-modules attributes in .classpath.

- Changed the label from "limits modules" to "modifies contents", which (a) matches the "Contents" tab and (b) allows easy combination to "modifiers contents and encapsulation".

Leaving the bug open to ensure the fix gets into 4.7.1a.

@Noopur, what's the intended strategy between the three active branches?
Comment 3 Noopur Gupta CLA 2017-09-24 15:23:02 EDT
(In reply to Stephan Herrmann from comment #2)
> Fixed via commit
> http://git.eclipse.org/c/jdt/eclipse.jdt.ui.git/commit/?h=BETA_JAVA9&id=03cfb6c4d47001541cacaff7c923ad3897ca7794
> 
> 
> - When set of included modules is equal to the standard set per JEP 261, do
> not set a limit-modules attribute. This is then reflected in the label and
> also avoids unnecessary limit-modules attributes in .classpath.
> 
> - Changed the label from "limits modules" to "modifies contents", which (a)
> matches the "Contents" tab and (b) allows easy combination to "modifiers
> contents and encapsulation".

Thanks, Stephan.

> Leaving the bug open to ensure the fix gets into 4.7.1a.
> 
> @Noopur, what's the intended strategy between the three active branches?

We should release all fixes in R4_7 and BETA_JAVA9 now. Once we merge BETA_JAVA9 / R4_7 to master (by Monday/Tuesday), BETA_JAVA9 will be abandoned and we should add all fixes to R4_7 and master after that until 4.7.1a is released.
Comment 4 Stephan Herrmann CLA 2017-09-24 18:11:11 EDT
Thanks, pushed also to R4_7_maintenance for 4.7.1a via http://git.eclipse.org/c/jdt/eclipse.jdt.ui.git/commit/?h=R4_7_maintenance&id=d4f834e9634e28583f297fdb9eef0b92bc268c8b