Yacc

Yacc

The computer program yacc is a parser generator developed by Stephen C. Johnson at AT&T for the Unix operating system. The name is an acronym for "Yet Another Compiler Compiler." It generates a parser (the part of a compiler that tries to make syntactic sense of the source code) based on an analytic grammar written in a notation similar to BNF. Yacc generates the code for the parser in the C programming language.

Yacc used to be available as the default parser generator on most Unix systems. It has since been supplanted as the default by more recent, largely compatible, programs such as Berkeley Yacc, GNU bison, MKS yacc and Abraxas pcyacc. An updated version of the original AT&T version is included as part of Sun's OpenSolaris project. Each offers slight improvements and additional features over the original Yacc, but the concept has remained the same. Yacc has also been rewritten for other languages, including Ratfor, EFL, ML, Ada, Java, and Limbo.

The parser generated by Yacc requires a lexical analyzer. Lexical analyzer generators, such as Lex or Flex are widely available. The IEEE POSIX P1003.2 standard defines the functionality and requirements for both Lex and Yacc.

Some versions of AT&T Yacc have become open source. For example, source code (for different implementations) is available with the standard distributions of Plan 9 and OpenSolaris.

ee also

* LALR parser: The underlying parsing algorithm in Yacc.
* Bison: The GNU version of Yacc.
* Lex (and Flex lexical analyser), the token parser commonly used in conjunction with yacc (and Bison).
* BNF, is a metasyntax used to express context-free grammar: that is, a formal way to describe formal languages.

References

*Stephen C. Johnson. [http://www2.informatik.uni-erlangen.de/Lehre/WS200304/Compilerbau/Uebungen/yacc.pdf YACC: Yet Another Compiler-Compiler] . "Unix Programmer's Manual " Vol 2b, 1979.

External links

* [http://www.techworld.com.au/article/252319/-z_programming_languages_yacc Computerworld Interview with Stephen C. Johnson on YACC]
* [http://www.angelfire.com/dragon/letstry/tutorials/compiler/index.html Tutorial] a lex/yacc/compiler tutorial by Arnab Chakrobarty.
* [http://yaxx.sourceforge.net Yaxx] yacc variant written to avoid dependencies on any particular programming language.
* [http://invisible-island.net/byacc/byacc.html Berkeley Yacc] : yacc variant written to avoid dependencies on any particular C compiler.
* [http://www.informatik.uni-freiburg.de/proglang/software/essence/ Essence] , an LR(1) parser generator for Scheme
* [http://www.smlnj.org/doc/ML-Yacc/index.html ML-Yacc] a yacc version for the Standard ML language.
* [http://www.pps.jussieu.fr/~jch/software/cl-yacc/ CL-Yacc] , a LALR(1)parser generator for Common Lisp.
* [http://www.erlang.org/faq/parsing.html Yecc] a yacc version for Erlang.
* [http://www.haskell.org/happy/ Happy] a yacc-like parser generator for Haskell.
* [http://www.dabeaz.com/ply PLY] a SLR and LALR(1) parser generator for Python
* [http://search.cpan.org/~casiano/Parse-Eyapp/ Eyapp] an extension of yacc for Perl
* A [http://epaperpress.com/lexandyacc/ Compact Guide] To lex & yacc
* TPYACC, a [http://www.musikwissenschaft.uni-mainz.de/~ag/tply/tply.htm Turbo Pascal or Delphi] version of YACC
* The [http://plas.fit.qut.edu.au/gppg/ Gardens Point Parser Generator] (GPPG), an implementation for C#


Wikimedia Foundation. 2010.

Игры ⚽ Нужна курсовая?

Look at other dictionaries:

  • Yacc — es un programa para generar analizadores sintácticos. Las siglas del nombre significan Yet Another Compiler Compiler, es decir, Otro generador de compiladores más . Genera un analizador sintáctico (la parte de un compilador que comprueba que la… …   Wikipedia Español

  • YACC — ist ein Computerprogramm, welches zur Herstellung von Compilern dient. Das Wort Yacc ist ein Akronym, das selbstironisch für yet another compiler compiler steht. Yacc ist eine Implementierung eines Parsergenerators der eine einfache Möglichkeit… …   Deutsch Wikipedia

  • Yacc — ist ein Computerprogramm, welches der Herstellung von Compilern dient. Das Wort Yacc ist ein Akronym, das selbstironisch für yet another compiler compiler steht. Yacc dient der syntaktischen Analyse. Es implementiert einen Parsergenerator, der… …   Deutsch Wikipedia

  • Yacc — yacc  компьютерная программа, служащая стандартным генератором синтаксических анализаторов (парсеров) в Unix системах. Название является сокращением от «Yet Another Compiler Compiler» («ещё один компилятор компиляторов»). Yacc генерирует… …   Википедия

  • yacc — yacc  компьютерная программа, служащая стандартным генератором синтаксических анализаторов (парсеров) в Unix системах. Название является акронимом «Yet Another Compiler Compiler» («ещё один компилятор компиляторов»). Yacc генерирует парсер… …   Википедия

  • YACC —   [Abk. für Yet Another Compiler Compiler, dt. »noch ein Compiler für Compiler«], Hilfsprogramm für das Betriebssystem Unix. YACC dient dazu, mittels formaler Definitionen einer vom Anwender vorgegebenen Computersprache, Compiler …   Universal-Lexikon

  • yacc — (Yet Another Compiler Compiler) n. computer software that is used as the standard parser generator on Unix systems …   English contemporary dictionary

  • YACC — Lex et yacc Lex et Yacc sont des outils très populaires de génération d analyseurs lexicaux (Lex) et syntaxiques (Yacc) en langage C. « Yacc » est l acronyme de Yet Another Compiler Compiler. Du point de vue de la classification des… …   Wikipédia en Français

  • Yacc — Lex et yacc Lex et Yacc sont des outils très populaires de génération d analyseurs lexicaux (Lex) et syntaxiques (Yacc) en langage C. « Yacc » est l acronyme de Yet Another Compiler Compiler. Du point de vue de la classification des… …   Wikipédia en Français

  • YACC — Yet Another Compiler Compiler Grammatikinterpreter und Compilergenerator unter UNIX http://www.desy.de/cgi bin/man cgiyacc …   Acronyms

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”