--- TOGoS <[EMAIL PROTECTED]> wrote: > > Leopold Toetsch wrote: > > TOGoS wrote: > >>>> Unprototyped :-) I guess I didn't make that > >>>> quite clear, enough. > >>> > >>> Setup a param array, that's all. > >>> > >>> leo > >> Umm... OK. Here's what I've done: I created 2 > >> functions that I can use when dealing > >> with variable-length parameter lists. One > >> to turn an array into pcc-compliant parameters, > > > > Wrong approach AFAIK. Just pass the array as one > > param. Its like the > > slurpy [EMAIL PROTECTED] in Perl6. In printstuff you then > iterate > > over this array and > > print items. > > > > leo > > But how is the caller supposed to know to do that? > Remember, I plan to get the 'printstuff' function by > saying:
Oh. Nevermind. I see what you mean, now. Don't do printstuff(*params) , but just do printstuff(params) instead. I can't think of an example off the top of my head where this wouldn't work, but it will happen that people'll want to use variable-length parameter lists on unprototyped functions (like the anonymous perl6 slurpy function). Also, Ruby's 'print' works like this. So it will have to be dealt with. __________________________________ Do you Yahoo!? Yahoo! SiteBuilder - Free, easy-to-use web site design software http://sitebuilder.yahoo.com