NIM
Generated by scripts/gen-format-pages.py from docs/data/format-metadata/, FILE_FORMATS.csv and docs/formats-master.csv. Do not edit by hand: change the source, then run the script.
Nim Preview.
At a glance
| Purpose | Nim source code (.nim), NimScript (.nims) or a Nimble package file (.nimble). |
| Extensions | .nim |
| Poka parser | poka-nim |
| Viewer | poka-metadata-card-viewer |
| Depth tier | Metadata card (see Depth tiers) |
| Breadth tier | B4 Summary (see Breadth tiers) |
How much Poka reads
B4 Summary. The container and metadata are read and summarised (counts, properties, structure), but the main content is not rendered.
Confidence: medium (the reviewer read the code). Basis: Reviewed 2026-10-26: read parsers/poka-nim/src/main.rs (302 lines) and plugin.json in full. The crate has no unit tests and no tests/samples.rs, and the corpus has no .nim, .nims and .nimble sample, so the tier rests on reading the code. Covers .nim, .nims and .nimble. The output is a metadata card of counts found by matching text line by line: imports, from-imports, includes, proc, template, macro and iterator, converter, method and func, types, const, var and let sections, pragmas, when blocks, doc comments and line counts. Judgement: B4, because the structure is summarised but the source itself is never shown.
What Poka does not read
- The source text is not shown: the card carries only counts and a few sample names, with no code view or highlighting
- Constructs are found by matching text line by line, not by parsing, so multi-line declarations, nested or indented definitions and keywords inside strings or comments can be miscounted
- Counts of named items stop where their name list is capped (imports at 32, types at 32), so a larger file under-reports them
- Files over 32 MiB are cut to the first 32 MiB (the card says so)
- Text that is not UTF-8 is decoded with replacement characters; no other encoding is tried
- Nimble package fields (version, author, requires) are not read as such
Libraries
Libraries Poka uses or has assessed for this format, with the status, licence and language the registry records.
- tree-sitter-nim (candidate; MPL-2.0; JavaScript; https://github.com/alaviss/tree-sitter-nim) — Tree-sitter grammar for Nim, usable from Rust via the tree-sitter crate. Grammar source language not shown on page; JavaScript assumed for a tree-sitter grammar.
- oak-nim (candidate; MPL-2.0; Rust; https://github.com/ygg-lang/oaks) — Nim parser in the Oaks framework (examples/oak-nim); licence is of the Oaks repo. Early-stage v0.0.4 and coverage unverified.
- Nim compiler (candidate; MIT; Nim; https://github.com/nim-lang/Nim) — Reference implementation; README says MIT except some modules (see copying.txt). The compiler's parser module was not individually confirmed.
Sources
- parsers/poka-nim/src/main.rs
- parsers/poka-nim/plugin.json