Skip to content

Commit

Permalink
Add missing changes
Browse files Browse the repository at this point in the history
  • Loading branch information
huwdp committed Nov 5, 2022
1 parent 5b2cbe9 commit 8877cef
Show file tree
Hide file tree
Showing 10 changed files with 17 additions and 1 deletion.
2 changes: 1 addition & 1 deletion source/build.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
rm -rf build
mkdir build
cd build
cmake -lcurl -lreadline ..
cmake ..
make
1 change: 1 addition & 0 deletions tests/logic/expected/overbound_array.hco
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
RUNTIME_ERROR: Out of bounds error in 'a' at line number 3
1 change: 1 addition & 0 deletions tests/logic/expected/overbound_string.hco
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
RUNTIME_ERROR: Out of bounds error in 'a' at line number 2
2 changes: 2 additions & 0 deletions tests/logic/expected/prints.hco
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
hello
world
1 change: 1 addition & 0 deletions tests/logic/expected/underbound_array.hco
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
RUNTIME_ERROR: Out of bounds error in 'a' at line number 3
1 change: 1 addition & 0 deletions tests/logic/expected/underbound_string.hco
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
RUNTIME_ERROR: Out of bounds error in 'a' at line number 2
3 changes: 3 additions & 0 deletions tests/logic/tests/overbound_array.hco
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
let a = array();
a[0] = "hello";
print(a[1]);
2 changes: 2 additions & 0 deletions tests/logic/tests/overbound_string.hco
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
let a = "hello";
print(a[100]);
3 changes: 3 additions & 0 deletions tests/logic/tests/underbound_array.hco
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
let a = array();
a[1] = "hello";
print(a[0]);
2 changes: 2 additions & 0 deletions tests/logic/tests/underbound_string.hco
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
let a = "hello";
print(a[-1]);

0 comments on commit 8877cef

Please sign in to comment.