More improvements to comment handling