[Q] making IBOutlet property as weak : is it changed in Xcode 4.5.1?
Since Xcode 4.5.1 I noticed a very interesting bug : When an IBOutlet is created by control-dragging to an interface file, it puts "_unsafe_unretained", although the small view for setting options for IBOutlet shows "weak". ( If you do not touch it, it will create "_unsafe_unretained", but if you touch the popup menu and choose "weak", it will create "weak" property. I filed this as a bug. )
Because I know that it is to be "weak" as it is described in "Patterns for Managing Outlets Become Consistent Across Platforms" within "Transitioning to ARC release notes", and because there was no problem in declaring and synthesizing IBOutlet that way until Xcode 4.5, I thought it would be OK to have them "weak" property.
However, after upgrading to Xcode 4.5.1, it started to show this message :
"Synthesis of a weak-unavailable property is disallowed because it requires synthesis of an ivar of the __weak object".
Just in case, I tried to declare the ivar as I had done with previous version of Xcode like Xcode 3.x,
IBOutlet NSTextView * __weak textView; // with and without __weak in front of textView
Now it complains, "Class is incompatible with __weak reference."
So, it looks like that they are changing the required reference type for IBOutlet from weak to _unsafe_unretained.
I noticed that the error messages, "Synthesis of a weak-unavailable.. " was included in the last December code of LLVM.
Probably Apple people adopted it with Xcode 4.5.1 but failed in refine things around it?
Are there any other people who noticed this change? Can you share your idea if any?