Throw an error on unbalanced expressions
Merge pull request #80 from olasd/bugfix/unbalanced-expressions

Correctly handle unbalanced expressions