Subject: | Fix for negative numbers issue |
sub _readnum {
# Reads in a character at a time until we run out of numbers to read...
my $self = shift;
my $cursor = $$self{'cursor'};
my $string;
while ( 1 ) {
my $char = $self->_readchar();
--- if ( $char !~ /^[\d\.]+$/ ) {
+++ if ( $char !~ /^[-\d\.]+$/ ) {
$$cursor--;
last;
}
$string .= $char;
} # End of while.