Added naive compilation of `wait` statement.