Is it possible to set a variable equal to a function without using an enclosure?
<p>In JavaScript, you can set a variable equal to a method like this:</p>

<pre><code>variable = function () { alert("My name is bob"); };
</code></pre>

<p>Or like this:</p>

<pre><code>function SayMyName() {
   alert("My name is bob");
}
variable = SayMyName;
</code></pre>

<p>You can also enclose a function with arguments like so:</p>

<pre><code>function SayMyName(name) {
   alert("My name is "+ name);
}
variable = function () { SayMyName("bob"); };
</code></pre>

<p>But trying to store a variable the following way will call the function, not store it as a variable:</p>

<pre><code>function SayMyName(name) {
   alert("My name is "+ name);
}
variable = SayMyName("bob");
</code></pre>

<p>There was a clever way you used to be able to work around this by using [callee][1], but callee is depreciated and won't work on most modern browsers. </p>

<p>Is there any way to set a variable equal to a function with arguments <em>without</em> using an enclosure?</p>
