YAPP(1) User Contributed Perl Documentation YAPP(1)

# [NAME](#NAME)

yapp - A perl frontend to the Parse::Yapp module

# [SYNOPSYS](#SYNOPSYS)

yapp \[options] *grammar*\[.yp]

yapp *-V*

yapp *-h*

# [DESCRIPTION](#DESCRIPTION)

yapp is a frontend to the Parse::Yapp module, which lets you compile Parse::Yapp grammar input files into Perl [**LALR**(1)](/man/os/perl-yapp/LALR.1) OO parser modules.

# [OPTIONS](#OPTIONS)

Options, as of today, are all optionals :-)

[*-v*](#v)

Creates a file *grammar*.output describing your parser. It will show you a summary of conflicts, rules, the DFA (Deterministic Finite Automaton) states and overall usage of the parser.

[*-s*](#s)

Create a standalone module in which the driver is included. Note that if you have more than one parser module called from a program, to have it standalone, you need this option only for one of your parser module.

[*-n*](#n)

Disable source file line numbering embedded in your parser module. I don't know why one should need it, but it's there.

[*-m module*](#m)

Gives your parser module the package name (or name space or module name or class name or whatever-you-call-it) of *module*. It defaults to *grammar*

[*-o outfile*](#o)

The compiled output file will be named *outfile* for your parser module. It defaults to *grammar*.pm or, if you specified the option *-m A::Module::Name* (see below), to *Name.pm*, in the current working directory.

[*-t filename*](#t)

The *-t filename* option allows you to specify a file which should be used as template for generating the parser output. The default is to use the internal template defined in *Parse::Yapp::Output.pm*. For how to write your own template and which substitutions are available, have a look to the module *Parse::Yapp::Output.pm* : it should be obvious.

[*-b shebang*](#b)

If you work on systems that understand so called *shebangs*, and your generated parser is directly an executable script, you can specifie one with the *-b* option, ie:

```
    yapp -b '/usr/local/bin/perl -w' -o myscript.pl myscript.yp
    
```

This will output a file called *myscript.pl* whose very first line is:

```
    #!/usr/local/bin/perl -w
    
```

The argument is mandatory, but if you specify an empty string, the value of *$Config**{perlpath}* will be used instead.

[*grammar*](#grammar)

The input grammar file. If no suffix is given, and the file does not exists, an attempt to open the file with a suffix of *.yp* is tried before exiting.

[*-V*](#V)

Display current version of Parse::Yapp and gracefully exits.

[*-h*](#h)

Display the usage screen.

# [BUGS](#BUGS)

None known now :-)

# [AUTHOR](#AUTHOR)

William N. Braswell, Jr. &lt;wbraswell\_cpan@NOSPAM.nym.hush.com&gt; (Remove "NOSPAM".)

# [COPYRIGHT](#COPYRIGHT)

Copyright © 1998, 1999, 2000, 2001, Francois Desarmenien. Copyright © 2017 William N. Braswell, Jr.

See [**Parse::Yapp**(3)](/man/os/perl-yapp/Parse::Yapp.3) for legal use and distribution rights

# [SEE ALSO](#SEE_ALSO)

[**Parse::Yapp**(3)](/man/os/perl-yapp/Parse::Yapp.3) [**Perl**(1)](/man/os/perl-yapp/Perl.1) [**yacc**(1)](/man/os/perl-yapp/yacc.1) [**bison**(1)](/man/os/perl-yapp/bison.1)

2026-10-26 perl v5.44.0

---

Document: yapp(1) from perl-yapp 1.21-r8 (Chainguard OS)
Source: https://github.com/wbraswell/parse-yapp
