[Bug objc/32995] False warning when implementing an instance method called `dealloc'

2010-09-14 Thread nicola at gcc dot gnu dot org


--- Comment #3 from nicola at gcc dot gnu dot org  2010-09-14 22:52 ---
If you want to use dealloc for compatibility with Apple Cocoa / GNUstep Base,
then you also want the warnings that dealloc needs to include a call to [super
dealloc], so I wouldn't change the compiler ;-)

You could change your code though - if you're triyng to be compatible with
Cocoa / GNUstep, then you may as well define an NSObject root class and have a
dealloc method in it ;-)

If you still want to use Object, you can add a -dealloc method to Object by
using a category:

@interface Object (dealloc)
- (void) dealloc;
@end

(the add the implementation).  Then you can have the missing [super dealloc] in
your subclass, and the compiler won't generate any warnings.

Thanks


-- 

nicola at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||WONTFIX


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32995



[Bug objc/32995] False warning when implementing an instance method called `dealloc'

2007-08-06 Thread pinskia at gcc dot gnu dot org


--- Comment #2 from pinskia at gcc dot gnu dot org  2007-08-06 21:40 ---
well to some extend dealloc is special method which is why the warning is
there.  Also dealloc does not belong to the the original Object class (which is
based on the old NX Object base class).  This is true of the NeXT runtime
Object too.


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 GCC target triplet|x86_64-linux-gnu|
Summary|False warning when  |False warning when
   |implementing an instance|implementing an instance
   |method called `dealloc' |method called `dealloc'


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32995



[Bug objc/32995] False warning when implementing an instance method called `dealloc'

2007-08-05 Thread vgeddes at gnome dot org


--- Comment #1 from vgeddes at gnome dot org  2007-08-05 13:56 ---
Created an attachment (id=14025)
 -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=14025action=view)
IObject.mi

Preprocessed file for IObject.m


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32995