def record(*a, **kw):
if len(a) == <NUM_LIT:1>:<EOL><INDENT>attributeNames = a[<NUM_LIT:0>].split()<EOL><DEDENT>elif len(a) == <NUM_LIT:0>:<EOL><INDENT>if not kw:<EOL><INDENT>raise TypeError("<STR_LIT>")<EOL><DEDENT>attributeNames = kw.keys()<EOL>attributeNames.sort()<EOL><DEDENT>else:<EOL><INDENT>raise TypeError(<EOL>"<STR_LIT>")<EOL><DEDENT>defaults = []<EOL>for attributeName in attributeNames:<EOL><INDENT>default = kw.pop(attributeName, _NOT_SPECIFIED)<EOL>if defaults:<EOL><INDENT>if default is _NOT_SPECIFIED:<EOL><INDENT>raise TypeError(<EOL>"<STR_LIT>"<EOL>"<STR_LIT>"<EOL>"<STR_LIT>")<EOL><DEDENT>else:<EOL><INDENT>defaults.append(default)<EOL><DEDENT><DEDENT>elif default is not _NOT_SPECIFIED:<EOL><INDENT>defaults.append(default)<EOL><DEDENT>else:<EOL><INDENT>pass<EOL><DEDENT><DEDENT>if kw:<EOL><INDENT>raise TypeError("<STR_LIT>" % (kw,))<EOL><DEDENT>return type('<STR_LIT>' % ('<STR_LIT:U+0020>'.join(attributeNames),),<EOL>(StructBehavior,),<EOL>dict(__names__=attributeNames,<EOL>__defaults__=defaults))<EOL>
Are you tired of typing class declarations that look like this::

    class StuffInfo:
        def __init__(self, a=None, b=None, c=None, d=None, e=None,
                     f=None, g=None, h=None, i=None, j=None):
            self.a = a
            self.b = b
            self.c = c
            self.d = d
            # ...

Epsilon can help!  That's right - for a limited time only, this function
returns a class which provides a shortcut.  The above can be simplified
to::

    StuffInfo = record(a=None, b=None, c=None, d=None, e=None,
                       f=None, g=None, h=None, i=None, j=None)

if the arguments are required, rather than having defaults, it could be
even shorter::

    StuffInfo = record('a b c d e f g h i j')

Put more formally: C{record} optionally takes one positional argument, a
L{str} representing attribute names as whitespace-separated identifiers; it
also takes an arbitrary number of keyword arguments, which map attribute
names to their default values.  If no positional argument is provided, the
names of attributes will be inferred from the names of the defaults
instead.