forked from OSchip/llvm-project
[clang-tidy] Fix for typos in the tests for `bugprone-exception-escape`
llvm-svn: 344445
This commit is contained in:
parent
d053f5c616
commit
af1f374ece
|
@ -263,21 +263,21 @@ void thrower(int n) {
|
|||
}
|
||||
|
||||
int directly_recursive(int n) noexcept {
|
||||
// CHECK-MESSAGES: :[[@LINE-1]]:5: warning: an exception may be thrown in funcion 'directly_recursive' which should not throw exceptions
|
||||
// CHECK-MESSAGES: :[[@LINE-1]]:5: warning: an exception may be thrown in function 'directly_recursive' which should not throw exceptions
|
||||
if (n == 0)
|
||||
thrower(n);
|
||||
return directly_recursive(n);
|
||||
}
|
||||
|
||||
int indirectly_recursive(int n) noexcept;
|
||||
// CHECK-MESSAGES: :[[@LINE-1]]:5: warning: an exception may be thrown in functin 'indirectly_recursive' which should not throw exceptions
|
||||
// CHECK-MESSAGES: :[[@LINE-1]]:5: warning: an exception may be thrown in function 'indirectly_recursive' which should not throw exceptions
|
||||
|
||||
int recursion_helper(int n) {
|
||||
indirectly_recursive(n);
|
||||
}
|
||||
|
||||
int indirectly_recursive(int n) noexcept {
|
||||
// CHECK-MESSAGES: :[[@LINE-1]]:5: warning: an exception may be thrown in funcion 'indirectly_recursive' which should not throw exceptions
|
||||
// CHECK-MESSAGES: :[[@LINE-1]]:5: warning: an exception may be thrown in function 'indirectly_recursive' which should not throw exceptions
|
||||
if (n == 0)
|
||||
thrower(n);
|
||||
return recursion_helper(n);
|
||||
|
|
Loading…
Reference in New Issue