Closed
Description
Work is being done to introduce a Tensor<T>
and supporting types. As part of that, there are many APIs that are both taking in some ref
or span like
type and which also return a ref
or span like
type or which exist as instance methods on a span like
type.
Most of these inputs will never be captured by the underlying or returned span like
type and so should be annotated as scoped which restricts the lifetime of the inputs and effectively indicates that the lifetime won't be extended (and therefore won't be captured by a span like
type or returned as a ref
).
We should, accordingly, audit all the newly introduced APIs and ensure scoped
is appropriately provided on the APIs where relevant.