Odin: dev-2024-06:f1779c85d
OS: Manjaro Linux, Linux 6.1.80-1-MANJARO
CPU: 12th Gen Intel(R) Core(TM) i7-1260P
RAM: 31806 MiB
Backend: LLVM 14.0.6
Expected Behavior
Compiler should give the compile error consistenly and never Segmentation fault (core dumped).
Current Behavior & Steps to Reproduce
When Running
package odincrash
import "core:fmt"
import "core:os"
main :: proc() {
files := [?]string{"i.txt", "j.txt"}
for &f in files {
stat := os.stat(f, allocator = context.temp_allocator) or_continue
fmt.println(stat)
}
}
Half of the time I get
/home/tadeo/Desktop/test/odincrash/main.odin(10:11) Error: 'or_continue' expects an "optional ok" like value, or an n-valued expression where the last value is either a boolean or can be compared against 'nil', got Errno
stat := os.stat(f, allocator = context.temp_allocator) or_contin ...
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
Half of the time I just get Segmentation fault (core dumped) from the compiler.
Context
Odin Version and OS:
Expected Behavior
Compiler should give the compile error consistenly and never
Segmentation fault (core dumped)
.Current Behavior & Steps to Reproduce
When Running
Half of the time I get
Half of the time I just get
Segmentation fault (core dumped)
from the compiler.