Corrected typos
Centralize creating indexes of state classes in the reference implementation.
Licensed under The BSD 3-Clause License
Changed the logic of invoking the OnArrival method. Now if the message recipient returns the FSM::idx_nochange index then the OnArrival does not run. Otherwise it runs, even if the state did not change. This is done to allow messages "looping" an FSM from a state to itself.