Skip to content

Commit

Permalink
Remove duplicated printing of component members (#270)
Browse files Browse the repository at this point in the history
  • Loading branch information
tmadlener authored Mar 23, 2022
1 parent d00f8cf commit 1dc1723
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
5 changes: 0 additions & 5 deletions python/templates/macros/implementations.jinja2
Original file line number Diff line number Diff line change
Expand Up @@ -181,11 +181,6 @@ std::ostream& operator<<(std::ostream& o, const {{ type }}& value) {
{% else %}
o << " {{ member.name }} : " << value.{{ member.getter_name(get_syntax) }}() << '\n';
{% endif %}
{% if member.sub_members %}
{% for sub_member in member.sub_members %}
o << " {{ member.name }}: " << value.{{ sub_member.getter_name(get_syntax) }}() << '\n';
{% endfor %}
{% endif %}
{% endfor %}

{% for relation in single_relations %}
Expand Down
6 changes: 6 additions & 0 deletions tests/datalayout.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,12 @@ datatypes :
OneToOneRelations:
- ExampleCluster cluster // a particular cluster

ExampleWithArrayComponent:
Description: "A type that has a component with an array"
Author: "Thomas Madlener"
Members:
- SimpleStruct s // a component that has an array

ExampleWithComponent :
Description : "Type with one component"
Author : "Benedikt Hegner"
Expand Down

0 comments on commit 1dc1723

Please sign in to comment.