From 082805b2f124f0dfe8583105a39bbeaf10308f8e Mon Sep 17 00:00:00 2001 From: Pavel Kirienko Date: Mon, 3 Mar 2014 22:14:37 +0400 Subject: [PATCH] Generated types can be compiled sucessfully now --- libuavcan/dsdl_compiler/data_type_template.hpp | 1 + libuavcan/include/uavcan/data_type.hpp | 1 - libuavcan/include/uavcan/internal/marshal/array.hpp | 5 +++++ libuavcan/include/uavcan/internal/marshal/float_spec.hpp | 3 +++ libuavcan/include/uavcan/internal/marshal/integer_spec.hpp | 3 +++ 5 files changed, 12 insertions(+), 1 deletion(-) diff --git a/libuavcan/dsdl_compiler/data_type_template.hpp b/libuavcan/dsdl_compiler/data_type_template.hpp index e92e2d374e..2ad377ed54 100644 --- a/libuavcan/dsdl_compiler/data_type_template.hpp +++ b/libuavcan/dsdl_compiler/data_type_template.hpp @@ -10,6 +10,7 @@ #include #include +#include #include % for inc in t.cpp_includes: diff --git a/libuavcan/include/uavcan/data_type.hpp b/libuavcan/include/uavcan/data_type.hpp index 0a8f6156bd..83ed51d0f5 100644 --- a/libuavcan/include/uavcan/data_type.hpp +++ b/libuavcan/include/uavcan/data_type.hpp @@ -9,7 +9,6 @@ #include #include #include -#include namespace uavcan { diff --git a/libuavcan/include/uavcan/internal/marshal/array.hpp b/libuavcan/include/uavcan/internal/marshal/array.hpp index cf6f1019f2..57c6981d18 100644 --- a/libuavcan/include/uavcan/internal/marshal/array.hpp +++ b/libuavcan/include/uavcan/internal/marshal/array.hpp @@ -298,6 +298,11 @@ public: return array.decodeImpl(codec, tao_mode, BooleanType()); } + static void extendDataTypeSignature(DataTypeSignature& signature) + { + RawValueType::extendDataTypeSignature(signature); + } + bool empty() const { return size() == 0; } void pop_back() { Base::shrink(); } diff --git a/libuavcan/include/uavcan/internal/marshal/float_spec.hpp b/libuavcan/include/uavcan/internal/marshal/float_spec.hpp index 0b9cb581b5..9ff1c84554 100644 --- a/libuavcan/include/uavcan/internal/marshal/float_spec.hpp +++ b/libuavcan/include/uavcan/internal/marshal/float_spec.hpp @@ -7,6 +7,7 @@ #include #include #include // Needed for isfinite +#include #include #include #include @@ -130,6 +131,8 @@ public: return res; } + static void extendDataTypeSignature(DataTypeSignature&) { } + private: static inline void saturate(StorageType& value) { diff --git a/libuavcan/include/uavcan/internal/marshal/integer_spec.hpp b/libuavcan/include/uavcan/internal/marshal/integer_spec.hpp index 285f9af71c..817ca3b840 100644 --- a/libuavcan/include/uavcan/internal/marshal/integer_spec.hpp +++ b/libuavcan/include/uavcan/internal/marshal/integer_spec.hpp @@ -6,6 +6,7 @@ #include #include +#include #include #include #include @@ -98,6 +99,8 @@ public: validate(); return codec.decode(out_value); } + + static void extendDataTypeSignature(DataTypeSignature&) { } }; template