News for hackers. Stuff that matters.
Re:Some simple tricks in C/C++ by eqvinox on Wednesday May 06, 2020 @01:22PM (#23093732)
I'm very much not a fan of indiscriminately typedef'ing structs. To me, a typedef describes a type as a "fundamental atom". Most structs are ... not that.

FWIW I also apply the above meaning for typedefs of integer types. It's an indicator for a "stronger" API boundary, i.e. you shouldn't mess with the contents.

Also this "Int" typedef in the article triggers a punch reflex for me. Would give it a hard NAK in any type of review. (Because it would lead to more WTFs in long-term maintenance of the code.)

There are no comments on this comment yet.