From: "matz (Yukihiro Matsumoto) via ruby-core" Date: 2025-12-20T06:44:34+00:00 Subject: [ruby-core:124334] [Ruby Feature#21785] Add signed and unsigned LEB128 support to pack / unpack Issue #21785 has been updated by matz (Yukihiro Matsumoto). It is too late to introduce it in Ruby 4.0, let's aim for 4.1. Matz. ---------------------------------------- Feature #21785: Add signed and unsigned LEB128 support to pack / unpack https://bugs.ruby-lang.org/issues/21785#change-115839 * Author: tenderlovemaking (Aaron Patterson) * Status: Closed ---------------------------------------- Hi, I'd like to add signed and unsigned LEB128 support to the pack and unpack methods. LEB128 is a variable length encoding scheme for integers. You can read the wikipedia entry about it here: https://en.wikipedia.org/wiki/LEB128 LEB128 is used in DWARF, WebAssembly, MQTT, and Protobuf. I'm sure there are other formats, but these are the ones I'm familiar with. I sent a pull request here: https://github.com/ruby/ruby/pull/15589 I'm proposing `K` for the unsigned version and `k` for the signed version. I just picked `k` because it was available, I'm open to other format strings. Thanks for consideration! -- https://bugs.ruby-lang.org/ ______________________________________________ ruby-core mailing list -- ruby-core@ml.ruby-lang.org To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org ruby-core info -- https://ml.ruby-lang.org/mailman3/lists/ruby-core.ml.ruby-lang.org/