Re: Variables and closures (Was: Objects and Relations)
Date: Fri, 9 Feb 2007 21:25:02 -0700
Message-ID: <MPG.2036f70ecccee5e39897ea_at_news.altopia.net>
Bob Badour <bbadour_at_pei.sympatico.ca> wrote:
> I don't know as much about the Java world, but the C++ world knows a
> dynamic variable is still a variable.
It really doesn't matter. If you want to push the point, though, you'll lose. From the C++ spec:
"A name is a use of an identifier (2.10) that denotes an entity or
label (6.6.4, 6.1). A variable is introduced by the declaration of an object. The variable?s name denotes the object."
In Java, variable has a different. From the Java language spec:
"A variable is a storage location and has an associated type ..."
"When an expression ... is evaluated ..., the result denotes one of three thing: ... a variable ... a value ... nothing."
Whether there is another definition of variable that includes objects is, to me, actually rather immaterial. Ditto for the discussion of whether anyone erred in using "variable" when they should have said "object". The only rational approach to the world these days is to accept that the word "variable" has multiple meanings. Figure out what is meant, and move on.
-- Chris SmithReceived on Sat Feb 10 2007 - 05:25:02 CET