[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: require() passing arguments to module?
- From: Rob Hoelz <rob@...>
- Date: Fri, 04 Nov 2011 21:45:49 -0500
+1 to this idea.
Sent from my Android phone with K-9 Mail. Please excuse my brevity.
HyperHacker <firstname.lastname@example.org> wrote:
I feel like this idea has been brought up before, but I don't recall
the consensus. Presently, require() accepts only one argument. Why not
change it to require(name, ...) and pass all additional args on to the
module? The module can then retrieve them from ... just as it would if
you did loadfile(name)(...).
Sent from my toaster.