|
|
|
|
|
by atrick6
3558 days ago
|
|
From the doc comments: /// Accesses the `Pointee` instance referenced by `self`.
///
/// - Precondition: Either the pointee has been initialized with an
/// instance of type `Pointee`, or `pointee` is being assigned to
/// and `Pointee` is a trivial type.
public var pointee: Pointee
So, `a.pointee = 42` is fine since we all know that `Int` is a trivial type. |
|
In this case, `.initialize` is likely also faster because any previous-value-checking logic than might be there is explicitly not used.