tree-sitter-objc/examples/SemaObjC/method-return-void.m

10 lines
235 B
Mathematica
Raw Normal View History

2022-04-16 15:58:26 +00:00
// RUN: %clang_cc1 -Wmethod-signatures -fsyntax-only -verify -Wno-objc-root-class %s
@interface Test
- (int)foo;
@end
@implementation Test
- (int)foo { return; } // expected-error {{non-void method 'foo' should return a value}}
@end