| … | |
… | |
| 451 | ################################################## |
451 | ################################################## |
| 452 | # |
452 | # |
| 453 | # Handle a numeric token |
453 | # Handle a numeric token |
| 454 | # |
454 | # |
| 455 | # Add an implicit multiplication, if needed |
455 | # Add an implicit multiplication, if needed |
|
|
456 | # Create the number object and check it |
| 456 | # Save the number as an operand |
457 | # Save the number as an operand |
| 457 | # |
458 | # |
| 458 | sub Num { |
459 | sub Num { |
| 459 | my $self = shift; |
460 | my $self = shift; |
| 460 | $self->ImplicitMult() if $self->state eq 'operand'; |
461 | $self->ImplicitMult() if $self->state eq 'operand'; |
| 461 | $self->pushOperand(Parser::Number->new($self,shift,$self->{ref})); |
462 | my $num = Parser::Number->new($self,shift,$self->{ref}); |
|
|
463 | my $check = $self->{context}->flag('NumberCheck'); |
|
|
464 | &$check($num) if $check; |
|
|
465 | $self->pushOperand($num); |
| 462 | } |
466 | } |
| 463 | |
467 | |
| 464 | ################################################## |
468 | ################################################## |
| 465 | # |
469 | # |
| 466 | # Handle a constant token |
470 | # Handle a constant token |