CPU::Z80::Assembler::Preprocessor - Preprocessor for the Z80 assembler
use CPU::Z80::Assembler::Preprocessor; open($fh, $file1) or die; my $stream = z80preprocessor("#include 'file2'\n", sub {<$fh>}); my $line = $stream->get;
This module provides a preprocessor to handle file includes. It is called by CPU::Z80::Assembler::Lexer to retrieve each line of input to scan.
It is a simple wrapper around Asm::Preproc - please look up to check for preprocessor syntax.
By default the 'z80preprocessor' subroutine is exported.
This takes as parameter a list of either text lines to parse, or iterators that return text lines to parse.
The result is a Asm::Preproc::Stream of Asm::Preproc::Line objects that contain each of the input lines of the input.
See Asm::Preproc.
See CPU::Z80::Assembler.
CPU::Z80::Assembler CPU::Z80::Assembler::Lexer Asm::Preproc::Stream Asm::Preproc::Line
To install CPU::Z80::Assembler, copy and paste the appropriate command in to your terminal.
cpanm
cpanm CPU::Z80::Assembler
CPAN shell
perl -MCPAN -e shell install CPU::Z80::Assembler
For more information on module installation, please visit the detailed CPAN module installation guide.