Or does the term "value" already exclude functions?
I'm trying to explain why (in JavaScript, for instance) calling foo(2 + 2)
is different from calling foo(() => 2 + 2)
, (assuming foo
can handle a function as argument for the purpose of lazily computing a value). In the first example, the argument that foo
receives is 4
, while in the second, the argument it receives is the function () => 2 + 2
itself. I want to describe the difference as "passing a value" versus "passing a function", but I'm wondering if there's a more precise term.