You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When compiling a recursive function with a particular type signature.
On EndevourOS (Arch Linux), x86_64, roc nightly pre-release, built from commit 71e68f9 on Mi 23 Okt 2024 09:02:05 UTC.
Most minimal reproducible example I could find, shown below.
Note the {} parameter and the Task return is required. roc check reports 0 errors and 0 warnings.
An internal compiler expectation was broken.
This is definitely a compiler bug.
Please file an issue here: <https://github.com/roc-lang/roc/issues/new/choose>
I thought a non-nullable-unwrapped variant for a lambda set was impossible: how could such a lambda set be created without a base case?
Location: crates/compiler/mono/src/layout.rs:1705:61
Removing the parameter on foo changes the error, as shown below. It is also caught by roc check.
I assume this error is less remarkable since it is marked as TODO.
thread '<unnamed>' panicked at crates/compiler/constrain/src/expr.rs:3706:22:
not yet implemented: TODO (@195-198 `17.IdentId(1)`, DelayedAlias { shared: Index(2) })
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Removing the Task return value makes the program function as expected (an infinite loop with no output).
thread 'main' panicked at crates/compiler/mono/src/borrow.rs:396:34:
internal error: entered unreachable code:
No borrow signature for LambdaName { name: `17.IdentId(2)`, niche: Niche(Captures([])) } layout.
Tip 1: This can happen when you call a function with less arguments than it expects.
Like `Arg.list!` instead of `Arg.list! {}`.
Tip 2: `roc check yourfile.roc` can sometimes give you a helpful error.
The tips don't seem to help; roc check again returns 0 errors and 0 warnings.
If this case is unrelated, I can create a separate issue for it.
The text was updated successfully, but these errors were encountered:
Possibly related to (or duplicate of) #6252.
When compiling a recursive function with a particular type signature.
On EndevourOS (Arch Linux), x86_64, roc nightly pre-release, built from commit 71e68f9 on Mi 23 Okt 2024 09:02:05 UTC.
Most minimal reproducible example I could find, shown below.
Note the
{}
parameter and theTask
return is required.roc check
reports0 errors and 0 warnings
.Removing the parameter on
foo
changes the error, as shown below. It is also caught byroc check
.I assume this error is less remarkable since it is marked as
TODO
.Removing the
Task
return value makes the program function as expected (an infinite loop with no output)....and similarly when changing the return value to
Task * *
Using two mutually-recursive functions causes another error.
The tips don't seem to help;
roc check
again returns0 errors and 0 warnings
.If this case is unrelated, I can create a separate issue for it.
The text was updated successfully, but these errors were encountered: