Built alone from an empty CARGO_HOME, its tests passed, and flowrsc checked, ran and exported a document from the conformance corpus; the export built alone. Co-Authored-By: Claude Opus 5.5 <[email protected]>
33 lines
945 B
Text
33 lines
945 B
Text
// Every statement and source form of the graph language, in one text.
|
|
group g0 = "Signal";
|
|
group g1 = "Inner" in g0;
|
|
group stages = "Stages";
|
|
|
|
let n0 = FloatLiteral { value: 2 } in g1;
|
|
let n1 = FloatLiteral {
|
|
value: -3.5,
|
|
unit: "V",
|
|
};
|
|
let lowpass = dsp.filter.iir(input: &n0.value) { response: lowpass, cutoff: 1e3 } in stages;
|
|
let n4 = math.add(
|
|
a: n0.value.copy(),
|
|
b: n4.sum.copy().prev(),
|
|
)
|
|
{ label: r#"a "quoted" label"# };
|
|
let n5 = io.print(value: &mut n4.sum);
|
|
let n6 = "math.add"(a: n1.value.clone(), "b": _);
|
|
let n7 = Merge(inputs: [n0.value, n1.value,]);
|
|
n7.inputs += n4.sum;
|
|
n5.value = n1.value; let n8 = StringLiteral { value: "tab\tand \u{e9}" }
|
|
|
|
fn twice@1(x: f64, k: f64 = 2) -> (y: "f64@{unit=V}") {
|
|
let n0 = math.mul(a: x.value, b: k.value) in inner;
|
|
group inner = "Inside";
|
|
out y = n0.product;
|
|
}
|
|
let n9 = twice@1(x: n0.value) { k: 3 };
|
|
|
|
app {
|
|
root = Stack([title])
|
|
title = Heading("Every statement")
|
|
}
|