Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » Template Semantic Errors (fake)(Non-fatal indexer resolution errors in Indigo with Boost Graph)
Template Semantic Errors (fake) [message #897177] Mon, 23 July 2012 01:18 Go to next message
Scribble ink is currently offline Scribble inkFriend
Messages: 2
Registered: July 2012
Junior Member
Hi everyone,

Fake Semantic error messages are non-fatal, but admittedly distracting and honestly annoying.

The following code creates "Semantic Error" messages for adjacency_pair_t and edge_pair_t, but strangely not for vertex_pair_t in Indigo + CDT8 (also in CDT6). The code compiles fine, both inside and outside of Eclipse. Rebuilding the index did not resolve the issue.

typedef boost::adjacency_list<	boost::vecS, boost::vecS, boost::undirectedS,
			vertex_prop_t, edge_prop_t, graph_prop_t >
				graph_t;
typedef boost::graph_traits<graph_t>::vertex_iterator vertex_iterator_t;
typedef boost::graph_traits<graph_t>::edge_iterator edge_iterator_t;
typedef boost::graph_traits<graph_t>::adjacency_iterator adjacency_iterator_t;
typedef std::pair<vertex_iterator_t, vertex_iterator_t> vertex_pair_t;
typedef std::pair<edge_iterator_t, edge_iterator_t> edge_pair_t;
typedef std::pair<adjacency_iterator_t, adjacency_iterator_t> adjacency_pair_t;


EDIT: The issue propagates further in the code with the error message: "Field 'first' cannot be resolved (Semantic Error)."
adjacency_pair_t nbd = boost::adjacent_vertices(g, v);
while(nbd.first != nbd.second) {
 ++nbd.first;
}


The following solutions for previously reported semantic errors did not work.
+ March 2012: http://www.eclipse.org/forums/index.php/m/830451/ - Rebuild the index
+ July 2012: http://www.eclipse.org/forums/index.php/t/367733/ - Rebuild the index


It should be noted that the files
.project
and
.cproject
were generated using CMake and edited in Eclipse via "Import" -> "Existing projects..." The include directories have been manually verified to be correct.

+ Anyone else run into this issue as well?
+ Any suggestions or insights?

Thanks in advance,
scribbleink

[Updated on: Mon, 23 July 2012 01:25]

Report message to a moderator

Re: Template Semantic Errors (fake) [message #897187 is a reply to message #897177] Mon, 23 July 2012 05:12 Go to previous message
Scribble ink is currently offline Scribble inkFriend
Messages: 2
Registered: July 2012
Junior Member
Sorry I hadn't checked Bugzilla before posting this one. Looks like it has been fixed in the Nightly build of CDT 8.1 for Juno. A full Eclipse upgrade worked.

Ref bug 357624.
Previous Topic:mixing static and shared libs
Next Topic:comment block code style
Goto Forum:
  


Current Time: Wed Apr 24 14:38:50 GMT 2024

Powered by FUDForum. Page generated in 0.03274 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top