I upgraded to xcode 4.0 and am now getting this error when I compile:
"Property 'xxx' not found on object开发者_JS百科 of type 'yyy'"
where xxx is a property and yyy is my delegate.
I'm trying to set the property xxx on the delegate object as follows:
self.delegate.xxx=@"abc"
Does anyone know why this would not be working now with xcode 4.0? It was fine with xcode 3.x.
I'm also getting this compile error:
"Expression is no assignable - type of receiver is unknown"
I'm guessing your delegate is of type id? If so, the compiler doesn't have enough information to safely let you do this. You need to cast your delegate to a type that is expecting to have a property xxx. I also find . notation more warning-prone. Maybe something like this:
[(YourObj *)self.delegate setXXX:@"abc"];
精彩评论