Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] warning-free EDC projects

Yes. Without it, you couldn't turn warnings into errors and tell the compiler to ignore specific ones.

John

At 09:56 AM 5/6/2010, Alena Laskavaia wrote:
So what was the new JDT feature? #3?

On Thu, May 6, 2010 at 10:49 AM, John Cortell <rat042@xxxxxxxxxxxxx> wrote:
> I've configured the EDC projects to treat warnings as errors so that the
> projects remain warning-free. This wasn't feasible before, but the JDT guys
> acted on my request to make it so (
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=295551 ).
>
> Here's what you need to do to make your projects warning-intolerant:
>
> 1. Open the project properties
> 2. Turn on Java Compiler > Errors/Warnings > Enable project specific
> settings
> 3. Turn on Java Compiler > Errors/Warnings > Annotations > Suppress optional
> errors with '@SuppressWarnings'
> 4. Open org.eclipse.jdt.core.prefs and do a find&replace of "=warning" to
> "=error" (use Replace All)
>
> I'm a big advocate of zero-warning code. I believe build-time warnings are
> effective only when you have none.  E.g., 'org.eclipse.cdt.debug.core' has
> 621 warnings. If the compiler tries to warn me about something suspicious in
> some new code I've added, there is about a 0% chance I'll be aware of it.
> That's because there's a 0% chance I'll realize there were 621 warnings in
> the project before my change and now there are 622. Anyway, enough
> preaching. Just wanted to spread the word on this new JDT option and how it
> enables us to improve code quality.
>
> Note that this does not cover PDE warnings.
>
> John
>
>
>
>
>
>
> _______________________________________________
> cdt-dev mailing list
> cdt-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/cdt-dev
>
>
_______________________________________________
cdt-dev mailing list
cdt-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/cdt-dev



Back to the top