Based on Apple's doc: Transitioning to ARC Release Notes, __weak is type qualifier. So, the correct position of __weak is Type * __weak weakPtr, which is weakPtr is a weak pointer points to a variable with Type, instant of __weak Type * notWeakPtr, which is notWeakPtr is a pointer points to a weak variable with Type.
Since const is type qualifier too, replacing __weak by const is a easy way to verify it. The following is the example to show the difference: Type * const constPtrand const Type * ptrToConstType.
Based on Apple's doc: Transitioning to ARC Release Notes,
__weak
is type qualifier. So, the correct position of__weak
isType * __weak weakPtr
, which is weakPtr is a weak pointer points to a variable with Type, instant of__weak Type * notWeakPtr
, which is notWeakPtr is a pointer points to a weak variable with Type.Since
const
is type qualifier too, replacing__weak
byconst
is a easy way to verify it. The following is the example to show the difference:Type * const constPtr
andconst Type * ptrToConstType
.