On 4/26/2014 4:39 AM, James Kuyper wrote: ....
I don't know how to put it any more clearly. In the one case, the array
as a whole is what's const, and in the other, it's the elements of the
array that are const.
No, that doesn't help. Without a specific consequence that follows from
an array being const, that wouldn't follow from it's elements being
const (or vice versa), it's just words being rearranged in pleasing
patterns.
I was prepared to hear that, if it an array's elements are not const,
but only the array itself, then those element can be written to. That
interpretation would make a "const array of int" indistinguishable from
an "array of int". Given the history that's been given for "B", "C"'s
ancestor, that would even make sense - the thing that was changeable in
B is, in C, only changeable for pointers, not arrays, so all C arrays
could b e considered 'const' in that sense. But you've made no such
assertions.
....
Not that I know of. That doesn't mean there isn't a difference to the
users of the phrase. That just means the difference isn't extensional.
I've looked up the term "extensional"
<
http://en.wikipedia.org/wiki/Extensional>, which I've not seen used
with this meaning before. The definitions I found left me just as
confused about what you meant as I was before I read that definition. I
can understand the examples given in that article - I don't see the
applicability in this context. That article explains that, if Lois Lane
believes that Clark Kent will be investigating a given case with her,
then it is not true that she believes Superman will be investigating the
case with her, because she's unaware that they're the same person.
That's because statements about what her beliefs are, are inherently
intensional.
So, if someone believes that a const array of int is in some way
different from an array of const int, the are intensionally different,
even if that person is mistaken? If that's what you're talking about,
then I don't see any point in worrying about intensional differences;
only the extensional ones really matter to me. If there are intensional
difference without corresponding extensional differences, that is an
issue of great importance to those, such as teachers, whose job it is to
correct that discrepancy, but even for them, the intensional difference
is important only in a very negative sense.
Since I don't remember having ever heard of these terms before, it could
be I'm totally misunderstanding the extensional/intensional distinction,
and therefore radically misusing it in the preceding paragraph. If so,
I'd a appreciate a better explanation of it.