297 view sweep write body reads leaf

✓ Passing This code compiles and runs correctly.

Code

input.k

Actual

sink 28
player_sink 18

Expected output

sink 28
player_sink 18

Flows

flow ~i64 click a branch to expand · @labels scroll to their anchor
i64 (expr: Strength)
flow ~i64 click a branch to expand · @labels scroll to their anchor
i64 (expr: Mana)
flow ~i64 click a branch to expand · @labels scroll to their anchor
i64 (expr: Armor)
flow ~std/proto click a branch to expand · @labels scroll to their anchor
std/proto (Player, source: str: Strength mana: Mana)
flow ~std/proto click a branch to expand · @labels scroll to their anchor
std/proto (Enemy, source: str: Strength armor: Armor)
flow ~new click a branch to expand · @labels scroll to their anchor
new (Player, capacity: 8, source: Player)
flow ~new click a branch to expand · @labels scroll to their anchor
new (Enemy, capacity: 8, source: Enemy)
flow ~view click a branch to expand · @labels scroll to their anchor
view (Entities, source: Player Enemy)
flow ~new click a branch to expand · @labels scroll to their anchor
new (acc, source: sink: 0[i64], player_sink: 0[i64])
flow ~insert click a branch to expand · @labels scroll to their anchor
insert (Player, source: str: 18, mana: 12)
flow ~insert click a branch to expand · @labels scroll to their anchor
insert (Enemy, source: str: 10, armor: 5)
flow ~query click a branch to expand · @labels scroll to their anchor
query (Entities)
flow ~query click a branch to expand · @labels scroll to their anchor
query (Entities)
flow ~print.ln click a branch to expand · @labels scroll to their anchor
print.ln (expr: "sink {{ acc.sink:d }}")
flow ~print.ln click a branch to expand · @labels scroll to their anchor
print.ln (expr: "player_sink {{ acc.player_sink:d }}")

Test Configuration

MUST_RUN