vgg(1) - Linux man page

Name

vgg - Produces a graph for a Eyapp grammar or a tree term

Synopsys

# for tree terms
vgg -t 'Operator(LeftBinaryOp(expr,term),RightBinaryOp(power),PreUnaryOp(uneg),PostUnaryOp(factorial))'  # dump to stdout
vgg -t 'Operator(LeftBinaryOp(expr,term),RightBinaryOp(power),PreUnaryOp(uneg),PostUnaryOp(factorial))' tree.txt

# for grammars
vgg Calc
vgg Calc.output
vgg -f ps Calc
vgg I<-h>

Install

For this script to work, you have to install GraphViz and Text::Tree first

Example

Here is an example of use:

$ vgg -t 'Operator(LeftBinaryOp(expr,term),RightBinaryOp(power),PreUnaryOp(uneg),PostUnaryOp(factorial))'
                       +--------+
                       |Operator|
                       +--------+
      .---------------.----^--------.-------------.
+------------+ +-------------+ +----------+ +-----------+
|LeftBinaryOp| |RightBinaryOp| |PreUnaryOp| |PostUnaryOp|
+------------+ +-------------+ +----------+ +-----------+
  .---^--.        |              |               |
+----+ +----+  +-----+         +----+       +---------+
|expr| |term|  |power|         |uneg|       |factorial|
+----+ +----+  +-----+         +----+       +---------+

See Also

• GraphViz

• Text::Tree

• eyapp,

• The pdf file in <http://nereida.deioc.ull.es/~pl/perlexamples/Eyapp.pdf>

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.

I wish to thank Leon Brocard for his GraphViz::Parse::Yacc module.

Author

Casiano Rodriguez-Leon

Copyright

(c) Copyright 2006 Casiano Rodriguez-Leon

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.