BNF

Syntax description language

BNF stands for Backus-Naur Form (or Backus Normal Form), a notation for describing the syntax of programming languages and other formal grammars.

Each rule defines how a symbol can be replaced by a sequence of other symbols: <digit> ::= 0 | 1 | 2 | 3.

BNF and its variants (EBNF, ABNF) remain standard tools for specifying language grammars in computer science documentation.

formalism

context-free

Needing no surroundings

expressiveness · standardization

structure

production

Making or generating something

  • ruleGoverning principle or standard
  • terminalAt the endpoint
  • symbolRepresentational mark or sign

derivation · expansion · alternation · concatenation · recursion · sequence · rewrite · substitution · definition · optional

parsing

compiler

Source-to-machine-code translator

lookahead · backtracking

variants

augmented

Increased in size/value

Categories
Opposites
meta-level vs. object-level

BNFsource code

Programming instructions before compilation

implementation · object code · machine code

abstraction vs. implementation

BNFmachine code

CPU-executable binary instructions

production code

formality of language description

BNFREADME

Documentation file convention

comments

Familiarity
Top 2,000,000
Profile
Used worldwide · Timeless · Abstract · Rated G