Is it not possible to have multiple roc.exe versions concurrently on the same machine? I've pulled down the compiler source to tidy up some things I've noticed, and was trying to test my changes by running the downloaded nightly and then my local build. However, running the nightly causes a kernel panic. (Windows)
Which version do you have?
Are you building the Rust or Zig roc from source?
I'm building the new Zig-based compiler
I'd be curious to know why the nightly causes a panic... but it may be hard to track down
There shouldn't be any reason they interact -- different versions
I wonder if our CI that is building the nightlies on Windows has something goofy going on... you may just be the first person to have tried the nightly :sweat_smile:
They are different executables, but the same "version" if that should matter.
❯ …\Projects\Roc\test ❯ cat .\main.roc
app [main!] { pf: platform "https://github.com/lukewilliamboswell/roc-platform-template-zig/releases/download/0.6/2BfGn4M9uWJNhDVeMghGeXNVDFijMfPsmmVeo6M4QjKX.tar.zst" }
import pf.Stdout
main! = |_args| {
Stdout.line!("Hello, World!")
Ok({})
}
❯ …\Projects\Roc\test ❯ D:\Projects\Roc-compiler\roc\zig-out\bin\roc
Hello, World!
❯ …\Projects\Roc\test ❯ E:\Roc\roc_nightly-windows_x86_64-2026-02-26-adbec1c\roc.exe
thread 7656 panic: integer does not fit in destination type
???:?:?: 0x7ff7eb988e4a in ??? (???)
???:?:?: 0x7ff7eb907a2b in ??? (???)
???:?:?: 0x7ff7eb76def0 in ??? (???)
???:?:?: 0x7ff7eb6c4357 in ??? (???)
???:?:?: 0x7ff7eb68aa26 in ??? (???)
???:?:?: 0x7ff7eb682098 in ??? (???)
???:?:?: 0x7ff7eb68136e in ??? (???)
???:?:?: 0x7ff7eb6810d5 in ??? (???)
???:?:?: 0x7ff7eb681043 in ??? (???)
???:?:?: 0x7ff7ebaa8448 in ??? (???)
???:?:?: 0x7ff7ebaaf33f in ??? (???)
???:?:?: 0x7ffc33ec7373 in ??? (KERNEL32.DLL)
???:?:?: 0x7ffc3589cc90 in ??? (ntdll.dll)
❯ …\Projects\Roc\test ❯ E:\Roc\roc_nightly-windows_x86_64-2026-02-26-adbec1c\roc.exe version
Roc compiler version debug-adbec1c9
❯ …\Projects\Roc\test ❯ D:\Projects\Roc-compiler\roc\zig-out\bin\roc version
Roc compiler version debug-adbec1c9
FWIW the nightly worked OK before I downloaded and built the source.
oh if they are the same "version" its conceivable they are messing with each other's Roc cache
You could try deleting the cache before running and see if that changes anything.
I'm not 100% on where that is on Windows... give me 1 sec
I did wonder about that, as I've noticed
❯ dir C:\Users\cobal\AppData\Roaming\Roc
Directory: C:\Users\cobal\AppData\Roaming\Roc
Mode LastWriteTime Length Name
---- ------------- ------ ----
d---- 26/02/2026 20:12 debug-adbec1c9
You're right, it works fine when I delete that
And then the locally compiled one doesn't work, but it doesn't panic just errors out, So if I want to run different builds locally I need to fiddle with a version number somewhere I guess
The version comes from the git sha. But when you build from source it must be something like Debug verse ReleaseSafe or something like that maybe
Two different versions should use different cache's so that's fine... but if you are building from source and using a nightly I'm not sure we should worry about that too much, I would just recommend you pick one and stick with it
Yeah, that's fine. I was just trying to compare nightly to my local version as I was making some changes I wanted to test
This does suggest there is a deeper bug somewhere with our serialization of modules in the cache I think... but that's pretty deep into the compiler internals
If you commit you changes you will get a different version hash and use a different cache, so then you can compare ok I think
Ah good tip. I was trying to test before committing anything
I must say though, that the process of downloading and building Roc from source was buttery smooth compared to some things I've built myself in the past. Not in the least bit scary (all I had to do was work out why I kept getting the wrong version of Zig - turned out I'd installed it in three different places at various times, and completely forgot about the winget one that was first in my path)
Yeah it's really nice working with Zig. We learnt a lot from building the Rust version, and put a lot of lessons into making the Zig one a lot nicer.
I think the Zig guys have done an excellent job with their tooling
Last updated: Mar 20 2026 at 12:28 UTC