llvm-project/clang/test/SemaObjC/warn-unused-exception-param.m
Douglas Gregor 3f324d569b Diagnose unused exception parameters under a different warning group
(-Wunused-exception-parameter) than normal variables, since it's more
common to name and then ignore an exception parameter. This warning is
neither enabled by default nor by -Wall. Fixes <rdar://problem/7931045>.

llvm-svn: 102931
2010-05-03 18:51:14 +00:00

5 lines
168 B
Objective-C

// RUN: %clang_cc1 -fsyntax-only -verify -Wunused-exception-parameter %s
void f0() {
@try {} @catch(id a) {} // expected-warning{{unused exception parameter 'a'}}
}