Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 335901 - Suspicious semicolon is not reported in "else" clause
Summary: Suspicious semicolon is not reported in "else" clause
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-codan (show other bugs)
Version: 8.0   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 8.0   Edit
Assignee: Elena Laskavaia CLA
QA Contact: Elena Laskavaia CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-01-31 15:48 EST by Andrew Gvozdev CLA
Modified: 2011-05-01 22:23 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 Andrew Gvozdev CLA 2011-01-31 15:48:49 EST
Codan thinks that an empty statement is suspicious in "then" part of "if" but in "else" clause it's OK. Consider:

	if (false)
		; // only this one is reported
	else
		;
Comment 1 Elena Laskavaia CLA 2011-05-01 21:32:04 EDT
implemented, it is a preference in this checker - not enabled by default