Fix boundary condition on an assert.

Fixes #1324
Report the right token in the error message.

Fixes #1322
Remove invalid example