cli: preserve whole-array arguments for explicit array parameters
This commit is contained in:
1 parent
f733f7c7bb
commit
dde801c653
44 files changed
+397
-9
No files matched your search
@@ -0,0 +1,7 @@
|
||||
// expect: run
|
||||
// result: 42
|
||||
// phase: 6
|
||||
// spec: docs/spec/15-source-language.md §5
|
||||
module test.array_arguments
|
||||
fn set(a: mut<[u64; 2]>) -> void effects [] { a[0] = 42; }
|
||||
fn main() -> u64 effects [unsafe] { var rows: [[u64; 2]; 2] = zero; set(mut unchecked rows[1]); return rows[1][0]; }
|
||||
Reference in new issue
Block a user