help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Byte swapping and bindat


From: Eli Zaretskii
Subject: Re: Byte swapping and bindat
Date: Fri, 10 Jun 2022 18:53:32 +0300

> Date: Fri, 10 Jun 2022 09:32:31 -0400
> From:  Stefan Monnier via Users list for the GNU Emacs text editor 
> <help-gnu-emacs@gnu.org>
> 
>     (let* ((threshold 32)
>            (type (bindat-type (kind   uint 8)
>                               (length sint 32 (> kind threshold)))))
>       (list (bindat-unpack type "\x10\x00\x00\x01\x01")
>             (bindat-unpack type "\x80\x00\x00\x01\x01")))
>     =>
>     (((kind . 16)  (length . 257))
>      ((kind . 128) (length . 16842752)))

It would be nice to have sint documented in the ELisp manual...



reply via email to

[Prev in Thread] Current Thread [Next in Thread]