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

Re: A keyword data type

My purpose in suggesting a keyword data type was to make a definite
distinction between symbols and keywords.  Making one a subtype of the
other does not do this.  A type/subtype relation does not merely depend
on commonality of operations, but of purpose and use.  Keywords and
symbols do not serve the same purpose.  Keywords are used as symbolic
literals, while symbols are used as identifiers (i.e., indirect
references to values, functions, etc.).  Thus, it does not seem right
to make one the subtype of the other.  My own suggestion would be to
call symbols identifiers and create a new type called symbols which
is a super of both identifier and keyword, e.g.,

		       /      \
		 identifier  keyword

Unfortunately, this suggestion would introduce even more terminology
changes; so it goes.