code: def format_data_type(self, data_type):
          
          s = data_type.name
          for type_class, key_list in self._data_type_map:
              if isinstance(data_type, type_class):
                  args = []
                  for key in key_list:
                      val = getattr(data_type, key)
                      if val is not None:
                          if isinstance(val, AstTypeRef):
                              sval = val.name
                          elif isinstance(val, DataType):
                              sval = self.format_data_type(val)
                          else:
                              sval = self.format_value(val)
                          args.append(key + '=' + sval)
                  if args:
                      s += '(' + ', '.join(args) + ')'
                  break
          if data_type.nullable:
              s += '?'
          return s
docs: Helper function to format a data type.
  
          This returns the name if it's a struct or union, otherwise
          (i.e. for primitive types) it renders the name and the
          parameters.