- C 84.9%
- Makefile 15.1%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| grammar | ||
| .gitignore | ||
| LICENSE | ||
| README.md | ||
| ZigLanguageSpecification.md | ||
Zig Programming Language Specification
Language Reference
https://ziglang.org/documentation/master/
This document is intended to be the complete set of information that Zig users need to look at while coding.
It should explain all the features of the language and answer any questions that might arise. However it is not a tutorial and there is no narrative. It is also insufficient for implementing a compiler.
This document is outside the scope of the specification efforts of this project. It lives in the ZSF reference implementation of Zig.
Informal Specification
This document lives at ZigLanguageSpecification.md.
The entire document is non-normative. It is meant to communicate intent. The intended audience is not Zig users, but Zig project contributors. This document meticulously answers the question "how is the Zig Programming Language supposed to behave?" in plain English.
Thus, this document may contain contradictions due to the ambiguity of English language. Such contradictions help to flesh out how we want the Zig Programming Language to work. The Mechanized Specification will identify such contradictions, and then the resolutions to those ambiguities should be accounted for in the Informal Specification.
In this way, the Informal Specification acts as a mediator between the desired behavior of the language from a messy, human perspective, and the cold, hard reality of mathematics. Sometimes, the Informal Specification should be adjusted to match the Mechanized Specification, which has implications for compiler development, and sometimes the Mechanized Specification should be adjusted to account for the pragmatic needs of compiler development and human intuition.
Mechanized Specification
This is the Zig Programming Language encoded into formal verification software, for the purposes of mathematically proving things about programs written in Zig.
Examples of this would be CompCert, written in Rocq, or the WebAssembly specification, written in SpecTec.
Efforts to produce a mechanized specification of Zig are only just getting started and organized. Contributions welcome.