Re: [sv-ec] mantis item 3279

From: Jonathan Bromley <jonathanbromley@ymail.com>
Date: Tue Feb 22 2011 - 06:36:09 PST

Shalom
Note that 6.22.3 already says, "Compatibility can be in one direction only. For
example, an enum can be converted to an integral type without
>a cast, but not the other way around. Implicit casting rules are defined in
>6.24." I agree that this statement is not sufficient, as it does not say when it
>is unidirectional and when it is bidirectional, but it already expresses the
>possibility that this can occur.
I agree, but the statement is useless because nowhere is it defined *which way*
is meant when you say "A is assignment compatible with B". The preposition
"with" doesn't carry any sense of direction, as far as I understaind it.

More importantly, if you redefine 'assignment compatible', then it is also
necessary to examine all 30 uses of the term in the LRM to clarify in each
whether the compatibility is unidirectional or bidirectional.
One might reasonably argue that such review is overdue. I've just scanned the
LRM and it seems that the usage is consistently "source is assignment compatible
with destination", although there are a few places where two things are required
to be baldly "assignment compatible" without it being clear whether this is a
bidirectional requirement.

In reality the assignment-compatibility wording is probably just about OK, and I
don't want to waste people's time with unnecessary legalities, but I remain
convinced that the LRM would benefit overall from a much more rigorous style of
definition.

Jonathan

      

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Tue Feb 22 06:36:34 2011

This archive was generated by hypermail 2.1.8 : Tue Feb 22 2011 - 06:36:38 PST