diff options
Diffstat (limited to 'clang/test/CXX/temp/temp.decls/temp.class/temp.mem.func/pr5056.cpp')
-rw-r--r-- | clang/test/CXX/temp/temp.decls/temp.class/temp.mem.func/pr5056.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/clang/test/CXX/temp/temp.decls/temp.class/temp.mem.func/pr5056.cpp b/clang/test/CXX/temp/temp.decls/temp.class/temp.mem.func/pr5056.cpp new file mode 100644 index 0000000..70c9c70 --- /dev/null +++ b/clang/test/CXX/temp/temp.decls/temp.class/temp.mem.func/pr5056.cpp @@ -0,0 +1,17 @@ +// RUN: %clang_cc1 -fsyntax-only -verify %s + +extern "C" void * malloc(int); + +template <typename T> struct A { + void *malloc(int); +}; + +template <typename T> +inline void *A<T>::malloc(int) +{ + return 0; +} + +void f() { + malloc(10); +} |