diff --git a/tools/generate-bolts.py b/tools/generate-bolts.py index c1392b300..096f1d0ba 100755 --- a/tools/generate-bolts.py +++ b/tools/generate-bolts.py @@ -50,6 +50,15 @@ class Field(object): self.is_optional = optional self.field_comments = field_comments + def __deepcopy__(self, memo): + deepcopy_method = self.__deepcopy__ + self.__deepcopy__ = None + field = copy.deepcopy(self, memo) + self.__deepcopy__ = deepcopy_method + + field.type_obj = self.type_obj + return field + def add_count(self, count): self.count = int(count) diff --git a/tools/test/test_cases b/tools/test/test_cases index 1eda0352f..eb87c3c1b 100644 --- a/tools/test/test_cases +++ b/tools/test/test_cases @@ -40,6 +40,8 @@ msgdata,test_msg,test_sbt_varsize_var_assign,subtype_var_assign, msgdata,test_msg,test_sbt_var_len,subtype_var_len, msgdata,test_msg,test_sbt_varlen_varsize,subtype_varlen_varsize, msgdata,test_msg,test_sbt_arrays,subtype_arrays, +# test extension fields +msgdata,test_msg,extension_1,test_features,,option_short_id msgtype,test_tlv1,2 msgdata,test_tlv1,test_struct,test_short_id,