Cup class version method
Closed this issue · 2 comments
kerusan commented
I really love your framework Cup!
Just a thought
The Cup class overrides the class method version from CPObject and returns a CPString.
Wouldn't it be better to call the version method versionString instead since the CPObject
class method returns an int?
CPObject.j
- (int)version
{
return class_getVersion(self);
}
vs.
Cup.j
-
(CPString)version
{
var bundle = [CPBundle bundleForClass:[self class]];return [bundle objectForInfoDictionaryKey:@"CPBundleVersion"];
}
We are now test running with the new type checking that confirms with superclasses so we get a warning on this.
Thanks for the framework!
--kerusan
aparajita commented
I did not know about that method, thanks for pointing this out. You learn something new every day.
aparajita commented
Fixed, thank you.