
CPU::Z80::Assembler::Line - One line of text retrieved from the input

use CPU::Z80::Assembler::Line;
my $line1 = CPU::Z80::Assembler::Line->new(
text => $text,
line_nr => $line_nr,
file => $file );
my $line2 = $line->clone;
if ($line1 == $line2) {...}
if ($line1 != $line2) {...}
$line1->error($message);
$line2->warning($message);

This module defines the data structure to represent one line of input text to be assembled. The object is created by Class::Struct and contains the actual text from the line and the file name and line number where the text was retrieved. This information is used for error messages.

Nothing.

Creates a new object, see Class::Struct.
Get/set the text - text read from the file.
Get/set the line_nr - line where text was read from.
Get/set the file - name of the file where the text was read from.
Creates an identical copy as a new object.
print $self->as_string; print "$self";
Converts to string, for debug purposes. Overloads the double-quote operator.
if ($self == $other) { ... }
Compares two line objects. Overloads the '==' operator.
if ($self != $other) { ... }
Compares two line objects. Overloads the '!=' operator.
Dies with the given error message, indicating the place in the input source file where the error occured as "FILE(LINE) : error ...".
Warns with the given error message, indicating the place in the input source file where the error occured as "FILE(LINE) : warning ...".

See CPU::Z80::Assembler.

CPU::Z80::Assembler Class::Struct

See CPU::Z80::Assembler.