aboutsummaryrefslogtreecommitdiff
path: root/clang/test/Sema/warn-documentation.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2012-08-13 16:37:30 +0000
committerDouglas Gregor <dgregor@apple.com>2012-08-13 16:37:30 +0000
commit35ceb27fa4af18156d2cfec43dbabe0513a10cee (patch)
tree592ad714baa6ed83a7a1a896e88d742911a5568f /clang/test/Sema/warn-documentation.cpp
parent700de17aeaf29dacbe8f15163ca679a1bbf28527 (diff)
downloadllvm-35ceb27fa4af18156d2cfec43dbabe0513a10cee.zip
llvm-35ceb27fa4af18156d2cfec43dbabe0513a10cee.tar.gz
llvm-35ceb27fa4af18156d2cfec43dbabe0513a10cee.tar.bz2
When looking for the comment associated with a declaration, adjust the
'templated' declaration for a function or class template to refer to the function or class template itself, to which the documentation will be attached. Fixes PR13593. llvm-svn: 161762
Diffstat (limited to 'clang/test/Sema/warn-documentation.cpp')
-rw-r--r--clang/test/Sema/warn-documentation.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/clang/test/Sema/warn-documentation.cpp b/clang/test/Sema/warn-documentation.cpp
index d116c3f..16ba429 100644
--- a/clang/test/Sema/warn-documentation.cpp
+++ b/clang/test/Sema/warn-documentation.cpp
@@ -652,3 +652,19 @@ void test_nocrash1(int);
/// \param\brief
void test_nocrash2(int);
+// PR13593
+
+/**
+* Bla.
+*/
+template <typename>
+void test_nocrash3();
+
+/// Foo
+template <typename, typename>
+void test_nocrash4() { }
+
+template <typename>
+void test_nocrash3()
+{
+}