QuickBEAM.VM.Environment.Captures (QuickBEAM v0.10.9)

Copy Markdown View Source

Helpers for boxing, closing, and synchronizing captured lexical variables.

Summary

Functions

Closes over a captured value by copying it into a fresh heap cell.

Ensures a captured value is represented by a heap cell.

Reads the current value of a captured cell, falling back to the provided slot value.

Synchronizes a captured cell with a new local value.

Functions

close(arg1, val)

Closes over a captured value by copying it into a fresh heap cell.

ensure(cell, val)

Ensures a captured value is represented by a heap cell.

read(arg1, slot_val)

Reads the current value of a captured cell, falling back to the provided slot value.

sync(arg1, val)

Synchronizes a captured cell with a new local value.