Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 334955 - Chained comma operator is not highlighted in editor
Summary: Chained comma operator is not highlighted in editor
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-parser (show other bugs)
Version: 8.0   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 8.0   Edit
Assignee: Markus Schorn CLA
QA Contact: Markus Schorn CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-01-20 17:10 EST by Andrew Gvozdev CLA
Modified: 2011-01-21 06:23 EST (History)
2 users (show)

See Also:


Attachments
testcase + fix (2.03 KB, patch)
2011-01-21 05:38 EST, Markus Schorn CLA
mschorn.eclipse: iplog-
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew Gvozdev CLA 2011-01-20 17:10:29 EST
In the example below only first overloaded comma operator in main() is being highlighted and hyperlinked in editor. On the other hand, operator plus works fine.

#include <iostream>

class CHAINER {
public:
	CHAINER const & operator,(int x) const {
		std::cout << "*** " << x << " ***\n";
		return *this;
	};
	CHAINER const & operator+(int x) const {
		std::cout << "+++ " << x << " +++\n";
		return *this;
	};
};


int main() {

	CHAINER c;
	c,0,1,2; // Only first comma is colored

	c+10+11+12; // Coloring is fine here

	return 0;
}
Comment 1 Anton Leherbauer CLA 2011-01-21 04:04:14 EST
I assume this is a parser problem.
Comment 2 Markus Schorn CLA 2011-01-21 05:38:33 EST
Created attachment 187268 [details]
testcase + fix
Comment 3 Markus Schorn CLA 2011-01-21 05:42:14 EST
Fixed in 8.0 > 20110121.