For TYPE_MARKs for which the is_static predicate is True, the Result is obviously Current
(e.g. "STRING" is the declaration_type of "STRING" and, as another example, "ARRAY[INTEGER]" is
the declaration_type of "ARRAY[INTEGER]").
Is it written one of: "BOOLEAN", "CHARACTER", "INTEGER", "INTEGER_8", "INTEGER_16", "INTEGER_32",
"INTEGER_64", "REAL_32", "REAL_64", "REAL", "REAL_80", "POINTER".
The POSITION of the first character of the Current type mark where it is originally
written.
Note that, even if has_been_specialized is True, the Result is the POSITION of the
originally written type mark (and not the position of the resolved type mark (when internally
memorized). Finally, In some very rare cases, the Result can be an is_unknownPOSITION.
As checked in the require assertion, Current is written in new_type's base class.
Also note that
we have decided to keep in the Result all the information which is available in the original
text source. Because of declaration list of the form "x, y, z: FOO", note that specialize_*
feature may be called more than once with the same new_type argument.
require
start_position.class_text = new_type.class_text
ensure
Result = Current
Result = Current
Result.has_been_specialized
is_static implies Result = Current
All the original source code information is kept in the Result:
For TYPE_MARKs for which the is_static predicate is True, the Result is obviously Current
(e.g. "STRING" is the declaration_type of "STRING" and, as another example, "ARRAY[INTEGER]" is
the declaration_type of "ARRAY[INTEGER]").
For "like Current" the declaration_type is "STRING" only and only if "like Current" is written
in the "string.e" file. When there is no generic constraint, formal generic arguments are replaced
with "ANY" (as an example, "ANY" is the declaration_type of "E_" when "E_" is written in class
"array.e"). In case of a generic constraint, this generic constraint is used in place of "ANY" for
formal generic argument (as an example, the declaration_type of a "HASHED_DICTIONARY[V_,K_]" type
mark written inside class "hashed_dictionary.e" is "HASHED_DICTIONARY[ANY,HASHABLE]").
Is it written one of: "BOOLEAN", "CHARACTER", "INTEGER", "INTEGER_8", "INTEGER_16", "INTEGER_32",
"INTEGER_64", "REAL_32", "REAL_64", "REAL", "REAL_80", "POINTER".