Avoid crash on invalid `expect` syntax expectations

This fixes #71.