Open evanrelf opened 1 month ago
It looks like expected behavior. Roc doesn't cast anything implicitly, so Str
is an invalid type for the if
predicate, which expects only Bool
.
Maybe there’s another problem I missed?
The friendly human error is great, but it's followed by a compiler panic:
thread 'main' panicked at crates/compiler/gen_llvm/src/llvm/build.rs:5764:19:
Error in alias analysis: error in module ModName("UserApp"), function definition FuncName("mainForHost"), definition of value binding ValueId(4): could not find func in module ModName("UserApp") with name FuncName("#\x00\x00\x00\x00\x00\x00\x00z\x87\xceV\x11\xaaYs")
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
You might have missed it in the second code block; I think GitHub has it below the fold, so you have to scroll.
Thank you for the report and clarification!
Minimal repro:
app [main] {
pf: platform "https://github.com/roc-lang/basic-cli/releases/download/0.10.0/vNe6s9hWzoTZtFmNkvEICPErI9ptji_ySjicO6CkucY.tar.br",
}
main = 42
similar issues:
I built Roc from source with Nix at db94b555ab1946ad6bfdb5314a11ba67d9b1d1da.