Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 349312 - [1.7][compiler] improved problem messages
Summary: [1.7][compiler] improved problem messages
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.7   Edit
Hardware: All All
: P3 trivial (vote)
Target Milestone: 3.7.1   Edit
Assignee: Ayushman Jain CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-06-14 08:55 EDT by Markus Keller CLA
Modified: 2011-08-05 02:54 EDT (History)
2 users (show)

See Also:


Attachments
Patch (2.99 KB, patch)
2011-06-14 08:55 EDT, Markus Keller CLA
no flags Details | Diff
complete patch (48.01 KB, patch)
2011-06-15 09:50 EDT, Ayushman Jain CLA
no flags Details | Diff
patch for 1.5 warnings (102.86 KB, patch)
2011-06-28 02:40 EDT, Ayushman Jain CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Markus Keller CLA 2011-06-14 08:55:42 EDT
Created attachment 197949 [details]
Patch

Here are some fixes that align the new compiler problem messages with the existing ones.

In the first 2 messages, the "s" at the end of "greater or equals" is wrong. I think "source level 1.7 or greater" is easier to understand. That formulation is also used in the JavaCore class' Javadocs.

Some older messages use "... are only available if source level is 1.5". These could also be changed to "1.5 or greater".
Comment 1 Srikanth Sankaran CLA 2011-06-14 10:03:46 EDT
Ayush, please follow up - Thanks.
Comment 2 Ayushman Jain CLA 2011-06-15 09:50:28 EDT
Created attachment 198022 [details]
complete patch
Comment 3 Ayushman Jain CLA 2011-06-15 10:00:43 EDT
Released in BETA_JAVA7 branch.
Comment 4 Jay Arthanareeswaran CLA 2011-06-28 01:22:02 EDT
Ayush, you seem to have missed out the 1.5 related messages.
Comment 5 Ayushman Jain CLA 2011-06-28 01:27:42 EDT
Oops. I'll change them
Comment 6 Ayushman Jain CLA 2011-06-28 02:40:24 EDT
Created attachment 198707 [details]
patch for 1.5 warnings
Comment 7 Ayushman Jain CLA 2011-06-28 15:34:41 EDT
Released.

Updated messages are
590 = Syntax error, type parameters are only available if source level is 1.5 or greater
591 = Syntax error, static imports are only available if source level is 1.5 or greater
592 = Syntax error, 'for each' statements are only available if source level is 1.5 or greater
593 = Syntax error, parameterized types are only available if source level is 1.5 or greater
594 = Syntax error, enum declarations are only available if source level is 1.5 or greater
595 = Syntax error, varargs are only available if source level is 1.5 or greater
596 = Syntax error, annotations are only available if source level is 1.5 or greater
597 = Syntax error, annotation declarations are only available if source level is 1.5 or greater
Comment 8 Jay Arthanareeswaran CLA 2011-06-29 05:49:02 EDT
Verified.