> What I don't understand is the "why" of the rule. It makes Eiffel
> unnecessarily restrictive. I cannot use the cited REF class to
> encapsulate void references any more.
Yes it can, see my previous email with a suggested modification.
> Usually there should be a good reason for a validity rule. Do you know
> the reason for this rule?
It doesn't make sense to have:
a: detachable STRING
ref: TEST [detachable STRING]
ref := a
without ensuring the source `a' is attached, but we also wanted to make sure the
target will also be guaranteed to be attached. For that reason we ensured that
TARGET in a `to' conversion should be attached. Also conversion applies if the
type of the source matches the type in the Type_list which is only the case if the
type is attached, thus the requirement on SOURCE as well.
Feel free to contact ECMA for more in depth discussion as you seem interested in
changing the specification. As a reminder, the purpose of this group is to discuss
the use of Eiffel Software products and libraries (see
http://groups.eiffel.com).
Regards,
Manu