I apologize beforehand for the muddleheadedness of this question. It reflects the fact that I'm trying to interpret outward "behaviors" of Mathematica expressions without having any understanding of the scheme underlying these behaviors.
Among symbols that are "defined" (whatever this means), those that have head Function seem to be fundamentally different from most others in that they "respond" to a trailing square-bracket-delimited subexpression:
{Function[{}, 5], Function[{}, 5][]}
{Function[{}, 5], 5}
{3, 3[]}
{3, 3[]}
(I'm using the verb "respond" as the opposite of what happens when Mathematica's evaluation, as in the case of 3[], produces no visible change at all, not even a warning or error message.)
What is the difference in the ways that Mathematica evaluates Function[{}, 5][] and 3[] that accounts for the fact that the former returns something different from itself, but not the latter?
Is there a way to display a breakdown Mathematica's evaluation that clearly shows the basis of this difference?
One other head I know of that marks items that "respond" to a trailing [...] is Association (the "response" is either the value associated with the "key" in the [...], if such exists, or an item with head Missing). Are there any others?
Unfortunately, this question is muddled by this sort of thing:
ClearAll[foo];
{foo, foo[5]}
foo[5] = 4; {foo, foo[5]}
{foo, foo[7]}
Head[foo]
{foo, foo[5]}{foo, 4}
{foo, foo[7]}
Symbol
IOW, under some circumstances, an item with head Symbol will "respond" to some trailing [...] expressions. Hmph...
Functionconstruct is special, and has a special evaluation semantics, which is why you see the difference. Also, read this. – Leonid Shifrin May 08 '15 at 13:17Function[{}, 5][]is equivalent to5&[], not5[]. I don't claim very deep knowledge, but one of the lessons to learn from Leonid's link, is that a function is a bit different from a replacement rule that's created when you give a symbol a DownValue. I hope, however, that if I'm grossly inaccurate, the more knowledgeable folks will correct me here. – LLlAMnYP May 08 '15 at 13:34