r/programming • • Jun 28 '21

JavaScript Is Weird

https://jsisweird.com/
329 Upvotes

173 comments sorted by

View all comments

Show parent comments

2

u/_tskj_ Jun 28 '21

Ehh well, what the ALU does is an implementation detail and will vary from chip design to chip design. To follow IEEE 754 though, what it has to do, is evaluate0/0 to NaN. Whether you consider that "arithmetic" or not is a subjective distinction, but either way it's not that similar to an exception I don't think.