That said, you
could make them short-circuit as well when they are all 0s or all 1s. I'm not saying we should, as I'm disinclined to introduce even a cold branch for the check, but it is a possibility.
My main concern is that if (*sigh* probably when) we adopt this proposal we collapse the whole waveform of possibilities in this space, perhaps needlessly cutting off future growth directions.
I'm willing to lose the argument here, but I think we should eventually have the argument rather than blindly take the 10%.
I also realize that if we have the argument today, it is probably a sealed deal, and I'll lose.
Since this proposal is acting as a forcing function, and I don't think I can stem the tide of opinion on this one I accept the fact that it will probably go through.
I don't have the time right now to flesh out a full proposal, and I don't even think it would be a good idea to adopt in the current state of the Haskell.
If we're talking about a counter-proposal that makes sense in the 7.10 or likely even 7.12 timeframe, I'm out.
As a fairly weak example:
Many of the other usecases that would be opened up by the alternative to this proposal are also currently blocked or rendered ugly by the shape of Bits and are complicated.
e.g. The alternative permits you to use (.&.) and (.|.) in EDSLs when you need to capture the shape of your conditionals. (As long as you ignore testBit)
An example of something lost if this proposal is adopted: Folks can't use (.&.) and (.|.) for freely overridden logical connectives in finally tagless EDSLs and have Bool just be the default interpreted case.
I can see the appeal of the proposal, it is simple.
I'm personally a weak -1 on the grounds that I think it prematurely forces us to evaluate the possibilities in this space and takes us in a direction that cuts us off from paths that could lead to greater generality in the future.
On a more immediate front, I think the small constant factor performance gain is counter-balanced by the asymptotic hit, and saying 'don't do that then' is sweeping an asymptotic issue under the rug.
I also expect that these arguments aren't going to be strong enough to beat the immediate obviousness of the proposal.
-Edward