newRef method
- @mustCallSuper
@mustCallSuper
Create new reference to this SharedArray.
Implementation
@mustCallSuper
ArrayRef<T> newRef() {
if (_refCount == 0) {
sharedBuffer = Array<T>(length, _allocate);
}
_refCount++;
return ArrayRef._(this);
}