gleam-lang/gleam

Tracking issue for bit arrays on javascript target

Open

#3,842 建立於 2024年11月17日

在 GitHub 查看
 (3 留言) (3 反應) (0 負責人)Rust (960 fork)batch import
help wanted

倉庫指標

Star
 (21,417 star)
PR 合併指標
 (平均合併 10天 19小時) (30 天內合併 69 個 PR)

描述

There are still many features of bit arrays that are not yet implemented on the javascript target. We want to have all of them eventually, but it's a lot to implement in one go, and a lot to have a separate issue for each one. So I've decided to create a tracking issue to list them all, and these can be slowly ticked off when people implement specific features.

  • Non byte-aligned access
  • Non-constant sizes when pattern matching: <<bits:size(some_variable)>>
  • Non byte-aligned segments
  • Non-utf8 strings: utf16, utf32, utf16_codepoint and utf32_codepoint
  • Pattern matching on utf8_codepoint, utf16_codepoint and utf32_codepoint
  • Signedness: signed and unsigned
  • Endianness: Missing native
  • Unit specification: unit
  • 16-bit floats

Please let me know if I've missed any. I'm not super familiar with bit array syntax so I mostly just looked through the compiler and found where an error was thrown on javascript.

貢獻者指南