*shuts laptop forever*pic.twitter.com/3GS1JfNDSP
You can add location information to your Tweets, such as your city or precise location, from the web and via third-party applications. You always have the option to delete your Tweet location history. Learn more
The C example is not very strange or bizarre - it is a result of sign extension. https://en.wikipedia.org/wiki/Sign_extension …
I think new languages should make promises that == is always false if the values are not actually equal (no lossy implicit conversions).
Signed/unsigned comparison errors would rule this out. (i.e: enable -Werror=sign-compare and every warning flag you can get your hands on)
Wouldn't rule out the floating point version though.
And would be painful to use. The right solution for new languages moving forward is defining == in terms of actual value equality, even when the types make it require more code to implement the comparison.
cost model suffers, for such a low level language. explicit expensiveness may be better.
When the cost matters you can always use matching types, either for the underlying operands in the expressions or both sides or by casting one or both sides.
(1<<28)+1==0x1p28f is misleading. (float)((1<<28)+1)==0x1p28f is obviously reasonable.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.