[cfe-commits] r159354 - /cfe/trunk/lib/AST/ASTContext.cpp
Dmitri Gribenko
gribozavr at gmail.com
Thu Jun 28 09:19:39 PDT 2012
Author: gribozavr
Date: Thu Jun 28 11:19:39 2012
New Revision: 159354
URL: http://llvm.org/viewvc/llvm-project?rev=159354&view=rev
Log:
Attaching comments to declarations: don't attach comments to implicit declarations.
Modified:
cfe/trunk/lib/AST/ASTContext.cpp
Modified: cfe/trunk/lib/AST/ASTContext.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/ASTContext.cpp?rev=159354&r1=159353&r2=159354&view=diff
==============================================================================
--- cfe/trunk/lib/AST/ASTContext.cpp (original)
+++ cfe/trunk/lib/AST/ASTContext.cpp Thu Jun 28 11:19:39 2012
@@ -61,6 +61,10 @@
assert(D);
+ // User can not attach documentation to implicit declarations.
+ if (D->isImplicit())
+ return NULL;
+
// TODO: handle comments for function parameters properly.
if (isa<ParmVarDecl>(D))
return NULL;
More information about the cfe-commits
mailing list