bunch of syntax fixes