[Date Prev][Date Next][Thread Prev][Thread Next][Author Index][Date Index][Thread Index]

Re: name for SEFTable

Now that I've cooled down a bit from "hobgoblin"...

tribble> How about ConstTable or ConstantTable.  That's essentially what it is.

tribble> If we can agree that the semantics of ConstTables does in fact
tribble> parallel the const declaration, then let's use it!

Sounds good to me IFF it's characteristics match those of a const in C++.

markm>    (note that we can't say ConstX,
markm>    because that isn't symmetrical with our other names),

How is this asymmetrical?

markm>   Shouldn't that be spelled "ConsTable"?
tribble> No.  I like ConstTable.

While ConstTable is hard to spell and pronounce, I agree with Dean that
it's the right way to combine Const and Table, precicely because of the
collisions with "Cons" that markm noted.

tribble> (For a class to deserve the name
tribble> const, all member functions defined for it should be declared
tribble> 'const').

No.  For a class to deserve the name "const", it should be impossible to
change the (apparent) state of the object once it has been constructed.
This does not necessarily mean that variables, member functions, arguments
to member functions, or anything else associated with the object (except
public variables, which we try to avoid) should be declared "const".  It
just means no public member functions change the object's state memory.

Note that friends might actually change internals in invisible-to-non-
friend ways.  Examples:  Paging in virtual-memory objects, ref counts.

markm> Replaying our latter phone
markm> conversation, it is interesting to note that C++'s (and ANSI C's?)
markm> "const" corresponds to our ScruX, not our ImmuX.

That's also an argument that ImmuX and ScruX are both the wrong names for
whatever they're currently naming.  As I read the manuals, the meaning of
"const" is "It is an error to try to change the state of this thing."
I get that from "immutable" as well.  From "scrutable" I get "You can
understand this thing." which stretches to "You can read it."  but doesn't
reach "You can't change it.".