• 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
Object is nil although alloc'ed and init'ed
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Object is nil although alloc'ed and init'ed


  • Subject: Object is nil although alloc'ed and init'ed
  • From: Michael Becker <email@hidden>
  • Date: Thu, 25 Mar 2004 14:54:52 +0100

Hi!

I am really lost with this one. Here's the deal.

XTCIObject is defined as a subclass of NSObject.
XTCIUser is defined as a subclass of XTCIObject.

Both do not override any -init methods.
Here's my code:

XTCIUser *user = [[ XTCIUser alloc] init];
NSLog(@"This is the user: %@", user);

The output:
This is the user: (null)

How can that be? (There are no warnings, everything is declared nicely and all the necessary header files are imported...)

Regards,
Michael
_______________________________________________
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:
    • [SOLVED] Re: Object is nil although alloc'ed and init'ed
      • From: Michael Becker <email@hidden>
  • Prev by Date: String constants and how to do them
  • Next by Date: [SOLVED] Re: Object is nil although alloc'ed and init'ed
  • Previous by thread: Re: String constants and how to do them
  • Next by thread: [SOLVED] Re: Object is nil although alloc'ed and init'ed
  • Index(es):
    • Date
    • Thread