Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: New ObjC style language development




On Aug 22, 2005, at 6:40 AM, Jens Ayton wrote:

How about "ALTERS"?

It's a question of whether to pick "addition" or "modification".

If "modification" was to be the emphasis, then perhaps "MODIFIES" would be best. Anyway, thanks for the feedback, we're going to revisit this again.


Also, a nitpick: the Interface sample contains:

CLASS METHOD initWithFoo: (foo : Foo) andBar: (bar : Bar) : FooBar;

According to Cocoa/OpenStep practice, init* should be an instance method. The corresponding class method would be newWithFoo:andBar:, or fooBarWithFoo:andBar: if it autorelease the return value. Also, the return type should be OBJECT to allow clean overriding of superclass initialisers with the same name.

Indeed. However, keep in mind that the wiki page intends to present an overview and be concise. To the Modula-2 programmer the concept of dynamic typing is foreign and thus for illustrative reasons it was important to show that the method returns Foobar the class. Agreed, we'll have to work on that a bit to strike a better balance.


The only reason why initWithFoo:andBar: is presented as a class method is to show that there is a syntactical destinction between class methods and instance methods, a concept that will again be foreign to Modula-2 and Pascal programmers. But the idea to use newWithFoo:andBar: as an example instead is great. We'll change that. Thanks a lot for your feedback.

rgds
ObjM2 project





___________________________________________________________ Yahoo! Messenger - NEW crystal clear PC to PC calling worldwide with voicemail http://uk.messenger.yahoo.com
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Objc-language mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/objc-language/email@hidden


This email sent to email@hidden
References: 
 >New ObjC style language development (From: ObjM2 <email@hidden>)
 >Re: New ObjC style language development (From: Adam Nohejl <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.