Code::Blocks Forums

Developer forums (C::B DEVELOPMENT STRICTLY!) => Development => Topic started by: gmb300 on September 13, 2007, 11:15:31 pm

Title: C::B flags 'note:' as a compiler error (with patch)
Post by: gmb300 on September 13, 2007, 11:15:31 pm
Example:
warning: 'nErr' may be used uninitialized in this function
note: 'nErr' was declared here
    ^ This line is not an error, it is the context of the warning message

The 'note:' gets flagged as an error.

Edited...
Title: Re: C::B reports some gcc compiler warnings as errors
Post by: MortenMacFly on September 14, 2007, 06:51:00 am
Since I set the maximum error limit to 5 this prevents me from seeing any real errors.
So why do you set such a low limit then?! :shock:
Title: Re: C::B reports some gcc compiler warnings as errors
Post by: gmb300 on September 14, 2007, 08:38:41 pm
Patch

I created a patch which treats 'note:' lines as information. But only for the MingW/GCC target. It might be a good idea to add these regexes to all the GCC based compiler targets.

[attachment deleted by admin]
Title: Re: C::B reports some gcc compiler warnings as errors
Post by: Biplab on October 19, 2007, 11:07:12 am
Patch

I created a patch which treats 'note:' lines as information. But only for the MingW/GCC target. It might be a good idea to add these regexes to all the GCC based compiler targets.

Applied in revision 4544. Thanks for the patch. :)
Title: Re: C::B flags 'note:' as a compiler error (with patch)
Post by: darthdespotism on October 19, 2007, 01:33:40 pm
MinGW only?

Can be annoying with nativ gcc on Gnu/Linux, too ;)
Title: Re: C::B flags 'note:' as a compiler error (with patch)
Post by: mandrav on October 19, 2007, 02:03:18 pm
MinGW only?

Can be annoying with nativ gcc on Gnu/Linux, too ;)

It's the same compiler...
Title: Re: C::B flags 'note:' as a compiler error (with patch)
Post by: darthdespotism on October 19, 2007, 11:00:26 pm
It's the same compiler...

Yes but the author only mentions MinGW and excludes explicitely other GCCs from his Patch.

Doing an update right now ;)