arXiv · 2512.01036
A Word Sampler for Well-Typed Functions
Abstract
We describe an exact sampler for a simply-typed, first-order functional programming language. Given an acyclic finite automaton, $\alpha_{\varnothing}$, it samples a random function uniformly without replacement from well-typed functions in $\mathcal{L}(\alpha_{\varnothing})$. This is achieved via a fixed-parameter tractable reduction from a syntax-directed type system to a context-free grammar, preserving type soundness and completeness w.r.t. $\mathcal{L}(\alpha_{\varnothing})$, while retaining the robust metatheory of formal languages.
Explore related subjects
Keep this discovery
Explore connections, maps & timelines
Breandan Considine. 2025-11-30. A Word Sampler for Well-Typed Functions. https://arxiv.org/abs/2512.01036
Cite the original work for its findings. Save a collection to share your selection of sources.