Daniel Berlin <[EMAIL PROTECTED]> writes:

> > The builtins table is initialized with a separate .def file, but it
> > boils down to initializers this:
> > 
> >   { code, "__builtin_name", C2_INT,
> >    { C2_INT, C2_VPTR, C2_NONE, C2_NONE, C2_NONE, C2_NONE } },
> > 
> > This way I only have to write the type in one place, I only create the
> > function types I need, and the types are cached so I don't create the
> > same type more than once.
> > 
> > Much simpler in the long run, I think.
> 
> How are you handling putting attributes on these builtin functions?

I didn't bother to show it, but I also have a code for which type of
attribute they should take.  I build a table indexed by the code, and
pass the appropriate entry in to builtin_function.  That part of it is
basically the way that builtins.def works today.

Ian

Reply via email to