Re: Finding the instance reference of an object
greg <greg@cosc.cant erbury.ac.nzwri tes:
Personally, I find this whole debate kind of silly, as it is based on
a completely fallacious either/or dichotomy.
(1) It is unarguably true that Python and Java use a type of
call-by-value. This follows from the standard definition of
call-by-value, and common usage in, for example, the Scheme and
Java communities, etc.
(2) It is also unarguably true that saying that Python or Java use
"call-by-value", and saying nothing more is going to be profoundly
confusing to anyone who is learning these languages.
It's like the difference between
Q. What is a giraffe?
A. A giraffe is a type of animal.
and
Q. What is Greg?
A. Greg is a type of animal.
In both cases, the answers are strictly correct, but in the second
case, the answer is also deeply misleading.
Q. How do we generally solve this problem when speaking?
A. We invent more specific terms and then generally stick to the more
specific terms when the more general terms would be misleading.
I.e.,
Q. What is Greg?
A. Greg is a human being.
and
Q. What type of calling semantics do Python and Java use?
A. Call-by-sharing.
I assert that anyone who does not understand all of the above, is
helping to spread confusion.
|>oug
greg <greg@cosc.cant erbury.ac.nzwri tes:
Steven D'Aprano wrote:
>At least some sections of the Java community seem to prefer a
>misleading and confusing use of the word "value" over clarity and
>simplicity, but I for one do not agree with them.
>misleading and confusing use of the word "value" over clarity and
>simplicity, but I for one do not agree with them.
I don't see anything inherently confusing or misleading
about it. Confusion only arises when some people jump up
and say that it's wrong to use the terms that way, because
it might cause confusion...
about it. Confusion only arises when some people jump up
and say that it's wrong to use the terms that way, because
it might cause confusion...
a completely fallacious either/or dichotomy.
(1) It is unarguably true that Python and Java use a type of
call-by-value. This follows from the standard definition of
call-by-value, and common usage in, for example, the Scheme and
Java communities, etc.
(2) It is also unarguably true that saying that Python or Java use
"call-by-value", and saying nothing more is going to be profoundly
confusing to anyone who is learning these languages.
It's like the difference between
Q. What is a giraffe?
A. A giraffe is a type of animal.
and
Q. What is Greg?
A. Greg is a type of animal.
In both cases, the answers are strictly correct, but in the second
case, the answer is also deeply misleading.
Q. How do we generally solve this problem when speaking?
A. We invent more specific terms and then generally stick to the more
specific terms when the more general terms would be misleading.
I.e.,
Q. What is Greg?
A. Greg is a human being.
and
Q. What type of calling semantics do Python and Java use?
A. Call-by-sharing.
I assert that anyone who does not understand all of the above, is
helping to spread confusion.
|>oug
Comment