Appearance
| 1 | namespace IR.Values.Store is | |
| 2 | use SymbolBase = Semantic.Symbols.Symbol | |
| 3 | ||
| 4 | // The cast to the symbol's expected kind is a checked construction | |
| 5 | // invariant: the caller only ever builds this value with a symbol of | |
| 6 | // that kind, so a throw here means the invariant broke elsewhere. | |
| 7 | @suppress("cast-may-throw") | |
| 8 | class INSTANCE_FIELD: SYMBOL is | |
| 9 | is_consumable: bool => value.is_consumable | |
| 10 | ||
| 11 | init(from: IR.Values.Value, symbol: SymbolBase, value: IR.Values.Value) is | |
| 12 | super.init(from, symbol, value) | |
| 13 | ||
| 14 | si | |
| 15 | ||
| 16 | accept(visitor: Visitor) is | |
| 17 | visitor.visit(self) | |
| 18 | si | |
| 19 | ||
| 20 | to_string() -> string => | |
| 21 | "store:[{type}]({from},\"{symbol.name}\",{value})" | |
| 22 | si | |
| 23 | si |