✓
Passing This code compiles and runs correctly.
Code
// Test 641: Flow Annotations - Parametrized Annotations on Flow Invocations
//
// This test validates that Flow invocations can have parametrized annotations
// and that they are correctly parsed and available in the AST.
import std/build
// Flow with simple annotation
[pure]std/build:step(name: "simple") {
echo "Simple step"
}
// Flow with parametrized annotation (single arg)
[depends_on("simple")]std/build:step(name: "single_dep") {
echo "Single dependency"
}
// Flow with parametrized annotation (multiple args - variadic)
[depends_on(simple, single_dep)]std/build:step(name: "multi_dep") {
echo "Multiple dependencies"
}
// Flow with multiple annotations
[pure|depends_on(simple)]std/build:step(name: "combined") {
echo "Combined annotations"
}
Flows
flow ~step click a branch to expand · @labels scroll to their anchor
step (name: "simple", source: echo "Simple step")
flow ~step click a branch to expand · @labels scroll to their anchor
step (name: "single_dep", source: echo "Single dependency")
flow ~step click a branch to expand · @labels scroll to their anchor
step (name: "multi_dep", source: echo "Multiple dependencies")
flow ~step click a branch to expand · @labels scroll to their anchor
step (name: "combined", source: echo "Combined annotations")
Test Configuration
Post-validation Script:
#!/bin/bash
# Test Flow annotations parsing
set -e
echo "=== Compiling $KORU_INPUT with Flow annotations ==="
koruc "$KORU_INPUT"
echo ""
echo "✅ Flow annotations parsed successfully!"
echo "Annotations are stored in AST and available for build orchestration"