diff options
author | Brad King <brad.king@kitware.com> | 2010-08-20 18:11:18 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2010-08-25 21:10:00 (GMT) |
commit | 7be2617b5a52529ce0ca33e6c878a0294e1e2781 (patch) | |
tree | 9f6246316213f16ecd20d05b812965b51a29d30b /Source/cmComputeLinkDepends.cxx | |
parent | 95b3bb5dbcb6021f07329f5bc400b1a205386970 (diff) | |
download | CMake-7be2617b5a52529ce0ca33e6c878a0294e1e2781.zip CMake-7be2617b5a52529ce0ca33e6c878a0294e1e2781.tar.gz CMake-7be2617b5a52529ce0ca33e6c878a0294e1e2781.tar.bz2 |
Split notion of node lists and edge lists
Diffstat (limited to 'Source/cmComputeLinkDepends.cxx')
-rw-r--r-- | Source/cmComputeLinkDepends.cxx | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/Source/cmComputeLinkDepends.cxx b/Source/cmComputeLinkDepends.cxx index 24410ec..4b0214e 100644 --- a/Source/cmComputeLinkDepends.cxx +++ b/Source/cmComputeLinkDepends.cxx @@ -285,7 +285,7 @@ cmComputeLinkDepends::AllocateLinkEntry(std::string const& item) lei = this->LinkEntryIndex.insert(index_entry).first; this->EntryList.push_back(LinkEntry()); this->InferredDependSets.push_back(0); - this->EntryConstraintGraph.push_back(NodeList()); + this->EntryConstraintGraph.push_back(EdgeList()); return lei; } @@ -669,7 +669,7 @@ void cmComputeLinkDepends::CleanConstraintGraph() cmsys_stl::sort(i->begin(), i->end()); // Make the edge list unique. - NodeList::iterator last = cmsys_stl::unique(i->begin(), i->end()); + EdgeList::iterator last = cmsys_stl::unique(i->begin(), i->end()); i->erase(last, i->end()); } } @@ -681,9 +681,9 @@ void cmComputeLinkDepends::DisplayConstraintGraph() cmOStringStream e; for(unsigned int i=0; i < this->EntryConstraintGraph.size(); ++i) { - NodeList const& nl = this->EntryConstraintGraph[i]; + EdgeList const& nl = this->EntryConstraintGraph[i]; e << "item " << i << " is [" << this->EntryList[i].Item << "]\n"; - for(NodeList::const_iterator j = nl.begin(); j != nl.end(); ++j) + for(EdgeList::const_iterator j = nl.begin(); j != nl.end(); ++j) { e << " item " << *j << " must follow it\n"; } @@ -758,8 +758,8 @@ cmComputeLinkDepends::DisplayComponents() fprintf(stderr, " item %d [%s]\n", i, this->EntryList[i].Item.c_str()); } - NodeList const& ol = this->CCG->GetComponentGraphEdges(c); - for(NodeList::const_iterator oi = ol.begin(); oi != ol.end(); ++oi) + EdgeList const& ol = this->CCG->GetComponentGraphEdges(c); + for(EdgeList::const_iterator oi = ol.begin(); oi != ol.end(); ++oi) { fprintf(stderr, " followed by Component (%d)\n", *oi); } @@ -784,8 +784,8 @@ void cmComputeLinkDepends::VisitComponent(unsigned int c) // Visit the neighbors of the component first. // Run in reverse order so the topological order will preserve the // original order where there are no constraints. - NodeList const& nl = this->CCG->GetComponentGraphEdges(c); - for(NodeList::const_reverse_iterator ni = nl.rbegin(); + EdgeList const& nl = this->CCG->GetComponentGraphEdges(c); + for(EdgeList::const_reverse_iterator ni = nl.rbegin(); ni != nl.rend(); ++ni) { this->VisitComponent(*ni); @@ -856,8 +856,8 @@ void cmComputeLinkDepends::VisitEntry(int index) // are now pending. if(completed) { - NodeList const& ol = this->CCG->GetComponentGraphEdges(component); - for(NodeList::const_iterator oi = ol.begin(); oi != ol.end(); ++oi) + EdgeList const& ol = this->CCG->GetComponentGraphEdges(component); + for(EdgeList::const_iterator oi = ol.begin(); oi != ol.end(); ++oi) { // This entire component is now pending no matter whether it has // been partially seen already. |