• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
protocol not seeing superclass implementation : bug or feature?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

protocol not seeing superclass implementation : bug or feature?


  • Subject: protocol not seeing superclass implementation : bug or feature?
  • From: "Michael B. Johnson" <email@hidden>
  • Date: Tue, 26 Mar 2002 23:56:52 -0800

So let's say I have the following code in my TestView.h:

#import <AppKit/AppKit.h>

@protocol MyRectangle
- (NSRect)bounds;
@end

@interface TestView : NSView <MyRectangle> {
}
@end

When I compile, I get:

TestView.m:26: warning: incomplete implementation of class `TestView'
TestView.m:26: warning: method definition for `-bounds' not found
TestView.m:26: warning: class `TestView' does not fully implement the
`MyRectangle' protocol

which, given that NSView *does* implement this method, and TestView
clearly inherits from NSView, it seems silly for the compiler to
complain. Is this somehow a feature, and I'm missing it? Or is this a
genuine bug? If it's not a bug, what's the best way to not get the
error - I can obviously declare and then implement

- (NSRect)bounds {
return [super bounds];
}

but that seems silly (or again, maybe not - I think I'm just not seeing
some obvious feature of this).

Thanks for any insight.


--> Michael B. Johnson, Ph.D. -- email@hidden
--> Studio Tools, Pixar Animation Studios
--> http://xenia.media.mit.edu/~wave
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: protocol not seeing superclass implementation : bug or feature?
      • From: Nat! <email@hidden>
    • Re: protocol not seeing superclass implementation : bug or feature?
      • From: Nathan Day <email@hidden>
    • Re: protocol not seeing superclass implementation : bug or *feature*?
      • From: Marcel Weiher <email@hidden>
  • Prev by Date: Re: How to change path where Cocoa App is runnin?
  • Next by Date: Re: Dynamic Linking
  • Previous by thread: Re: Intelligently resizing table columns
  • Next by thread: Re: protocol not seeing superclass implementation : bug or *feature*?
  • Index(es):
    • Date
    • Thread