Correctly manage comment nodes