Hacker News new | comments | show | ask | jobs | submit login

I've gotten a bit pissed at the Microsoft C compiler for (1) having no standard way to generate NaN or Infinity and (2) having a good enough static analyzer that if you generate one by casting, it emits a warning saying that your arithmetic overflows.

Gee, thanks MSC. I didn't expect "x = INFINITY;" to overflow.




0/0 should be NaN, 1/0 should be +Infinity, -1/0 should be -Infinity. (I haven't tried that in a while).

Also check the flags, like /fp:precise for MSVC

-----




Applications are open for YC Summer 2016

Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | DMCA | Apply to YC | Contact

Search: