✓
Passing This code compiles and runs correctly.
Code
// Test 624: Destination Scoping with Wildcards
// Validates that destination patterns match visible events in scope
// Pattern ~tap(* -> file.write) observes ALL sources calling file.write
const std = @import("std");
~import "$std/taps"
~event file.read {}
~proc file.read {
}
~event file.write {}
~proc file.write {
std.debug.print("Writing\n", .{});
}
~event network.fetch {}
~proc network.fetch {
}
~event logger { caller: []const u8 }
~proc logger {
std.debug.print("write called from: {s}\n", .{caller});
}
// Observe ALL sources calling file.write
~tap(* -> file.write)
| Profile p |> logger(caller: p.source)
~file.read() |> file.write() |> network.fetch() |> file.write()
Expected
write called from: input:file.read
Writing
write called from: input:network.fetch
Writing
Actual
write called from: input:file.read
Writing
write called from: input:network.fetch
Writing
Test Configuration
MUST_RUN