Fixed various parse issues. I should write "function" on the blackboard 100 times...