Remove old autovect-branch by moving to "dead" directory.
[official-gcc.git] / old-autovect-branch / gcc / testsuite / obj-c++.dg / method-2.mm
bloba76055e471671dd646e772a2b92481c2d061470b
1 /* Test if prior method lookup at method @implementation time is not
2    overly aggressive, leading to methods being found in other classes.  */
3 /* Author: Ziemowit Laski <zlaski@apple.com>.  */
5 /* { dg-do compile } */
7 #include <objc/Object.h>
9 @class NSString;
11 @protocol NSMenuItem
12 + (void)setUsesUserKeyEquivalents:(BOOL)flag;
13 + (BOOL)usesUserKeyEquivalents;
14 @end
16 @interface NSMenuItem : Object <NSMenuItem> {
17   @private
18   id _menu;
20 @end
22 @interface NSResponder : Object <NSMenuItem>
24   id _nextResponder;
26 @end
28 @interface Object(NSMenuValidation)
29 - (BOOL)validateMenuItem:(id <NSMenuItem>)menuItem;
30 @end
32 @interface NSResponder (NSStandardKeyBindingMethods)
33 - (void)insertText:(id)insertString;
34 - (void)doCommandBySelector:(SEL)aSelector;
35 @end
37 @interface NSView : NSResponder
39   id _superview;
40   id _subviews;
42 @end
44 @interface SKTGraphicView : NSView {
45   @private
46   float _gridSpacing;
48 @end
50 @implementation SKTGraphicView
51 - (BOOL)validateMenuItem:(NSMenuItem *)item {
52   return (BOOL)1;
54 - (void)insertText:(NSString *)str {
56 @end