view clang/test/AST/template-implicit-vars.cpp @ 150:1d019706d866

LLVM10
author anatofuz
date Thu, 13 Feb 2020 15:10:13 +0900
parents
children 2e18cbf3894f
line wrap: on
line source

// RUN: %clang_cc1 -fsyntax-only %s -std=c++11 -ast-dump | FileCheck %s
template<typename T>
void f(T t) {
  T a[] = {t};
  for (auto x : a) {}
}

void g() {
  f(1);
}
// CHECK: VarDecl {{.*}} implicit used __range
// CHECK: VarDecl {{.*}} implicit used __range
// CHECK: VarDecl {{.*}} implicit used __begin
// CHECK: VarDecl {{.*}} implicit used __end