Hi, As an undergrad student I actually question the output of static analysis tools. Are you guys actively using it or do you find projects like Sonar efficient in such open source projects? Last time I heard that FindBugs are no longer maintained because the code was hard to maintain. For instance I checked one of the “Potential Index Out of bounds” pointed by LGTM. This is listed as a potential one. What is wrong with the snippet below?(https://lgtm.com/projects/g/apache/cassandra/alerts/?mode=tree&severity=error&rule=2049320662 <https://lgtm.com/projects/g/apache/cassandra/alerts/?mode=tree&severity=error&rule=2049320662>)
<E extends Exception> void forEach(HistogramDataConsumer<E> consumer) throws E { for (int i = 0; i < map.length; i += 2) { if (map[i] != -1) { consumer.consume(map[i], map[i + 1]); } } } Thanks a lot! > On 1 Nov 2017, at 12:53, Jeff Jirsa <jji...@gmail.com> wrote: > > Ah, I remember that now. Blocked by a guava bug? 4.0 seems like a good time > to upgrade guava. > > -- > Jeff Jirsa > > >> On Nov 1, 2017, at 2:49 AM, Stefan Podkowinski <s...@apache.org> wrote: >> >> >>> 2) Static Analysis stuff: >> >> I think it's worth mentioning that I also tried to integrate the Error >> Prone analyzer (http://errorprone.info/) a while ago as part of >> CASSANDRA-13175. Eventually I dropped the ball there due to some >> classpath issues, but maybe that can be fix or worked around. >> >> Having a service like lgtm.com is nice, but ideally I'd like to have a >> solution that does integrate with circle CI and clearly indicates new >> issues for a proposed patch. Or, at least, have a one-click way to check >> new code that is about to get committed using an external service. >> Easily recognizing issues for new code seems to be more valuable to me, >> instead of having a long report for your complete code base that you >> have to filter manually. >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: dev-unsubscr...@cassandra.apache.org >> For additional commands, e-mail: dev-h...@cassandra.apache.org >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscr...@cassandra.apache.org > For additional commands, e-mail: dev-h...@cassandra.apache.org >