[poe-commits] poe/lib/POE NFA.pm,1.29,1.30 Session.pm,1.103,1.104
Brought to you by:
rcaputo
From: <tek...@us...> - 2004-11-16 07:54:20
|
Update of /cvsroot/poe/poe/lib/POE In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21359 Modified Files: NFA.pm Session.pm Log Message: CALLER_STATE added Index: NFA.pm =================================================================== RCS file: /cvsroot/poe/poe/lib/POE/NFA.pm,v retrieving revision 1.29 retrieving revision 1.30 diff -C2 -d -r1.29 -r1.30 *** NFA.pm 16 Nov 2004 07:12:42 -0000 1.29 --- NFA.pm 16 Nov 2004 07:54:10 -0000 1.30 *************** *** 108,121 **** sub CALLER_FILE () { 7 } sub CALLER_LINE () { 8 } ! sub ARG0 () { 9 } ! sub ARG1 () { 10 } ! sub ARG2 () { 11 } ! sub ARG3 () { 12 } ! sub ARG4 () { 13 } ! sub ARG5 () { 14 } ! sub ARG6 () { 15 } ! sub ARG7 () { 16 } ! sub ARG8 () { 17 } ! sub ARG9 () { 18 } sub import { --- 108,122 ---- sub CALLER_FILE () { 7 } sub CALLER_LINE () { 8 } ! sub CALLER_STATE () { 9 } ! sub ARG0 () { 10 } ! sub ARG1 () { 11 } ! sub ARG2 () { 12 } ! sub ARG3 () { 13 } ! sub ARG4 () { 14 } ! sub ARG5 () { 15 } ! sub ARG6 () { 16 } ! sub ARG7 () { 17 } ! sub ARG8 () { 18 } ! sub ARG9 () { 19 } sub import { *************** *** 223,227 **** sub _invoke_state { ! my ($self, $sender, $event, $args, $file, $line) = @_; # Trace the state invocation if tracing is enabled. --- 224,228 ---- sub _invoke_state { ! my ($self, $sender, $event, $args, $file, $line, $fromstate) = @_; # Trace the state invocation if tracing is enabled. *************** *** 268,272 **** # Invoke the current state's leave event, if one exists. ! $self->_invoke_state( $self, 'leave', [], undef, undef ) if exists $self->[SELF_CURRENT]->{leave}; --- 269,273 ---- # Invoke the current state's leave event, if one exists. ! $self->_invoke_state( $self, 'leave', [], undef, undef, undef ) if exists $self->[SELF_CURRENT]->{leave}; *************** *** 276,280 **** # Invoke the new state's enter event, if requested. ! $self->_invoke_state( $self, $enter_event, \@enter_args, undef, undef ) if defined $enter_event; --- 277,281 ---- # Invoke the new state's enter event, if requested. ! $self->_invoke_state( $self, $enter_event, \@enter_args, undef, undef, undef ) if defined $enter_event; *************** *** 291,295 **** ] ); ! $self->_invoke_state( $self, NFA_EN_GOTO_STATE, \@args, undef, undef ); return undef; --- 292,296 ---- ] ); ! $self->_invoke_state( $self, NFA_EN_GOTO_STATE, \@args, undef, undef, undef ); return undef; *************** *** 309,313 **** $self->_invoke_state( $self, NFA_EN_GOTO_STATE, [ $previous_state, $previous_event, @$args ], ! undef, undef ); --- 310,314 ---- $self->_invoke_state( $self, NFA_EN_GOTO_STATE, [ $previous_state, $previous_event, @$args ], ! undef, undef, undef ); *************** *** 377,380 **** --- 378,382 ---- $file, # CALLER_FILE_NAME $line, # CALLER_FILE_LINE + $fromstate, # CALLER_STATE @$args # ARG0.. ); *************** *** 394,397 **** --- 396,400 ---- $file, # CALLER_FILE_NAME $line, # CALLER_FILE_LINE + $fromstate, # CALLER_STATE @$args # ARG0.. ); Index: Session.pm =================================================================== RCS file: /cvsroot/poe/poe/lib/POE/Session.pm,v retrieving revision 1.103 retrieving revision 1.104 diff -C2 -d -r1.103 -r1.104 *** Session.pm 16 Nov 2004 07:12:42 -0000 1.103 --- Session.pm 16 Nov 2004 07:54:10 -0000 1.104 *************** *** 128,141 **** sub CALLER_FILE () { 7 } sub CALLER_LINE () { 8 } ! sub ARG0 () { 9 } ! sub ARG1 () { 10 } ! sub ARG2 () { 11 } ! sub ARG3 () { 12 } ! sub ARG4 () { 13 } ! sub ARG5 () { 14 } ! sub ARG6 () { 15 } ! sub ARG7 () { 16 } ! sub ARG8 () { 17 } ! sub ARG9 () { 18 } sub import { --- 128,142 ---- sub CALLER_FILE () { 7 } sub CALLER_LINE () { 8 } ! sub CALLER_STATE () { 9 } ! sub ARG0 () { 10 } ! sub ARG1 () { 11 } ! sub ARG2 () { 12 } ! sub ARG3 () { 13 } ! sub ARG4 () { 14 } ! sub ARG5 () { 15 } ! sub ARG6 () { 16 } ! sub ARG7 () { 17 } ! sub ARG8 () { 18 } ! sub ARG9 () { 19 } sub import { *************** *** 160,163 **** --- 161,165 ---- *{ $package . '::CALLER_FILE' } = \&CALLER_FILE; *{ $package . '::CALLER_LINE' } = \&CALLER_LINE; + *{ $package . '::CALLER_STATE' } = \&CALLER_STATE; } *************** *** 563,567 **** sub _invoke_state { ! my ($self, $source_session, $state, $etc, $file, $line) = @_; # Trace the state invocation if tracing is enabled. --- 565,569 ---- sub _invoke_state { ! my ($self, $source_session, $state, $etc, $file, $line, $fromstate) = @_; # Trace the state invocation if tracing is enabled. *************** *** 630,633 **** --- 632,636 ---- $file, # caller file name $line, # caller file line + $fromstate, # caller state @$etc # args ); *************** *** 647,650 **** --- 650,654 ---- $file, # caller file name $line, # caller file line + $fromstate, # caller state @$etc # args ); *************** *** 1595,1601 **** =item CALLER_LINE ! my ($caller_file, $caller_line) = @_[CALLER_FILE,CALLER_LINE]; ! The file and line number from which this state was called. =back --- 1599,1608 ---- =item CALLER_LINE ! =item CALLER_STATE ! my ($caller_file, $caller_line, $caller_state) = ! @_[CALLER_FILE,CALLER_LINE,CALLER_STATE]; ! ! The file, line number, and state from which this state was called. =back |