|
@@ -274,7 +274,7 @@ bounds_check_error :: proc "contextless" (file: string, line, column: int, index
|
|
|
if 0 <= index && index < count do return;
|
|
|
handle_error :: proc "contextless" (file: string, line, column: int, index, count: int) {
|
|
|
fd := os.stderr;
|
|
|
- print_caller_location(fd, Source_Code_Location{file, line, column, ""});
|
|
|
+ print_caller_location(fd, Source_Code_Location{file, line, column, "", 0});
|
|
|
os.write_string(fd, " Index ");
|
|
|
print_i64(fd, i64(index));
|
|
|
os.write_string(fd, " is out of bounds range 0:");
|
|
@@ -289,7 +289,7 @@ slice_expr_error :: proc "contextless" (file: string, line, column: int, lo, hi:
|
|
|
if 0 <= lo && lo <= hi && hi <= len do return;
|
|
|
handle_error :: proc "contextless" (file: string, line, column: int, lo, hi: int, len: int) {
|
|
|
fd := os.stderr;
|
|
|
- print_caller_location(fd, Source_Code_Location{file, line, column, ""});
|
|
|
+ print_caller_location(fd, Source_Code_Location{file, line, column, "", 0});
|
|
|
os.write_string(fd, " Invalid slice indices: ");
|
|
|
print_i64(fd, i64(lo));
|
|
|
os.write_string(fd, ":");
|
|
@@ -306,7 +306,7 @@ dynamic_array_expr_error :: proc "contextless" (file: string, line, column: int,
|
|
|
if 0 <= low && low <= high && high <= max do return;
|
|
|
handle_error :: proc "contextless" (file: string, line, column: int, low, high, max: int) {
|
|
|
fd := os.stderr;
|
|
|
- print_caller_location(fd, Source_Code_Location{file, line, column, ""});
|
|
|
+ print_caller_location(fd, Source_Code_Location{file, line, column, "", 0});
|
|
|
os.write_string(fd, " Invalid dynamic array values: ");
|
|
|
print_i64(fd, i64(low));
|
|
|
os.write_string(fd, ":");
|
|
@@ -324,7 +324,7 @@ type_assertion_check :: proc "contextless" (ok: bool, file: string, line, column
|
|
|
if ok do return;
|
|
|
handle_error :: proc "contextless" (file: string, line, column: int, from, to: typeid) {
|
|
|
fd := os.stderr;
|
|
|
- print_caller_location(fd, Source_Code_Location{file, line, column, ""});
|
|
|
+ print_caller_location(fd, Source_Code_Location{file, line, column, "", 0});
|
|
|
os.write_string(fd, " Invalid type assertion from ");
|
|
|
print_typeid(fd, from);
|
|
|
os.write_string(fd, " to ");
|