-
-
06 Jul 2019 22:46:02 UTC
- Distribution: CPU-Z80-Assembler
- Module version: 2.18
- Source (raw)
- Browse (raw)
- Changes
- How to Contribute
- Repository
- Issues (1)
- Testers (445 / 0 / 6)
- Kwalitee
Bus factor: 1- 97.18% Coverage
- License: perl_5
- Perl: v5.10.0
- Activity
24 month- Tools
- Download (155.54KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
++ed by:1 non-PAUSE userNAME
CPU::Z80::Assembler::List - Assembly listing output class
SYNOPSIS
use CPU::Z80::Assembler::List; my $lst = CPU::Z80::Assembler::List->new(input => $asm_input, output => \*STDOUT); $lst->add($line, $address, $bytes); $lst->flush();
DESCRIPTION
This module handles the output of the assembly listing file. It is fead with each assembled opcode and generates the full assembly list file on the given output handle.
If output is undef, does not generate any output.
EXPORTS
Nothing.
FUNCTIONS
new
my $lst = CPU::Z80::Assembler::List->new(input => $asm_input, output => \*STDOUT);
Creates a new object, see Class::Struct.
input
input is the input as passed to z80asm, i.e. list of text lines to parse or iterators that return text lines to parse.
output
output is the output file handle to receive the listing file. It can be an open file for writing, or one of the standard output file handles.
If output is undefined, no output is generated.
add
$self->add($line, $address, $bytes);
Adds a new opcode to the output listing. Receives the opcode Asm::Preproc::Line, address and bytes. Generates the output lines including this new opcode.
The output is held in an internal buffer until an opcode for the next line is passed to a subsequent add() call.
The last output line is only output on flush() or DESTROY()
flush
$self->flush();
Dumps the current line to the output. Called on DESTROY().
Module Install Instructions
To install CPU::Z80::Assembler, copy and paste the appropriate command in to your terminal.
cpanm CPU::Z80::Assembler
perl -MCPAN -e shell install CPU::Z80::Assembler
For more information on module installation, please visit the detailed CPAN module installation guide.