Force-assignment operator

The force-assignment operator <-! assigns a resource-typed value to an optional-typed variable if the variable is nil. If the variable being assigned to is non-nil, the execution of the program aborts.

The force-assignment operator is only used for resource types and the move operator (<-), which are covered the resources section of this document.

Last updated