added poc of semantic substitution
fixed some whitespace issues in the parser