summaryrefslogtreecommitdiffstats
path: root/clang/lib/Serialization
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2015-08-21 03:04:33 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2015-08-21 03:04:33 +0000
commitb9fa99649bc99e2be9d06511d16f266225eae860 (patch)
treec613a456b27dcd04d793d764d1b47310aff63d23 /clang/lib/Serialization
parent772527c57b4b949905e39ec03360f6f9d19d2729 (diff)
downloadbcm5719-llvm-b9fa99649bc99e2be9d06511d16f266225eae860.tar.gz
bcm5719-llvm-b9fa99649bc99e2be9d06511d16f266225eae860.zip
[modules] When we see a definition of a function for which we already have a
non-visible definition, skip the new definition to avoid ending up with a function with multiple definitions. llvm-svn: 245664
Diffstat (limited to 'clang/lib/Serialization')
-rw-r--r--clang/lib/Serialization/ASTReader.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/clang/lib/Serialization/ASTReader.cpp b/clang/lib/Serialization/ASTReader.cpp
index 440ca6d74bf..6fa1765bc43 100644
--- a/clang/lib/Serialization/ASTReader.cpp
+++ b/clang/lib/Serialization/ASTReader.cpp
@@ -8238,9 +8238,8 @@ void ASTReader::finishPendingActions() {
// Load the bodies of any functions or methods we've encountered. We do
// this now (delayed) so that we can be sure that the declaration chains
- // have been fully wired up.
- // FIXME: There seems to be no point in delaying this, it does not depend
- // on the redecl chains having been wired up.
+ // have been fully wired up (hasBody relies on this).
+ // FIXME: We shouldn't require complete redeclaration chains here.
for (PendingBodiesMap::iterator PB = PendingBodies.begin(),
PBEnd = PendingBodies.end();
PB != PBEnd; ++PB) {
OpenPOWER on IntegriCloud