News for hackers. Stuff that matters.
Re:A tool to detect bugs in Java and C/C++/Objective-C code ... by pm215 on Saturday March 05, 2022 @09:17AM (#30567782)
The major benefit to "tool is part of the compiler" is that vastly more people will use it and maybe fix the errors. There's a Google paper from 2018 (https://m-cacm.acm.org/magazines/2018/4/226371-lessons-from-...) about their experience with static analysis tools, and what they found was that the better the analysis was integrated with the existing developer workflow and the earlier the issues were noted, the more likely they were to actually be fixed. So "existing compiler reports the errors" is better than "tooling reports the errors as comments in the existing code review system" is better than "tooling files bugs in the existing bug tracking system after new code is already committed" is better than "tooling has its own separate dashboard that nobody looks at".

I don't care whether under the hood the implementation is fully part of one big "compiler" engine or not, in the same way I don't care that when I run 'gcc' it's really running a compiler, assembler and linker which are all self-contained programs -- I do care that when I say "build my code" in the usual way that that is when analysis happens.

Re:A tool to detect bugs in Java and C/C++/Objective-C code ... by htfy96 on Saturday March 05, 2022 @09:33AM (#30567906)
the downside of this is that companies with locked compiler versions won't be able to use the static analysis tool. Up-to-date compiler versions, according to my observation, is more like a privilege of BigTech and startups. Tons of firms are still using the bundled compiler in RHEL and only upgrade every 3-5 years, though in this case the off-tree decision more likely came from the intent of bypassing compiler repo code reviews for faster iteration (very typical at BigTech when you need KR every quarter)
Re:A tool to detect bugs in Java and C/C++/Objective-C code ... by pjmlp on Saturday March 05, 2022 @11:03AM (#30568606)
Lint exists since 1979, they certainly have newer toolchains.
Re:A tool to detect bugs in Java and C/C++/Objective-C code ... by secondcoming on Saturday March 05, 2022 @10:57AM (#30568563)
They can continue to use their existing analysis tools, no?