Ranges before:
void test(void (*)(int), int, float);
~~~~~~~~~~~~~ ~~~~ ~~~~~~
Ranges after:
void test(void (*)(int), int, float);
~~~~~~~~~~~~~ ~~~ ~~~~~
This does not change the actual location of the ParmVarDecl, it still
points to the location where the name would be. PR17970.
llvm-svn: 200640
to an "overloaded" set of declarations. This cursor kind works for
unresolved references to functions/templates (e.g., a call within a
template), using declarations, and Objective-C class and protocol
forward declarations.
llvm-svn: 113805
cursors. Sadly, this visitation is a hack, because we don't have
proper source-location information for nested-name-specifiers in the
AST. It does improve on the status quo, however.
llvm-svn: 112837
three different kinds of AST nodes to represent using declarations:
UsingDecl, UnresolvedUsingValueDecl, and
UnresolvedUsingTypenameDecl. These three are collapsed into a single
cursor kind for using declarations, since libclang clients don't need
the distinction.
Several related changes here:
- Cursor visitation of the three AST nodes for using declarations
- Proper source-range computation for these AST nodes
- Using declarations have no USRs, since they don't actually declare
any entities.
llvm-svn: 112730
suppressing USRs). Also, fix up the source location information for
using directives so that the declaration location refers to the
namespace name.
llvm-svn: 112693
aliases. Previously, the location of the alias was at the "namespace"
keyword. Now, it's on the identifier being declared (as is the custom
for Clang), and we keep a separate source location for the "namespace"
keyword.
Also, added a getSourceRange() member function to NamespaceAliasDecl
to correctly compute the source range.
Finally, removed a bunch of setters from NamespaceAliasDecl and gave
ASTReaderDecl friendship so that it could set the corresponding fields
directly.
llvm-svn: 112681
with a new cursor kind for a reference to a namespace.
There's still some oddities in the source location information for
NamespaceAliasDecl that I'll address with a separate commit, so the
source locations displayed in the load-namespaces.cpp test will
change.
llvm-svn: 112676