Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unaligned bit arrays on the JavaScript target #761

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

richard-viney
Copy link
Contributor

@richard-viney richard-viney commented Dec 5, 2024

Updates to support unaligned bit arrays on the JavaScript target.

  • CI now runs on nightly as well as v1.6.0 so that the tests of unaligned bit arrays can be run.
  • Tests involving unaligned bit arrays are separated into their own files so that they can be removed when testing on JavaScript and not running on nightly.

Use of nightly should be replaced with v1.9 once it's released.

Additionally, if a future release of stdlib (maybe v1.0?) is able to bump its minimum Gleam version to 1.9 then a bunch of JavaScript code here could be removed due to old-style bit array representations no longer needing to be supported.

@richard-viney richard-viney force-pushed the js-unaligned-bit-arrays branch 2 times, most recently from 04fbf8e to a938a2d Compare December 5, 2024 03:41
@richard-viney richard-viney changed the title Support unaligned bit arrays on JavaScript Unaligned bit arrays on the JavaScript target Dec 5, 2024
@richard-viney richard-viney force-pushed the js-unaligned-bit-arrays branch 4 times, most recently from 7e599c5 to d2bfa0c Compare December 13, 2024 08:02
@richard-viney richard-viney force-pushed the js-unaligned-bit-arrays branch 3 times, most recently from ef7bedf to 12b7ec3 Compare December 24, 2024 05:00
@richard-viney richard-viney force-pushed the js-unaligned-bit-arrays branch 5 times, most recently from 2449e2c to 568d07e Compare January 5, 2025 04:18
@richard-viney richard-viney force-pushed the js-unaligned-bit-arrays branch 2 times, most recently from ffe3918 to 6bcb8c5 Compare January 26, 2025 02:52
@richard-viney richard-viney force-pushed the js-unaligned-bit-arrays branch from 6bcb8c5 to ddd0692 Compare February 2, 2025 22:20
@richard-viney richard-viney force-pushed the js-unaligned-bit-arrays branch 7 times, most recently from 35317a7 to ef7e4c7 Compare February 19, 2025 01:15
@richard-viney richard-viney marked this pull request as ready for review February 19, 2025 01:20
@richard-viney
Copy link
Contributor Author

@lpil Ready for review as the new tests now pass when run against nightly

Copy link
Member

@lpil lpil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you. The conditional testing is somewhat complex, and I'm not sure the gleam property is correct any more, so let's instead drop support for old versions of Gleam and use 1.9.0. We'll need that to be out at least for these to be released.

@richard-viney richard-viney force-pushed the js-unaligned-bit-arrays branch from ef7e4c7 to 67be2fb Compare February 19, 2025 21:33
@richard-viney
Copy link
Contributor Author

Great. Everything's been simplified to assume a minimum Gleam version of v1.9.

The CI failures are resolved by gleam-lang/gleam#4266 (or alternatively by waiting for the v1.9 release and specifying that version in ci.yml instead of nightly).

@richard-viney richard-viney force-pushed the js-unaligned-bit-arrays branch from e672381 to 615591d Compare February 21, 2025 01:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants