diff --git a/rosidl_generator_type_description/rosidl_generator_type_description/__init__.py b/rosidl_generator_type_description/rosidl_generator_type_description/__init__.py index ba1c2990a..3e2d23116 100644 --- a/rosidl_generator_type_description/rosidl_generator_type_description/__init__.py +++ b/rosidl_generator_type_description/rosidl_generator_type_description/__init__.py @@ -415,6 +415,8 @@ def field_type_capacity(ftype: definition.AbstractType) -> int: if isinstance(ftype, definition.AbstractNestedType): if isinstance(ftype, definition.Array): return ftype.size + elif isinstance(ftype, definition.BoundedSequence): + return ftype.maximum_size return 0