This simplifies the code a bit. No functionality change.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Thanks for the cleanup! I have a few nits below, some of which will help to reduce the diff. LGTM once you fix those.
llvm/utils/TableGen/OptParserEmitter.cpp | ||
---|---|---|
237 |
| |
244–246 |
| |
255 | You can reduce the diff with: for (const Record &R : llvm::make_pointee_range(Groups)) { A side benefit is we keep a non-non-null variable from looking like it could be null to the casual reader of later lines. | |
340–341 | StringRef is cheap to copy; just use it by-value. Generally we try to avoid taking it by-reference (unless it's being modified, or if it somehow avoids an #include although it's so pervasive that's probably not worth doing). | |
391 | As above, you can use make_pointee_range. | |
458 | make_pointee_range |
clang-format not found in user's PATH; not linting file.