sway_ir

Module value

Source
Expand description

The base descriptor for various values within the IR.

Values can be function arguments, constants and instructions. Instructions generally refer to each other and to constants via the Value wrapper.

Like most IR data structures they are Copy and cheap to pass around by value. They are therefore also easy to replace, a common practice for optimization passes.

Structsยง