Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LLVM 6 support #8

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 5 additions & 1 deletion clang/include/clang_type_name.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,11 @@ SOFTWARE.
//
//===----------------------------------------------------------------------===//

#if LLVM_VERSION_MAJOR >= 6
#include "clang/AST/QualTypeNames.h"
#else
#include "clang/Tooling/Core/QualTypeNames.h"
#endif
#include "clang/AST/DeclTemplate.h"
#include "clang/AST/DeclarationName.h"
#include "clang/AST/GlobalDecl.h"
Expand Down Expand Up @@ -438,7 +442,7 @@ namespace ClangTypeName {
bool WithGlobalNsPrefix) {
// In case of myType* we need to strip the pointer first, fully
// qualify and attach the pointer once again.
if (isa<PointerType>(QT.getTypePtr())) {
if (isa<clang::PointerType>(QT.getTypePtr())) {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add a small comment that clang:: prevents a warning?

// Get the qualifiers.
Qualifiers Quals = QT.getQualifiers();
QT = getFullyQualifiedType(QT->getPointeeType(), Ctx, WithGlobalNsPrefix);
Expand Down
1 change: 0 additions & 1 deletion clang/src/type_helper.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#include "type_helper.hpp"

#include "clang/Tooling/Core/QualTypeNames.h"
#include "clang/AST/Type.h"
#include "clang/AST/Decl.h"
#include "clang/AST/DeclTemplate.h"
Expand Down