A state machine implementation is often done as a "switch" statement (read "if ... elsif ..." in Perl) and can get pretty long even when most of the work for each state is factored out into individual subs. There are ways to avoid the "switch" (dispatch tables for example), but often the operation of the state machine becomes less obvious.
In reply to Re^2: Is there an ideal module size or subroutine size?
by GrandFather
in thread Is there an ideal module size or subroutine size?
by talexb
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |