Specification of language X says:
- The behaviour of ~0 is implementation defined, but may not be positive.
- The behaviour of 0^0 is undefined.
Implementation S specifies that ~0 equals -1.
Implementation T specifies that ~0 equals 1. Neither defines what 0^0 means. Program P contains ~0. Program R contains 0^0. Running P on S produces -1. Running R on S locks up the OS requiring a reboot. S is confirming. Running P on T produces 1. Running R on T produces an error message. T is not confirming.
Implementation defined means that the feature is a valid feature, and it's up to each implementation to define what it means. Undefined behaviour basically means the feature is not valid, and implementations do not define what happens.
But let me guess, you're still going to claim to not understand the difference, right? | [reply] |
Specifications specify, they do not define. Define is defined as: To describe, explain, or make definite and clear;. You cannot define what will be; only what is.
Implementations do not define, they implement. If they implement the specifications incorrectly--whether by design or error--the resultant behaviour does not meet the specification and so is not conforming; but the behaviour, whatever it may be, still exists. And by recording that behaviour, that behaviour is defined. Right or wrong, the behaviour is described; explained; made definite and clear. Conformant or not, that implementation's behaviour is defined by what actually happens.
Just as a child's behaviour is defined (described, explained etc.), by what they actually do; not by what his mother says they should or will do.
If specifications defined, then no implementation could ever be in error. Not just unreasonable or illogical, but impossible.
If implementations defined, then the first implementation's choices--bugs'n all--would forever preclude any other implementation from doing anything different--whether by design or error. Again, unreasonable, illogical and impossible.
There is a world of difference between "implementation defined" (which should almost certainly be "implementor's define" or better "decide"), and 'defined by the implementation'.
The former implies predefinition. And the very existance of that word implies that before-the-fact decisions are quite different from after-the-fact determinations.
But let me guess, you're still going to claim to not understand the difference, right?
Wrong! I understand the difference that the two phrases are intended to signify. My hope was that the process of trying to differentiate the phrases in writing would make their failure to meet those intents, as clear to you as they are to me.
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
| [reply] |