You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs(readme): document the Elixir ~PB compile-time sigil
Verified examples (glyphs captured from the reference encoder, round-trip
checked through Elixir decode/1): Hello, World! <-> Hello٫␣Worldǃ and a heredoc
"·OK" -> <<0, "OK">>.
Supported flags: `-d/--decode`, `-f/--format NxM`, `-s/--spaces`, `--mappings*`, `-h/--help`. The CLI shares the exact encode/decode implementation with the browser UI.
263
263
264
+
### As an Elixir `~PB` Sigil (compile-time)
265
+
266
+
The `~PB` sigil decodes printable-binary glyphs to a **raw binary at compile
267
+
time**, so you can embed binary data legibly inline in Elixir source (no
268
+
separate fixture files) with zero runtime cost — the decoded bytes are baked
269
+
straight into the compiled BEAM module. A literal `"` never appears in the
270
+
encoding, so a `"""` heredoc can safely hold multi-line payloads.
271
+
272
+
```elixir
273
+
importPrintableBinary
274
+
275
+
# Decoded to raw bytes at COMPILE time, then trivially assigned to a variable.
0 commit comments