parameters: (bases, message_descriptor, dictionary)
return_statement: return tuple(new_bases)
docstring: Creates a new protocol message *class*.
docstring_summary: Creates a new protocol message *class*.
docstring_tokens: Creates a new protocol message * class * .
function: def NewMessage(bases, message_descriptor, dictionary):
    """Creates a new protocol message *class*."""
    new_bases = []
    for base in bases:
      if base is message.Message:
        # _message.Message must come before message.Message as it
        # overrides methods in that class.
        new_bases.append(_message.Message)
      new_bases.append(base)
    return tuple(new_bases)
function_tokens: def NewMessage ( bases , message_descriptor , dictionary ) : new_bases = [ ] for base in bases : if base is message . Message : # _message.Message must come before message.Message as it # overrides methods in that class. new_bases . append ( _message . Message ) new_bases . append ( base ) return tuple ( new_bases )