* refactor grammar and assembler to be cleaner