A month or so ago I started seeing the following error when running cargo check --all --all-targets
- is this known?
error[E0599]: no associated item named `GENERIC_COPY_REF` found for struct `roc_module::symbol::Symbol` in the current scope
--> crates/compiler/gen_llvm/src/llvm/bitcode.rs:749:26
|
749 | let symbol = Symbol::GENERIC_COPY_REF;
| ^^^^^^^^^^^^^^^^
| |
| associated item not found in `Symbol`
| help: there is an associated constant with a similar name: `GENERIC_COMPARE_REF`
|
note: if you're trying to build a new `roc_module::symbol::Symbol`, consider using `roc_module::symbol::Symbol::new` which returns `roc_module::symbol::Symbol`
Intriguing. GENERIC_COPY_REF
exists. It is defined here: https://github.com/roc-lang/roc/blob/main/crates/compiler/module/src/symbol.rs#L1178
I must have missed something when I added it...not sure what though.
I see no difference between GENERIC_COPY_REF
and GENERIC_RC_REF
in definition and use. Yet you see no error for GENERIC_RC_REF
Though cargo check --all --all-targets
doesn't generate any errors for me
Do you have an old version of rust?
$ cargo --version
cargo 1.77.2 (e52e36006 2024-03-26)
Same cargo version: cargo 1.77.2 (e52e36006 2024-03-26)
Strange!
Oh, interesting. I see multiple errors on linux. None on macos.
For example see this:
oc_exhaustive v0.0.1 (/home/bren077s/Projects/roc-misc/roc/crates/compiler/exhaustive)
error[E0004]: non-exhaustive patterns: `roc_module::called_via::BinOp::Assignment`, `roc_module::called_via::BinOp::IsAliasType`, `roc_module::called_via::BinOp::IsOpaqueType` and 1 more not covered
--> crates/compiler/fmt/src/expr.rs:657:11
|
657 | match op {
| ^^ patterns `roc_module::called_via::BinOp::Assignment`, `roc_module::called_via::BinOp::IsAliasType`, `roc_module::called_via::BinOp::IsOpaqueType` and 1 more not covered
|
Ok, I'm really confused by this error. Those missing patterns aren't part of roc_module::called_via::BinOp
try running cargo clean
. Fixed it for me.
bad rust caching with version changes I guess.
This is all I'm seeing
https://gist.github.com/lukewilliamboswell/feffeb6d5705a05409fb86532f45c0dd
Yeah, that's what I see on my mac. And now on my linux machine after running clean
Wow; cargo clean worked!
Should have thought to try that :/
Definitely seen this thing before with rust in other contexts
Thanks!
Joshua Warner has marked this topic as resolved.
Last updated: Jul 06 2025 at 12:14 UTC