Index: tools/gn/xml_element_writer.cc |
diff --git a/tools/gn/xml_element_writer.cc b/tools/gn/xml_element_writer.cc |
index 51e0488b53964abd6683cd51e7e5b0b2bf761231..a608ee305eec4ad32dc77903bbc2b9c6efffd818 100644 |
--- a/tools/gn/xml_element_writer.cc |
+++ b/tools/gn/xml_element_writer.cc |
@@ -38,7 +38,9 @@ XmlElementWriter::XmlElementWriter(std::ostream& out, |
XmlElementWriter::~XmlElementWriter() { |
if (!opening_tag_finished_) { |
- out_ << "/>" << std::endl; |
+ // The XML spec does not require a space before the closing slash. However, |
+ // Eclipse is unable to parse XML settings files if there is no space. |
+ out_ << " />" << std::endl; |
} else { |
if (!one_line_) |
out_ << std::string(indent_, ' '); |