Unrelatedly, why does their sample code ( https://man.netbsd.org/NetBSD-1.3/readdir.3 ) have a line while ((dp = readdir(dirp)) != NULL), what's the point of doing a comparison != NULL if that's exactly the same behaviour as just omitting it? I'd expect sample code to not waste characters on a comparison that's completely unnecessary... Is there some edge case that I'm unaware of where it's different? ![]()
@vaporeon_ these days developers tend to prefer clarity over brevity. it's very normal to write extra code if the programmer thinks it is easier to understand that way
@wallhackio I just don't think that it adds any clarity at all...
@wallhackio @vaporeon_ eh you should at least be consistent within a codebase with the choices you make, which is my actual opinion about these sorts of matters of style and convention and layout and such