diff options
author | Douglas Gregor <dgregor@apple.com> | 2011-06-22 18:16:25 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2011-06-22 18:16:25 +0000 |
commit | 1501f16cfeb3908c3adaa28fcc0710937605c6ef (patch) | |
tree | b723ae9c8f73562cdcb061b0e49f53e8db1ea11a /clang/test/SemaTemplate/instantiate-function-2.cpp | |
parent | 59b5f356ad1705fe2c5af385dc6630c73218371a (diff) | |
download | bcm5719-llvm-1501f16cfeb3908c3adaa28fcc0710937605c6ef.tar.gz bcm5719-llvm-1501f16cfeb3908c3adaa28fcc0710937605c6ef.zip |
When instantiating a function template declaration that was expressed
via a typedef of a function, make sure to synthesize parameter
declarations. Fixes PR9654 / <rdar://problem/9257497>.
llvm-svn: 133628
Diffstat (limited to 'clang/test/SemaTemplate/instantiate-function-2.cpp')
-rw-r--r-- | clang/test/SemaTemplate/instantiate-function-2.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/clang/test/SemaTemplate/instantiate-function-2.cpp b/clang/test/SemaTemplate/instantiate-function-2.cpp index ebc0ef3a9f9..b4c0d9d6393 100644 --- a/clang/test/SemaTemplate/instantiate-function-2.cpp +++ b/clang/test/SemaTemplate/instantiate-function-2.cpp @@ -31,3 +31,14 @@ namespace UsedAttr { foo<int>(); // expected-note{{instantiation of}} } } + +namespace PR9654 { + typedef void ftype(int); + + template<typename T> + ftype f; + + void g() { + f<int>(0); + } +} |