I noticed that in some old versions of Xcode you could use properties of objects without self
just fine.
Now it gives me an error when I try to access my property without self
, but today I'm writing this code, and it works fine, and doesn't give me any errors.
[aCoder encodeObject:itemName forKey:@"itemName"];
Why is it this way? Why don't I get an error in this case? Why is an error raised in other cases? Why can't this behavior be unified, and what should I use?