with-disposal ( object quot -- )
Factor handbook > The language > Deterministic resource disposal > Using destructors

Prev:dispose ( disposable -- )
Next:dispose-each ( seq -- )


Vocabulary
destructors

Inputs and outputs
objecta disposable object
quota quotation with stack effect ( object -- )


Word description
Calls the quotation, disposing the object with dispose after the quotation returns or if it throws an error.

Definition