| // RUN: %clang_cc1 -triple x86_64-apple-darwin11 -fsyntax-only -fobjc-arc -fblocks -Wdealloc-in-category -verify %s |
| // RUN: not %clang_cc1 -triple x86_64-apple-darwin11 -fsyntax-only -fobjc-arc -fblocks -Wdealloc-in-category -fdiagnostics-parseable-fixits %s 2>&1 | FileCheck %s |
| - dealloc; // expected-error {{return type must be correctly specified as 'void' under ARC, instead of 'id'}} |
| // CHECK: fix-it:"{{.*}}":{6:3-6:3}:"(void)" |
| @protocol Foo <NSObject> @end |
| - (id) dealloc { // expected-error {{return type must be correctly specified as 'void' under ARC, instead of 'id'}} |
| // CHECK: fix-it:"{{.*}}":{20:5-20:7}:"void" |
| @interface Subclass : Base |
| @interface Subclass (CAT) |
| @implementation Subclass (CAT) |
| - (void)dealloc { // expected-warning {{-dealloc is being overridden in a category}} |
| @interface NSError:NSObject |
| - (NSError *)MCCopyAsPrimaryError __attribute__((objc_method_family(new))); |
| @implementation NSError(CAT) |
| - (NSError *)MCCopyAsPrimaryError { |