Fix literal validation errors
Fix dynamically built up errors

fixes #1653 on github