cli: validate inferred allocation content before AIR

This commit is contained in:
dev committed 2026-10-08 10:31:10 +03:00
1 parent 1bbfed24a8
commit bc5412dadd
67 files changed
+607 -8

No files matched your search

@@ -0,0 +1,7 @@
// expect: reject E7005
// phase: 6
// spec: docs/spec/15-source-language.md §10/§16; docs/spec/03-memory-model.md §25
module test.inferred_content
fn wrap<T>(heap: cap<mem.alloc>, x: T) -> void effects [mem.alloc] { let value = own.new(x, heap) or trap; trap; }
fn unused(heap: cap<mem.alloc>, p: ref<u64>) -> void effects [mem.alloc] { wrap::<ref<u64>>(heap, p); trap; }
fn main() -> void effects [] {}