Remix.run Logo
croes 4 days ago

Sometimes good names etc. don’t help. Think of this

https://en.wikipedia.org/wiki/Fast_inverse_square_root

That definitely needs a what comment.

Scarblac 4 days ago | parent [-]

Yes of course, sometimes there is no understandable way to write the code and comments are the best way.

But there's also the case to be made that the comments that particular code needs are "why" comments. I can see what happens, but why does it work?

croes 3 days ago | parent [-]

Why does it work or why was the code written?

The article mentions the reason for the code which I would expect in the commit message