Add a Tricium C++ linter/analyzer |
||||
Issue descriptionFrom go/tricium-ideas: Simple Python-based linter for C++
,
Jul 25
Julie, do you know whether this might be something that someone in Fuchsia would be interested in enabling or trying out? Some background: cpplint.py checks for some cases where C++ code fails to conform to The Google style guide, but it has fewer possible checks than clang-tidy, and works differently than clang-tidy. At the moment, we're not really sure which of these warnings is going to be useful. Longer-term, I'm expecting that cpplint.py could potentially be a kind of supplement to clang-format and clang-tidy, since there might be a few types of warnings that it produces that don't overlap with the previous two.
,
Jul 25
I'm less familiar with the suite of checks in cpplint.py -- I'd be interested to try it out, but a real need for us would be the ability to disable anything we don't want. We *mostly* follow the Google style guide, with a few key points of departure and I wouldn't want to create noise for style points we don't want to enforce. Is that a possible extension?
,
Aug 3
Late reply: So, just like Pylint, I think there's no current good solution for per-project analyzer config of analyzer. One possible path right now which I think would be good would be to try out this CppLint analyzer with a relatively conservative set of checks. I still don't know what these checks should be. I'd like to gather some stats about the top warnings in different repos, and then survey some people about which ones are likely to be a good (high-confidence, useful, conservative) starting set. I think this set could potentially be used for both Fuchsia and Chromium... Anyway I'll mark this bug as "done" and continue this conversation on tricium-dev.
,
Aug 10
The following revision refers to this bug: https://chromium.googlesource.com/playground/gerrit-tricium/+/432ea0b5fcba2bf0fcde776c6f3e837b10a64778 commit 432ea0b5fcba2bf0fcde776c6f3e837b10a64778 Author: Quinten Yearsley <qyearsley@chromium.org> Date: Fri Aug 10 17:40:39 2018 Update playground tricium-dev, adding cpplint TBR=maruel TBR_REASON=playground repo Bug: 867607 Change-Id: Ifb26e4fb042da6fc0f306bf099c80e4b3a677902 [modify] https://crrev.com/432ea0b5fcba2bf0fcde776c6f3e837b10a64778/tricium-dev.cfg
,
Aug 10
The following revision refers to this bug: https://chromium.googlesource.com/infra/infra/+/11ebccc685519878e65ddb2232cd56c478d06dd8 commit 11ebccc685519878e65ddb2232cd56c478d06dd8 Author: Quinten Yearsley <qyearsley@chromium.org> Date: Fri Aug 10 18:29:22 2018 [tricium cpplint] Exclude whitespace warnings in cpplint Only affect on behavior from this CL should be to filter on confidence and message type. In addition, this CL contains a few minor changes: - Minor changes to comments - Adjust message format - Update Makefile - Move regexp compilation to top level - Remove exPath = "" Purpose: Planning to test cpplint in playground repo Bug: 867607 Change-Id: I1cb5f7ff253ca27d9c0efd1b10df33c9507e62f8 Reviewed-on: https://chromium-review.googlesource.com/1171196 Reviewed-by: Marc-Antoine Ruel <maruel@chromium.org> Commit-Queue: Quinten Yearsley <qyearsley@chromium.org> [modify] https://crrev.com/11ebccc685519878e65ddb2232cd56c478d06dd8/go/src/infra/tricium/functions/cpplint/cpplint_parser_test.go [modify] https://crrev.com/11ebccc685519878e65ddb2232cd56c478d06dd8/go/src/infra/tricium/functions/cpplint/Makefile [modify] https://crrev.com/11ebccc685519878e65ddb2232cd56c478d06dd8/go/src/infra/tricium/functions/cpplint/cpplint_parser.go [modify] https://crrev.com/11ebccc685519878e65ddb2232cd56c478d06dd8/go/src/infra/tricium/functions/cpplint/README.md
,
Aug 11
The following revision refers to this bug: https://chromium.googlesource.com/infra/infra/+/1c960e6f53a47f6bc99af1263959fd6bd52e50b6 commit 1c960e6f53a47f6bc99af1263959fd6bd52e50b6 Author: Quinten Yearsley <qyearsley@chromium.org> Date: Sat Aug 11 16:36:49 2018 [tricium cpplint] Add disable instructions to comment message If it's helpful to do this for pylint, maybe it's also helpful to do it for cpplint. Bug: 867607 Change-Id: Ic98d2fe201a8d28f6fc76cb16d99604bac9eafca Reviewed-on: https://chromium-review.googlesource.com/1171803 Reviewed-by: Marc-Antoine Ruel <maruel@chromium.org> Commit-Queue: Quinten Yearsley <qyearsley@chromium.org> [modify] https://crrev.com/1c960e6f53a47f6bc99af1263959fd6bd52e50b6/go/src/infra/tricium/functions/cpplint/cpplint_parser_test.go [modify] https://crrev.com/1c960e6f53a47f6bc99af1263959fd6bd52e50b6/go/src/infra/tricium/functions/cpplint/cpplint_parser.go
,
Aug 13
The following revision refers to this bug: https://chromium.googlesource.com/infra/infra/+/1843f62865a1125e8425e866365e8da06e6c153e commit 1843f62865a1125e8425e866365e8da06e6c153e Author: Quinten Yearsley <qyearsley@chromium.org> Date: Mon Aug 13 17:35:22 2018 [tricium cpplint] Disable header guard check Bug: 867607 Change-Id: I66afc34b54d6311c12095a3fa2a18a12d38c0dc8 Reviewed-on: https://chromium-review.googlesource.com/1171816 Commit-Queue: Quinten Yearsley <qyearsley@chromium.org> Reviewed-by: Marc-Antoine Ruel <maruel@chromium.org> [modify] https://crrev.com/1843f62865a1125e8425e866365e8da06e6c153e/go/src/infra/tricium/functions/cpplint/cpplint_parser.go |
||||
►
Sign in to add a comment |
||||
Comment 1 by bugdroid1@chromium.org
, Jul 25