Add comment for my last patch.
llvm-svn: 106813
diff --git a/clang/lib/Sema/SemaDecl.cpp b/clang/lib/Sema/SemaDecl.cpp
index 5c1de6a..ba84f7c 100644
--- a/clang/lib/Sema/SemaDecl.cpp
+++ b/clang/lib/Sema/SemaDecl.cpp
@@ -1454,7 +1454,13 @@
New->setInvalidDecl();
return;
}
-
+ // c99 6.2.2 P4.
+ // For an identifier declared with the storage-class specifier extern in a
+ // scope in which a prior declaration of that identifier is visible, if
+ // the prior declaration specifies internal or external linkage, the linkage
+ // of the identifier at the later declaration is the same as the linkage
+ // specified at the prior declaration.
+ // FIXME. revisit this code.
if (New->hasExternalStorage() &&
Old->getLinkage() == InternalLinkage &&
New->getDeclContext() == Old->getDeclContext())