Re: casting



Richard Heathfield <invalid@xxxxxxxxxxxxxxx> writes:
jaysome said:

<snip>

So what you're saying is that the consequences of "implementation
defined behaviour" could be the same as the consequences of "undefined
behaviour"?

If that were the case, and I'm not saying that it is or isn't,
shouldn't we expect some hard-core pedantics to start telling us that
use of "implementation defined behaviou" could lead to formatting of
our hard drives?

It *can*. And in some cases it does.

The difference is that, for implementation-defined behaviour, the
implementation is required to *document* this effect. If you want to format
your drive, such a feature can be extremely useful, n'est-ce-pas?

The other difference is that, in the case of implementation-defined
behavior, the standard provides two or more possibilities and the
implementation has to pick one of them. (Unspecified behavior is the
same, except that the implementation needn't document its choice.)

These terms are all defined in section 3 of the standard.

--
Keith Thompson (The_Other_Keith) kst-u@xxxxxxx <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <*> <http://users.sdsc.edu/~kst>
We must do something. This is something. Therefore, we must do this.
.



Relevant Pages

  • Re: casting
    ... If that were the case, and I'm not saying that it is or isn't, ... use of "implementation defined behaviou" could lead to formatting of ... our hard drives? ...
    (comp.lang.c)
  • Re: casting
    ... If that were the case, and I'm not saying that it is or isn't, ... use of "implementation defined behaviou" could lead to formatting of ... our hard drives? ...
    (comp.lang.c)
  • Re: AS/400 savsys on 1gb or 2gb QIC needed for Model 436
    ... So are you saying that I cannot do a scratch install of V4R3M0? ... after formatting the hard drives? ...
    (comp.sys.ibm.as400.misc)
  • Re: advance="no" not portable
    ... formatting, and you have found *EXACTLY* the reason why not. ... The standard allows a compiler is allowed to start new records quite ... diagnosing problems. ...
    (comp.lang.fortran)
  • Re: backspace error (reading file from the end)
    ... using list-directed or namelist formatting. ... That's an "interesting" restriction in the standard. ... The fact that some implementations disallow backspace on some files ...
    (comp.lang.fortran)