Add codegen for if, if-else and while.