lfe_bits(3)
π NAME π
Okay bestie, welcome to the lfe_bits(3) page β this is all about lfe_bits, aka the Lisp Flavoured Erlang (LFE) common binary functions. Itβs giving βtiny utility closet for binariesβ energy, and honestly? Iconic. β¨
π SYNOPSIS π
This module contains a collection of library functions for handling binaries. They are generally not called by the user β like, this is not your main-character API, bestie, itβs backend utility stuff. π
πΈ EXPORTS πΈ
parse_bitspecs(Specs) β the parser that spills the tea β
parse_bitspecs(Specs) ->
{ok,Size,{Type,Unit,Sign,Endian}} |
{error,Error}.
This one parses a bitspec and returns the data. Unmentioned fields get the value default. So if a field isnβt mentioned, itβs lowkey just default. Thatβs the whole vibe. π«Ά
get_bitspecs(Specs) β same energy, but with defaults applied π
get_bitspecs(Specs) ->
{ok,Size,{Type,Unit,Sign,Endian}} |
{error,Error}.
Parse a bitspec, apply defaults, and return the data. Unmentioned fields get the value default. Yes bestie, itβs parse plus default-glow-up. β¨
π ERROR INFORMATION π
The following error values are returned:
{undefined_bittype,Type}bittype_unit
Those are the error values on the list β no more, no less. If you see one, thatβs the vibe. π
π AUTHORS π
Robert Virding. Thatβs the author, periodt. π
Thatβs it, bestie! Source/version: lfe_bits(3), date: 2011-2016. Bye πβ¨
π¦ where this page comes from
- alpine 3.24: lfe-doc 2.2.0-r2 Β· Apache-2.0
- nixos 26.05: erlang27.3.4.19-lfe 2.2.0
- nixpkgs unstable: erlang27.3.4.19-lfe 2.2.2
- nixpkgs unstable: erlang28.5.0.8-lfe 2.2.2
- nixpkgs unstable: erlang29.1.2-lfe 2.2.2
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms