Skip to content

Commit

Permalink
add test
Browse files Browse the repository at this point in the history
  • Loading branch information
felipensp committed Dec 3, 2023
1 parent 2142430 commit a4c078f
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions vlib/v/tests/array_fixed_auto_clone_test.v
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
fn test_main() {
mut buf4 := [100]u8{}
name(mut buf4)
}

fn name[T](mut buf4 T) {
for idx in 0 .. 100 {
buf4[idx] = idx
}

mut bp := buf4[1..99]

println(bp.bytestr())
assert bp.len == 100
}

0 comments on commit a4c078f

Please sign in to comment.