From http://en.wikipedia.org/wiki/Extended_Backus–Naur_Form

Extended Backus–Naur Form (EBNF) is a family of metasyntax notations, any of which can be used to express a context-free grammar.

Does it mean that a context-free grammar is a metalanguage of a context-free language, and EBNF is a syntax for the context-free grammar as a metalanguage, and therefore EBNF is a metasyntax for the context-free language as a object language?

From http://en.wikipedia.org/wiki/Metasyntax

A metasyntax describes the allowable structure and composition of phrases and sentences of a metalanguage, which is used to describe either a natural language or a computer programming language.

Some of the widely used formal metalanguages for computer languages are Backus–Naur Form (BNF), Extended Backus–Naur Form (EBNF), Wirth syntax notation (WSN), and Augmented Backus–Naur Form (ABNF).

Does it mean that EBNF is a metalanguage of a context-free grammar being a formal language?

Some relevant definitions:

From https://proofwiki.org/wiki/Definition:Syntax

The syntax of a formal language is its structure, and is specified by a formal grammar of the formal language.

From https://proofwiki.org/wiki/Definition:Metalanguage

A metalanguage of a formal language is a formal language used to specify the formal language (make statements about the formal language).

The object language of a metalanguage is the language described by that metalanguage.

From https://proofwiki.org/wiki/Definition:Metalanguage/Metasyntax

The syntax of a metalanguage is called a metasyntax of the object language of that metalanguage.

  • 1
    It's not a language, you can't make propositions in it.
    – curiousdannii
    Jul 12, 2014 at 22:56
  • what are BNF and EBNF then?
    – Tim
    Jul 12, 2014 at 22:58
  • 1
    Notations. Metasyntaxes possibly, I don't know what that term is used for.
    – curiousdannii
    Jul 12, 2014 at 22:59
  • For a formal language, are its formal grammar and its syntax the same thing?
    – Tim
    Jul 12, 2014 at 23:04
  • @Tim: Yes. People who talk about formal languages as if they really existed always use the word syntax to mean 'grammar'.
    – jlawler
    Jul 13, 2014 at 1:36

1 Answer 1


According to the Wikipedia definition of a metalanguage, a metalanguage is a language used to make statements about statements in another language. That is, it is a language designed to describe the constructs of another language.

Wikipedia then defines a metasyntax as the syntax or grammar of a given metalanguage.

Therefore, Backus-Naur Form (BNF) is a metalanguage which defines a metasyntax (i.e. a metagrammar) that you use to write statements in BNF to describe the constructs in another language.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.