mirror of
https://github.com/roc-lang/roc.git
synced 2025-12-23 08:48:03 +00:00
A fast, friendly, functional language.
https://roc-lang.org
When a numeric literal like `0` is used in a polymorphic context (e.g., `[0]`), its type may be a flex var that defaults to Dec during evaluation. Later, when this value is used as an index to List.get (which expects U64), the type gets unified to U64 but the value's layout is already Dec. This caused a panic because asI128() asserted the layout was an integer. The fix adds extractIndexAsI128() helper that handles both int and frac layouts to extract the integer value correctly, converting Dec values by dividing by the scaling factor. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> |
||
|---|---|---|
| .cargo | ||
| .devcontainer | ||
| .github | ||
| .reuse | ||
| ci | ||
| crates | ||
| design | ||
| devtools | ||
| docker | ||
| examples | ||
| nix | ||
| src | ||
| test | ||
| .gitattributes | ||
| .gitignore | ||
| .llvmenv | ||
| .rules | ||
| AGENT.md | ||
| authors | ||
| build.zig | ||
| build.zig.zon | ||
| BUILDING_FROM_SOURCE.md | ||
| Cargo.lock | ||
| Cargo.toml | ||
| code_of_conduct.md | ||
| CONTRIBUTING.md | ||
| default.nix | ||
| flake.lock | ||
| flake.nix | ||
| Glossary.md | ||
| legal_details | ||
| LICENSE | ||
| mlc_config.json | ||
| README.md | ||
| rust-toolchain.toml | ||
| shell.nix | ||
| typos.toml | ||
| version.txt | ||
Work in progress!
Roc is not ready for a 0.1 release yet, but we do have:
- installation guide
- tutorial
- docs for the standard library
- examples
- faq: frequently asked questions
- group chat for help, questions and discussions
If you'd like to contribute, get started here. Don't hesitate to ask for help on our group chat, we're friendly!
Sponsors
You can 💜 sponsor 💜 Roc on:
We are very grateful for our corporate sponsors Lambda Class, ohne-makler, and Decem:
If you would like your company to become a corporate sponsor of Roc's development, please DM Richard Feldman on Zulip!
We'd also like to express our gratitude to our generous individual sponsors! A special thanks to those sponsoring $25/month or more:
- Peter Marreck
- Barry Moore
- Eric Andresen
- Jackson Lucky
- Agus Zubiaga
- Angelo Ceccato
- Niclas Overby
- Krzysztof G.
- Sam Mohr
- Steven Chen
- Drew Lazzeri
- Alex Binaei
- Jono Mallanyk
- Chris Packett
- James Birtles
- Ivo Balbaert
- Lucas Rosa
- Jonas Schell
- Christopher Dolan
- Nick Gravgaard
- Zeljko Nesic
- Shritesh Bhattarai
- Richard Feldman
- Ayaz Hafiz
- Anthony Bullard
Thank you all so much for helping Roc progress!