[PATCH] D82980: [NFC] Run clang-format on llvm-objcopy.
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 1 10:19:33 PDT 2020
MaskRay added a comment.
It is subjective but it seems to me that clang-format is making bad decisions for .td files. Many people don't format .td files (various lib/Target/*/*.td and include/clang/Driver/Options.td)
Formatting C++ files is fine but it seems that we run into some discrepancy between clang-format versions. Formatting with latest clang-format is probably fine.
================
Comment at: llvm/tools/llvm-objcopy/CopyConfig.cpp:210
if (Split.second.getAsInteger(0, NewAlign))
- return createStringError(errc::invalid_argument,
- "invalid alignment for --set-section-alignment: '%s'",
- Split.second.str().c_str());
+ return createStringError(
+ errc::invalid_argument,
----------------
I suspect the difference is due to changed heuristics of clang-format (of different versions).
================
Comment at: llvm/tools/llvm-objcopy/CopyConfig.cpp:490
+ MatchStyle SymbolMatchStyle =
+ InputArgs.hasArg(OBJCOPY_regex) ? MatchStyle::Regex
+ : InputArgs.hasArg(OBJCOPY_wildcard) ? MatchStyle::Wildcard
----------------
Pre-merge checks may suggest that this is due to different versions of clang-format.
I wonder whether we want to format the block.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D82980/new/
https://reviews.llvm.org/D82980
More information about the llvm-commits
mailing list