Mercurial > hg > CbC > CbC_llvm
annotate clang/test/SemaTemplate/default-expr-arguments-2.cpp @ 207:2e18cbf3894f
LLVM12
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Tue, 08 Jun 2021 06:07:14 +0900 |
parents | 1d019706d866 |
children |
rev | line source |
---|---|
150 | 1 // RUN: %clang_cc1 -ast-dump %s 2>&1 | FileCheck %s |
2 | |
3 // This is a wacky test to ensure that we're actually instantiating | |
4 // the default arguments of the constructor when the function type is | |
5 // otherwise non-dependent. | |
6 namespace PR6733 { | |
7 template <class T> | |
8 class bar { | |
9 public: enum { kSomeConst = 128 }; | |
10 bar(int x = kSomeConst) {} | |
11 }; | |
12 | |
13 // CHECK: FunctionDecl{{.*}}f 'void ()' | |
14 void f() { | |
15 // CHECK: VarDecl{{.*}}tmp 'bar<int>' | |
16 // CHECK: CXXDefaultArgExpr{{.*}}'int' | |
17 bar<int> tmp; | |
18 } | |
19 } |