Fix assumption that `state(0)` is the same as `start_state`.

This fixes #111.