PQL Grammar

This page specifies the complete grammar of PQL captured in the ANTLR notation. ANTLR (ANother Tool for Language Recognition) is a parser generator for reading and translating structured text or binary files. ANTLR can take a grammar of a language as input and generate source code for a parser that can build and walk syntax trees. The language is specified using a context-free grammar which is expressed using extended Backus-Naur Form.

PQL grammar is proposed below. The latest version of the grammar is available here.