The Development of Syntax Notations

Steven Pemberton, CWI, Amsterdam

The author

Abstract

Contents

Apology

The bad news: there was a mixup; two different talks by me were assigned to this slot.

The other was ixml standards update.

The good news: there is a whole paper about it from this year's XML Prague; available on my home page.

In the beginning

1951 Kleene, regular language in automata theory.

Uses Kleene star *.

In logic parent* x = x or parent x or parent parent x etc.

Chomsky

Mid 50's

Sentence → NP^VP
VP → Verb^NP
NP → the^man, the^book

Later:

A → BcD
A → a
S → ε

BNF Late 50's

Introduced by Backus for Algol 60

Wrongly quotes nonterminals instead of terminals

Therefore there are some reserved symbols: ::=, and |, chosen because they don't appear in Algol60

Not a normal form, so renamed to Backus Naur Form

<if clause> ::= if <Boolean expression> then
<unconditional statement> ::= 
   <basic statement>|
   <for statement>|
   <compound statement>|
   <block>
<if statement> ::= 
    <if clause> <unconditional statement>|
    <label>: <if statement>
<conditional statement> ::= 
    <if statement>|
    <if statement> else <statement>

vwf mid 60's

Used for Algol 68

exponent part: 
   times ten to the power choice, power of ten.
times ten to the power choice: 
   times ten to the power symbol;
   letter e symbol.

Uses second level to define repetition and option etc. *option *list *sequence *pack

THING option: THING; EMPTY.
THING sequence: THING; THING, THING sequence.

=> letter sequence option

Wirth WSN 1977

Wirth EBNF

Now ISO / IEX 14997 (1996)

ABNF

rfc 733 1977 first appearance
rfc 2234 1997 first def
rfc 4234 2005
rfc 5234 2008

rulelist     =  1*( rule / (*c-wsp c-nl) )
rule         =  rulename defined-as elements c-nl
                ; continues if next line starts
                ; with white space
rulename     =  ALPHA *(ALPHA / DIGIT / "-")
defined-as   =  *c-wsp ("=" / "=/") *c-wsp
                ; basic rules definition and
                ; incremental alternatives

Conclusion