Yo Greg! On Wed, 19 Nov 2025 08:34:01 -0500 Greg Troxel <[email protected]> wrote:
> Hal Murray <[email protected]> writes: > > > [email protected] said: > >> The standard approach is: > >> Use %d for int, %ld for long. > >> Use PRI macros for other types. > > > > I find the PRI stuff hard to read. Maybe I just need more > > practice. I'd much rather cast the parameter to a long. > > Makes sense, but properly to intmax_t and %j. And then you have to pull in intptr_t, and things get real weird. intmax_t and intprt_t are rare enough that it adds cognitive load to people reading code. We don't want to be evern more of an outlier in C code style. > >> Very simple: "PPS and i386" is a typo for "ppc and i386". This > >> has nothing to do with PPS. > > > > Thanks. Makes much more sense that way. > > > > So, other than printf, are there any serous problems? > > The only other thing I'd expect is being careful about pointers and > integers, but I'd call it a feature to catch that. Since gpsd does a lot of strings and math, that is a substantial part of the current code base! RGDS GARY --------------------------------------------------------------------------- Gary E. Miller Rellim 109 NW Wilmington Ave., Suite E, Bend, OR 97703 [email protected] Tel:+1 541 382 8588 Veritas liberabit vos. -- Quid est veritas? "If you can't measure it, you can't improve it." - Lord Kelvin
pgppKMoeDeskX.pgp
Description: OpenPGP digital signature
