pccts.1
资源名称:pccts133.zip [点击查看]
上传用户:itx_2006
上传日期:2007-01-06
资源大小:493k
文件大小:4k
源码类别:
编译器/解释器
开发平台:
Others
- .TH PCCTS 1 "April 1994" "PCCTS" "PCCTS Manual Pages"
- .SH NAME
- PCCTS - The Purdue Compiler Construction Tool Set
- .SH DESCRIPTION
- .PP
- PCCTS is a set of public domain software tools designed to facilitate
- the implementation of compilers and other translation systems. These
- tools currently include fIantlrfP, fIdlgfP and support code. In
- many ways, PCCTS is similar to a highly integrated version of YACC
- [Joh78] and LEX [Les75]; where fIantlrfP (ANother Tool for Language
- Recognition) corresponds to YACC and fIdlgfP (DFA-based Lexical
- analyzer Generator) functions like LEX. However, PCCTS has many
- additional features which make it easier to use for a wider range of
- translation problems.
- .PP
- PCCTS grammars contain specifications for lexical and syntactic
- analysis, intermediate-form construction and error reporting. Rules
- may employ Extended Backus Naur Form (EBNF) grammar constructs and may
- define parameters, return values and local variables. Languages
- described in PCCTS are recognized via Strong LL(k) parsers constructed
- in pure, human-readable, C code. As a result, standard debugging
- tools can be used to trace and debug PCCTS parsers. Breakpoints can
- be set so that parser execution stops before or after grammar
- fragments of interest have been recognized.
- .PP
- PCCTS grammars may contain predicates which allow parsing to be a
- function of semantics as well as syntax (em context-sensitive
- grammars. Backtracking can also be specified to recognized non-LL(k)
- and non-LALR(k) constructs. In addition, PCCTS supports
- intermediate-form (such as expression-trees) construction via a
- flexible Abstract-Syntax Tree (AST) mechanism which allows trees to be
- built explicitly or automatically. The user explicitly creates trees
- via a LISP-like tree constructor or directs the automatic tree
- construction facility via simple grammar directives. AST nodes are
- user-defined and are generally a function of attributes. A default
- transformation from attributes (fB$fP-variables) to AST nodes can be
- specified. Alternatively, each tree node can be defined explicitly
- via an AST node constructor.
- .SH INSTALLATION
- .PP
- PCCTS includes a number of different programs and examples in the
- software release package(emmost of which like to live in their own
- directories. The install script will build a standard hierarchy. The
- PCCTS executables (fIantlrfP, fIdlgfP) may be placed anywhere the
- user wishes but the install script places them in the bin directory
- created during installation.
- .PP
- To begin installation, place the pccts.tar file into the directory
- where you want to place a pccts subdirectory. Untar the file with
- tar xvf pccts.tar
- and cd into it. To install PCCTS, simply type
- make
- which will build the standard PCCTS directory hierarchy (under the
- directory where you ran the install script) and build executable
- versions of antlr and dlg.
- .PP
- The examples associated with PCCTS have makefile variables called
- fBANTLRfP, fBDLGfP etc... which must be set according to your
- personal directory structure before fImakefP'ing. Some variables
- point to the PCCTS executables if the fBPATHfP environment variable
- does not include your fBbinfP directory. Also, there are variables
- that point to PCCTS include directories and must be changed if you
- deviate from the standard PCCTS installation hierarchy. fIantlrfP
- and fIdlgfP can be built without executable versions of themselves
- (fIantlrfP and fIdlgfP are written in themselves).
- .SH "GETTING STARTED"
- .PP
- A C program called fBgenmk.cfP is available in the fBsupport/genmkfP
- directory of the PCCTS release.
- .SH "SEE ALSO"
- .LP
- dlg(1), antlr(1)