
Summary: ASTImporter contained wrong or missing imports of SourceLocation and SourceRange for some objects. At least a part of such errors is fixed now. Source location import fixes in namespace, enum, record, class template specialization declarations and DeclRefExpr, UnresolvedLookupExpr, UnresolvedMemberExpr, NestedNameSpecifierLoc. Reviewers: martong, a.sidorin, shafik Reviewed By: shafik Subscribers: rnkovacs, dkrupp, Szelethus, gamesh411, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D60499
14 lines
325 B
C++
14 lines
325 B
C++
// RUN: clang-import-test -dump-ast -import %S/Inputs/T.cpp -expression %s | FileCheck %s
|
|
|
|
// CHECK: |-ClassTemplateSpecializationDecl
|
|
// CHECK-SAME: <line:4:1, line:8:1> line:4:20 struct A
|
|
|
|
void expr() {
|
|
A<int>::B b1;
|
|
A<bool>::B b2;
|
|
b1.f + b2.g;
|
|
}
|
|
|
|
static_assert(f<char>() == 0, "");
|
|
static_assert(f<int>() == 4, "");
|