dart-spec-and-grammar icon indicating copy to clipboard operation
dart-spec-and-grammar copied to clipboard

Dart Language Specification and Grammar

Dart Language Specification and Grammar

Using TeX sources taken from @dart-lang/sdk/docs/language, this project makes available the generated versions of the following documents:

  • Dart Language Specification PDF
    • Deprecated; this is now provided by the Dart Team at https://www.dartlang.org/guides/language/spec#in-progress-specification
  • Dart language grammar, automatically extracted from the specification.

The grammar is available in

  • markdown. This is the most workable format; e.g., non-terminal symbols are linked. Here are direct links to some productions:
    • libraryDefinition
    • partDeclaration
    • topLevelDefinition
  • Plain text.
  • PDF (formatting is still work in progress).

The latest language specification sources are mirrored in DLS/current. Subfolders exist for the following key versions as well: