Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jdt-core-dev] Compiler warning contributions

Maybe you didn't see my comment then.
As for the subsequent diagnostic, I am not seeing how the offending method
invocation is relating with the fact the declaring class is final.

The lesson learned from providing compiler diagnostics is that they should
provide useful feedback to user. Figuring 5 useful diagnostics out of
10.000 irrelevant ones is not helping anybody. Also, we are planning on
enabling some participation in compilation process, and certain diagnostics
could be implemented outside the compiler implementation itself through
this mechanism (details coming soon).


------- Additional Comment #4 From Philippe Mulet 2005-09-06 07:23 [reply]
-------
Thank for this addition. The implementation of the feature looks fine. I am
still hedging whether this is a mandated feature. Why would string be any
different than any other object comparison ? I am a bit worried about
generating
too much noise.




                                                                           
             Joris Verschoor                                               
             <j.verschoor@nefl                                             
             i.nl>                                                      To 
             Sent by:                  "Eclipse JDT Core developers list." 
             jdt-core-dev-boun         <jdt-core-dev@xxxxxxxxxxx>          
             ces@xxxxxxxxxxx                                            cc 
                                                                           
                                                                   Subject 
             09/19/2005 03:05          [jdt-core-dev] Compiler warning     
             PM                        contributions                       
                                                                           
                                                                           
             Please respond to                                             
             "Eclipse JDT Core                                             
             developers list."                                             
                                                                           
                                                                           




Hello,

I recently submitted the patch
https://bugs.eclipse.org/bugs/show_bug.cgi?id=108824
Now I know how things work, I thought of another compiler warning which
I want to implement. But first I need some feedback + confirmation that
it will be included in eclipse (I don't have my bugzilla password with
me, so no feat. req. now)

The problem is: String.replace() is sometimes called without assigning
it's value to a new string.

Solution:
Give a warning if a method of a final class (String, Integer, etc)
returns something non-void, and is not used for:
*rvalue
*comparison
*method parameter

Let me know if I should begin implementing.


Joris


_______________________________________________
jdt-core-dev mailing list
jdt-core-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jdt-core-dev




Back to the top