NAME
Parse::Eyapp::Node - The nodes of the Syntax Trees
SYNOPSIS
use Parse::Eyapp;
use Parse::Eyapp::Treeregexp;
METHODS
The Parse::Eyapp::Node objects represent the nodes of the syntax tree. All the node classes build by %tree and %metatree directives inherit from Parse::Eyapp::Node and consequently have acces to the methods provided in such module.
Parse::Eyapp:YATW Methods
Parse::Eyapp:YATW objects represent tree transformations. They carry the information of what nodes match and how to modify them.
TREE MATCHING AND TREE SUBSTITUTION
See the documentation in Parse::Eyapp::MatchingTrees
SEE ALSO
ocamlyacc tutorial at http://plus.kaist.ac.kr/~shoh/ocaml/ocamllex-ocamlyacc/ocamlyacc-tutorial/ocamlyacc-tutorial.html
REFERENCES
The classic Dragon's book Compilers: Principles, Techniques, and Tools by Alfred V. Aho, Ravi Sethi and Jeffrey D. Ullman (Addison-Wesley 1986)
AUTHOR
Casiano Rodriguez-Leon (casiano@ull.es)
ACKNOWLEDGMENTS
This work has been supported by CEE (FEDER) and the Spanish Ministry of Educacion y Ciencia through Plan Nacional I+D+I number TIN2005-08818-C04-04 (ULL::OPLINK project http://www.oplink.ull.es/). Support from Gobierno de Canarias was through GC02210601 (Grupos Consolidados). The University of La Laguna has also supported my work in many ways and for many years.
A large percentage of code is verbatim taken from Parse::Yapp 1.05. The author of Parse::Yapp is Francois Desarmenien.
I wish to thank Francois Desarmenien for his Parse::Yapp module, to my students at La Laguna and to the Perl Community. Special thanks to my family and Larry Wall.
LICENCE AND COPYRIGHT
Copyright (c) 2006-2008 Casiano Rodriguez-Leon (casiano@ull.es). All rights reserved.
Parse::Yapp copyright is of Francois Desarmenien, all rights reserved. 1998-2001
These modules are free software; you can redistribute it and/or modify it under the same terms as Perl itself. See perlartistic.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
EYAPP_GRAMMAR
unlink('main.pm', 't/main.pm', 'main.output', 't/main.output');
Parse::Eyapp->new_grammar( input=>$grammar, classname=>'Alias', firstline =>7, outputfile => 'main', );
#my $file = -d 't' ? 't/main.pm' : 'main.pm'; # Please, investigate the 'ouputfile' parameter of new_grammar!!!!!!!!!!!!!!! my $file = 'main.pm'; pod_file_ok( $file, "valid POD file from .yp" );
my $generated = slurp_file($file); like($generated, qr{MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE\.\s+=for None\s+=cut\s+#line.*\s+1;}, 'documentation inside eyapp ends ok'); }
unlink('main.pm', 't/main.pm', 'main.output', 't/main.output');