News for hackers. Stuff that matters.
Re:A gentle introduction to static analyzers for C by cozzyd on Wednesday September 27, 2023 @04:48PM (#37681101)
get_foobar() could update some thread_local static value, for example.... or print something to screen.

n_bytes could easily be negative if a byte offset, or as a sentinel.

This is why we have a type system, to express these things :)

Re:A gentle introduction to static analyzers for C by bjourne on Thursday September 28, 2023 @03:53PM (#37694884)
Nah, those are type errors. Some languages use case so that FOO can never have the same type as foo. Nothing prevents a type system from similarly distinguishing between get_foo() and set_foo().