subtle state error in grammar/sequence