This is the mail archive of the
mailing list for the libstdc++ project.
Re: [libstdc++ PATCH] TR1 'function' and 'mem_fn' support
Douglas Gregor wrote:
I think I probably now agree. The only minor problem I have with the
macro-based system is slightly harder to later increase the limit,
should someone want to use tuples / function_wrappers / whatever with
>10 arguments / elements. I shall however agree with the maintainers on
this issue :)
On Jan 29, 2005, at 8:44 AM, Chris Jefferson wrote:
Paolo Carlini wrote:
Chris Jefferson wrote:Attached is the most recent version of the maketuples.c program,
which generates the header is is currently in the CVS. It could
perhaps do with a little more documenting, but I think it's reasonable.
I'm happy to adapt my tuple generation program to generate this
header, which would have the advantage it would remove of 10 on the
maximum size. Of course this leads to other problems which I'm not
positive how to fix.... but it seems like it's not impossible
someone might hit the 10-parameter (I've seen functions with more,
although not in very nice code)
By the way: *where* is it (the tuple generation program)?!?
Assuming we really we want to go this way, we should provide it and
document its usage.
It seems like maintaining the code for TR1 in a set of C generator
programs will be significantly harder than their preprocessor-based
counterparts. The functional_iterate.h I submitted is annoying to work
with (because one has to use macros for parameter lists and such), but
it retains the essential structure of C++ code and it's easy to make
minor tweaks to the source.
If we're concerned about preprocessing time, we can always preprocess
all of the includes of functional_iterate.h for some number of
parameters as part of configuration.