Re: Delphi in BNF syntax

Robert Zierer <>
12 Feb 1998 13:40:14 -0500

          From comp.compilers

Related articles
Delphi in BNF syntax (Christian Holzner) (1998-01-12)
Re: Delphi in BNF syntax (Paul Mann) (1998-01-13)
Re: Delphi in BNF syntax (Robert Zierer) (1998-02-12)
| List of all articles for this month |

From: Robert Zierer <>
Newsgroups: comp.compilers
Date: 12 Feb 1998 13:40:14 -0500
Organization: tu muenchen
References: 98-01-044
Keywords: Pascal, syntax, FTP, comment

Christian Holzner wrote:

> I am currently working on a lexer/parser for Delphi and would like to
> know if somebody has or knows a source where Delphi or at least
> (Borland) Pascal is described in BNF (or EBNF) syntax.

Here is my grammar for Borland Delphi 1.0 (LALR)
compile with Delphi 1.0.

This code is not very well tested and may contain bugs so there is no
warranty! send bugreports to: (or

The parser.y file is derived from tp4.y, the scanner.l file is derived
from scanner.l which are both in the TPYacc package from Albert Graef;
Homepage: (note:
'[..] However, Berend de Boer has released a new version of TP
Lex/Yacc (4.01) [..] The new version can be obtained from the Garbo
MsDos & Windows archive [..]')

I've modified an older version of TPYacc to fit my needs (larger table
sizes, tables in resources). Drop me a note, if you need that version.
[I stuck it in the archive at

Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.