Why static analysis is the way to go
H. S. Teoh
hsteoh at qfbox.info
Fri May 29 14:52:55 UTC 2026
On Fri, May 29, 2026 at 02:51:28AM +0000, monkyyy via Digitalmars-d wrote:
[...]
> I struggle with big projects but line counts and stupid problems to
> have are not a measurement of success.
Big projects are not my choice. My boss assigned me to work on a 2M LOC
codebase consisting of an entire OS with a large suite of daemons,
databases, and other modules running on embedded hardware. A lot of the
code is written in C, a significant part of which is legacy code from
20+ years ago when coding standards were (very) different. Hacks like
casting (the same!) void* into multiple, incompatible structs is a
thing. As is casting a struct pointer into a char* and writing raw
bytes into it. And passing around variadic struct pointers and writing
past the end (because the caller is assumed to have allocated enough
space for it -- and no, the allocated size isn't told to the callee).
And Schlemiel string manipulation everywhere (I recently was assigned to
clean up after some of his work -- nice guy, but very inefficient :-P).
I don't know what success means in this context. It pays the bills, I'm
not complaining. End of story.
Beauty in engineering is something that only matters when I'm writing D.
:-P
T
--
I am not young enough to know everything. -- Oscar Wilde
More information about the Digitalmars-d
mailing list