An feature-rich, yet simple finite state machine implementation in C