diff options
author | Dmitri Gribenko <gribozavr@gmail.com> | 2013-12-17 22:22:14 +0000 |
---|---|---|
committer | Dmitri Gribenko <gribozavr@gmail.com> | 2013-12-17 22:22:14 +0000 |
commit | e8bc31f0ab734ebc4a06662d3fb5db25ebce3e90 (patch) | |
tree | e4ac19afc5f2e301b71d3fc77bfcdbb0ef87bc88 /clang/test/Sema/warn-documentation.cpp | |
parent | d4e53f55f1f1883993b233e8308247b0489834af (diff) | |
download | bcm5719-llvm-e8bc31f0ab734ebc4a06662d3fb5db25ebce3e90.tar.gz bcm5719-llvm-e8bc31f0ab734ebc4a06662d3fb5db25ebce3e90.zip |
Documentation comment parsing: when checking if we have typedef to something
that we consider a function for the purposes of checking \param and \returns,
look through reference types.
llvm-svn: 197530
Diffstat (limited to 'clang/test/Sema/warn-documentation.cpp')
-rw-r--r-- | clang/test/Sema/warn-documentation.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/clang/test/Sema/warn-documentation.cpp b/clang/test/Sema/warn-documentation.cpp index 00c56015b6c..ad7ab181a78 100644 --- a/clang/test/Sema/warn-documentation.cpp +++ b/clang/test/Sema/warn-documentation.cpp @@ -326,6 +326,18 @@ typedef foo::function_wrapper<int (int aaa, int ccc)> test_function_like_typedef /// \returns aaa. typedef foo::function_wrapper<int (int aaa, int ccc)> *test_function_like_typedef6; +// expected-warning@+2 {{parameter 'bbb' not found in the function declaration}} expected-note@+2 {{did you mean 'ccc'?}} +/// \param aaa Meow. +/// \param bbb Bbb. +/// \returns aaa. +typedef foo::function_wrapper<int (int aaa, int ccc)> &test_function_like_typedef7; + +// expected-warning@+2 {{parameter 'bbb' not found in the function declaration}} expected-note@+2 {{did you mean 'ccc'?}} +/// \param aaa Meow. +/// \param bbb Bbb. +/// \returns aaa. +typedef foo::function_wrapper<int (int aaa, int ccc)> &&test_function_like_typedef8; + typedef int (*test_not_function_like_typedef1)(int aaa); |