griotspeak
griotspeak

Reputation: 13247

Does the order of methods in my .m file matter to the compiler?

I think that i have noticed moving certain methods around causes errors when i compile that are remedied by putting the method back where it was.

am i making this up? is there are rhyme or reason to the order that these need to be in? is decided by the order of my .h? what about delegate methods and inherited methods?

Upvotes: 2

Views: 474

Answers (1)

Wevah
Wevah

Reputation: 28242

Yes, but only if you reference a method in an earlier place without declaring it elsewhere. You may want to declare your method in your main @implementation or stick it into a class extension in your implementation (.m) file.

Upvotes: 3

Related Questions