Skip to content

Commit 57abd3a

Browse files
committed
test: add validation for list_push with nested lists
1 parent d4cd941 commit 57abd3a

1 file changed

Lines changed: 17 additions & 0 deletions

File tree

test_debug.prox

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
2+
func main() {
3+
print("Test Validating List Push");
4+
let l = [];
5+
print("Initial len: " + to_string(len(l)));
6+
let sub = [];
7+
print("Sub list created");
8+
list_push(sub, 1);
9+
print("Sub len: " + to_string(len(sub)));
10+
let res = list_push(l, sub);
11+
print("Push result: " + to_string(res));
12+
print("Final len: " + to_string(len(l)));
13+
if (len(l) > 0) {
14+
print("Nested item len: " + to_string(len(l[0])));
15+
}
16+
}
17+
main();

0 commit comments

Comments
 (0)