forked from enlightenment/efl
csharp: Escape contents of struct fields' value tag.
Summary: In structs' definition, field `<value>` tags weren't scaping characters, so characters like "&" would lead to invalid XML errors. Fixes T8588. Test Plan: Run ninja test. Reviewers: segfaultxavi Reviewed By: segfaultxavi Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T8588 Differential Revision: https://phab.enlightenment.org/D11202
This commit is contained in:
parent
fdf0aee35c
commit
5d982dd985
|
@ -564,12 +564,13 @@ struct struct_definition_generator
|
|||
// iterate struct fields
|
||||
for (auto const& field : struct_.fields)
|
||||
{
|
||||
if (!as_generator(documentation(indent.n + 1)).generate(sink, field, context))
|
||||
auto docs = documentation(indent.n + 1);
|
||||
if (!as_generator(docs).generate(sink, field, context))
|
||||
return false;
|
||||
|
||||
if (!field.type.doc_summary.empty())
|
||||
{
|
||||
if (!as_generator(indent << scope_tab << "/// <value>" << field.type.doc_summary << "</value>\n").generate(sink, attributes::unused, context))
|
||||
if (!docs.generate_tag_value(sink, field.type.doc_summary, context))
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue