I'm not sure we're talking about the same thing. I'm not talking about
the variable "argument", but some variable named "a". "argument" can
be passed to $A() because it has the nature of an Array, but I don't
know anything about my variable a. So it looks like $A(a) will fail in
the case that interests me, ie if "a" is not an Enumerable and is not
something special like "argument".

To be more clear, I want to be able to call myFunc with those calls :

myFunc(1)
myFunc("fubar")
myFunc([1, "fubar"])
myFunc($$('div.comment'))
myFunc($('wrapper'))

etc.

On Aug 3, 5:45 pm, mr_justin <[email protected]> wrote:
> You could just use the arguments array.
>
> var stuff = $A(arguments).flatten();
>
> -justin
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to