• 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
new class
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

new class


  • Subject: new class
  • From: H M <email@hidden>
  • Date: Thu, 20 Sep 2007 23:12:42 +0100

HELP! this is driving me nuts.

In a new class (subclass of NSObject) I have the following method:

- (DCPoint)convert { // gives this error: can not use an object as parameter to a method
DCPoint * DC = [[DCPoint alloc] init];


	// insert calculations here

	[DC initWithDistance:0 Course:0];
	return DC;						 // gives this error: incompatible types in return

}

my method does not have any parameters, which is why that first error is driving me nuts. what does it mean?

there was also a warning: control reaches end of non-void function, but that disappeared somehow. strange...





--
GPG Key ID: 92AD877F7E4E32B9
Fingerprint: 16B0 7DCD 3AB0 0C45 F5FD  581D 92AD 877F 7E4E 32B9


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: new class
      • From: PGM <email@hidden>
    • Re: new class
      • From: "I. Savant" <email@hidden>
    • Re: new class
      • From: "Igor Mozolevsky" <email@hidden>
  • Prev by Date: Re: Calling processPendingChanges from awakeFromInsert
  • Next by Date: Re: new class
  • Previous by thread: Re: cross platform distributed objects?
  • Next by thread: Re: new class
  • Index(es):
    • Date
    • Thread