tests: audit buffer and error-value rejection twins

This commit is contained in:
dev committed 2026-10-08 21:21:42 +03:00
1 parent 2742867ef7
commit 5371eb7a2f
14 files changed
+273 -17

No files matched your search

@@ -0,0 +1,10 @@
// expect: reject E3201
// phase: 6
// spec: docs/spec/15-source-language.md §17
// AIR twin: buffers/wrong_capability.air
module test.buffer_wrong_capability
fn bad(b: mut<buffer<u64>>, cap: cap<io.write>) -> void effects [mem.alloc] {
buffer.reserve(b, 0usize, cap) or trap; // diagnostic here
trap;
}
fn main() -> u64 effects [] { return 42; }