CodeQL library for C/C++
codeql/cpp-all 2.0.2-dev (changelog, source)
Search

Member predicate Declaration::getName

Gets the name of this declaration.

This name doesn’t include a namespace or any argument types, so for example both functions ::open() and ::std::ifstream::open(...) have the same name. The name of a template class includes a string representation of its parameters, and the names of its instantiations include string representations of their arguments. Template functions and their instantiations do not include template parameters or arguments.

To get the name including the namespace, use hasQualifiedName.

To test whether this declaration has a particular name in the global namespace, use hasGlobalName.

string getName()