A fast, friendly, functional language. https://roc-lang.org
Find a file
Matthieu Pizenberg 0392a93d1b
Implement bitwise shifts (#8469)
* Implement bitwise shifts

Signed-off-by: Matthieu Pizenberg <matthieu.pizenberg@gmail.com>

* Add low_level_interp shift tests

Signed-off-by: Matthieu Pizenberg <matthieu.pizenberg@gmail.com>

* Fix wrong test

Signed-off-by: Matthieu Pizenberg <matthieu.pizenberg@gmail.com>

* Use appropriate byte size for shifts

Signed-off-by: Matthieu Pizenberg <matthieu.pizenberg@gmail.com>

* Simplify shift left and right interpreter

Signed-off-by: Matthieu Pizenberg <matthieu.pizenberg@gmail.com>

* Factorize the num_shift_right_zf_by in interpreter

Signed-off-by: Matthieu Pizenberg <matthieu.pizenberg@gmail.com>

* Add edge cases tests for shifts

Signed-off-by: Matthieu Pizenberg <matthieu.pizenberg@gmail.com>

* Fix an edge case test

Signed-off-by: Matthieu Pizenberg <matthieu.pizenberg@gmail.com>

* Truncate shift left to the correct precision

Signed-off-by: Matthieu Pizenberg <matthieu.pizenberg@gmail.com>

* Add shift operators to the borrow switch

Signed-off-by: Matthieu Pizenberg <matthieu.pizenberg@gmail.com>

* restore accidental deletions

---------

Signed-off-by: Matthieu Pizenberg <matthieu.pizenberg@gmail.com>
Co-authored-by: Anton-4 <17049058+Anton-4@users.noreply.github.com>
2025-12-17 19:32:38 +01:00
.cargo
.devcontainer
.github retry on timeout 2025-12-16 18:28:44 +01:00
.reuse
ci Implement bitwise shifts (#8469) 2025-12-17 19:32:38 +01:00
crates don't ask to report issue for old compiler (#8683) 2025-12-15 17:01:43 +01:00
design
devtools
docker
examples
nix
src Implement bitwise shifts (#8469) 2025-12-17 19:32:38 +01:00
test fix if else fmt without {} (#8698) 2025-12-17 16:36:17 +01:00
.gitattributes
.gitignore Cleanup target handling and deuplication 2025-12-09 13:30:36 +11:00
.llvmenv
.rules
AGENT.md
authors
build.zig fix windows targets for test platforms 2025-12-17 14:35:16 +11:00
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 sigfault is not a typo 2025-12-05 23:16:14 -05:00
version.txt

Work in progress!

Roc is not ready for a 0.1 release yet, but we do have:

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:

Lambda Class logo      ohne-makler logo      Decem logo

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:

Thank you all so much for helping Roc progress!