Bug 247654 - Adding @noextend and removing final modifier is not a pb if the class was a final class
Summary: Adding @noextend and removing final modifier is not a pb if the class was a f...
Status: VERIFIED FIXED
Alias: None
Product: PDE
Classification: Eclipse Project
Component: API Tools (show other bugs)
Version: 3.4   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.5 M2   Edit
Assignee: Olivier Thomann CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 245858
  Show dependency tree
 
Reported: 2008-09-17 10:11 EDT by Olivier Thomann CLA
Modified: 2008-09-17 13:16 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 Olivier Thomann CLA 2008-09-17 10:11:16 EDT
We should not report a changed/restrictions delta in a case where the class was a final class in the baseline and the class in the current profile is not final anymore, but tagged as @noextend.
Before the class was explicitly not extensible using the final modifier. Now this is replaced with the restrictions @noextend.
This doesn't change the behavior of the class and therefore should not be a compatible problem.
Comment 1 Olivier Thomann CLA 2008-09-17 11:40:59 EDT
Added regression tests:
org.eclipse.pde.api.tools.comparator.tests.RestrictionsDeltaTests#test12
org.eclipse.pde.api.tools.comparator.tests.RestrictionsDeltaTests#test13

Released for 3.5M2.
Darin, please verify.

Applying patch for bug 245858 comment 1 is a good test case to reproduce this issue.
Comment 2 Darin Wright CLA 2008-09-17 13:16:29 EDT
Added two build tests:

ClassCompatibilityModifierTests:
* testRemoveFinalAddNoExtend*()
* testRemoveFinal*()

Verified.