✓
Passing This code compiles and runs correctly.
Code
// TEST: aspirational - arbitrary stdlib events should be rejected inside kernel scope
~import std/kernel
~import std/io
~std/kernel:shape(Body) {
mass: f64,
}
~std/kernel:init(Body) {
{ mass: 1.0 },
}
| kernel k |> std/kernel:self { k.mass *= 2.0 } |> std/io:print.ln("mass updated")
Flows
flow ~shape click a branch to expand · @labels scroll to their anchor
shape (expr: Body, source: mass: f64,)
flow ~init click a branch to expand · @labels scroll to their anchor
init (expr: Body, source: { mass: 1.0 },)
Test Configuration
Expected Error:
unsupported construct 'std.io:print.ln' inside kernel scope