dave/dst
Decorated Syntax Tree - manipulate Go source with perfect fidelity. observed · 2026-08-28
Health v2 · maintenance only
67/100
- Activity 77
- Release rhythm 35
- Longevity 100
Flags: no_releases no_license
How is this computed?
round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10) — computed 2026-09-02. Adoption (stars, forks) is never an input.
- gap_med: n/a
- age_days: 2909
- days_rel: n/a
- days_push: 141
- n_releases_24m: 0
Adoption not part of the score
1438 stars · 64 forks observed · 2026-08-28
What it is AI-extracted, prompt v1, taxonomy v1, 2026-08-30, confidence not recorded
A Go library providing a Decorated Syntax Tree (dst) that allows manipulation of Go source code with perfect fidelity, preserving comments, spacing, and formatting as nodes are modified. It serves as a drop-in alternative to go/ast for source-to-source transformations.
Use cases
- rewrite Go source code while preserving comments and formatting
- reorder or refactor Go statements without breaking comment attachment
- build automated Go code refactoring tools
- inject or modify comments in Go AST nodes
- convert between go/ast and a fidelity-preserving syntax tree
- generate Go code transformations for codemods
When to choose
- you need to programmatically modify Go source and keep comments and spacing intact
- go/ast round-tripping loses or misplaces comments in your transformations
- you are building a Go refactoring, linting, or codemod tool
- you need reliable parse-modify-print of Go code
When to avoid
- you only need to read or analyze Go code without modifying it - go/ast or go/types suffice
- you are working with languages other than Go
- you need type checking or semantic analysis - pair it with go/types instead
Facets
library · maturity stable
parser developer-tools developer-tools programming-languages parsers go cross-platform go-ast source-code-manipulation syntax-tree code-generation decorations comments-preservation
1 source
- readme: https://github.com/dave/dst · fetched 2026-08-28 · 0077b90404d9
Member repositories
| Repository | Role | Health v2 |
|---|---|---|
| dave/dst | main | 67 |
For agents
Data as of 2026-08-30T08:39:29.467469+00:00 · Report a problem