diff --git a/libuavcan/dsdl_compiler/data_type_template.hpp b/libuavcan/dsdl_compiler/data_type_template.hpp index 35cc99e258..69f9be1367 100644 --- a/libuavcan/dsdl_compiler/data_type_template.hpp +++ b/libuavcan/dsdl_compiler/data_type_template.hpp @@ -249,6 +249,13 @@ ${define_yaml_streamer(t.cpp_full_type_name, t.fields)} } +% for nsc in t.cpp_namespace_components: +namespace ${nsc} +{ +% endfor +namespace +{ + <%def name="define_streaming_operator(type_name)"> template inline Stream& operator<<(Stream& s, ${type_name}::ParameterType obj) @@ -264,3 +271,8 @@ ${define_streaming_operator(t.cpp_full_type_name + '::Response')} ${define_streaming_operator(t.cpp_full_type_name)} % endif +} +% for nsc in t.cpp_namespace_components: +} +% endfor +