[PATCH] D54943: [clang-tidy] implement new check 'misc-const-correctness' to add 'const' to unmodified variables

2022-04-24 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang-tools-extra/clang-tidy/misc/ConstCorrectnessCheck.cpp:103 + +#if 0 + // FIXME: Remove this section if there are no crashes after the iterator-fix. Hasn't this already been addressed, if so can this block just be

[PATCH] D124104: [clang][dataflow] Fix `Environment::join`'s handling of flow condition merging

2022-04-24 Thread Stanislav Gatev via Phabricator via cfe-commits
sgatev accepted this revision. sgatev added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/DataflowEnvironment.cpp:339-341 // Move `LocToVal` so that `Environment::ValueModel::merge` can safely assign // values to storage locations while this code iterates ov

[PATCH] D124344: [clangd] Output inlay hints with `clangd --check`

2022-04-24 Thread Tobias Ribizel via Phabricator via cfe-commits
upsj marked 2 inline comments as done. upsj added inline comments. Comment at: clang-tools-extra/clangd/tool/Check.cpp:195 + // Build Inlay Hints for the entire AST + bool buildInlayHints(llvm::Optional LineRange) { nridge wrote: > The comment should probably

[PATCH] D124344: [clangd] Output inlay hints with `clangd --check`

2022-04-24 Thread Tobias Ribizel via Phabricator via cfe-commits
upsj updated this revision to Diff 424817. upsj added a comment. forgot to include the old changes in the diff CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124344/new/ https://reviews.llvm.org/D124344 Files: clang-tools-extra/clangd/Protocol.cpp clang-tools-extra/clangd/Protocol.h

[PATCH] D124344: [clangd] Output inlay hints with `clangd --check`

2022-04-24 Thread Tobias Ribizel via Phabricator via cfe-commits
upsj updated this revision to Diff 424816. upsj added a comment. Output InlayHintKind and improve comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124344/new/ https://reviews.llvm.org/D124344 Files: clang-tools-extra/clangd/Protocol.cpp clang-tools-extra/clangd/Protocol.h c

[PATCH] D124344: [clangd] Output inlay hints with `clangd --check`

2022-04-24 Thread Nathan Ridge via Phabricator via cfe-commits
nridge accepted this revision. nridge added a comment. This revision is now accepted and ready to land. Thanks, this seems useful. Comment at: clang-tools-extra/clangd/tool/Check.cpp:195 + // Build Inlay Hints for the entire AST + bool buildInlayHints(llvm::Optional LineRan

[clang] e33867a - Fix an issue in comment. NFC

2022-04-24 Thread Jun Zhang via cfe-commits
Author: Jun Zhang Date: 2022-04-25T12:45:39+08:00 New Revision: e33867a43410ea425c169cde9de7187f08264e59 URL: https://github.com/llvm/llvm-project/commit/e33867a43410ea425c169cde9de7187f08264e59 DIFF: https://github.com/llvm/llvm-project/commit/e33867a43410ea425c169cde9de7187f08264e59.diff LOG

[PATCH] D124356: [Driver][Solaris] -r: imply -nostdlib like GCC

2022-04-24 Thread Brad Smith via Phabricator via cfe-commits
brad created this revision. brad added reviewers: MaskRay, ro. brad added a project: clang. Herald added subscribers: StephenFan, fedor.sergeev. Herald added a project: All. brad requested review of this revision. Similar to D116843 for Gnu.cpp Repository: rG

[PATCH] D123884: [HLSL][clang][Driver] Support target profile command line option.

2022-04-24 Thread Xiang Li via Phabricator via cfe-commits
python3kgae updated this revision to Diff 424810. python3kgae marked an inline comment as done. python3kgae added a comment. Herald added a subscriber: Anastasia. Use c_str instead of data to avoid test fail. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm

[PATCH] D122663: Mark identifier prefixes as substitutable

2022-04-24 Thread Harald van Dijk via Phabricator via cfe-commits
hvdijk added a comment. In D122663#3457330 , @erichkeane wrote: > LGTM! I would like @rjmccall to take a pass if he ends up having time in the > next day or two (perhaps tack on an extra day or two because of Easter), else > I'll be willing to approve

[PATCH] D121754: [clang-format] Refactor determineStarAmpUsage NFC

2022-04-24 Thread sstwcw via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGc261f78d05de: [clang-format] Refactor determineStarAmpUsage NFC (authored by sstwcw). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121754/new/ https://revi

[clang] c261f78 - [clang-format] Refactor determineStarAmpUsage NFC

2022-04-24 Thread via cfe-commits
Author: sstwcw Date: 2022-04-24T22:30:22Z New Revision: c261f78d05deee305166e5f8c91e347b8401dfa4 URL: https://github.com/llvm/llvm-project/commit/c261f78d05deee305166e5f8c91e347b8401dfa4 DIFF: https://github.com/llvm/llvm-project/commit/c261f78d05deee305166e5f8c91e347b8401dfa4.diff LOG: [clang

[PATCH] D124351: [Clang][WIP] Implement Change scope of lambda trailing-return-type - Take 2

2022-04-24 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added a comment. Hey folks. I do not intend this to be merge but if there is anyway this can be battle tested against internal codebases, i think it could be helpful to help guide how WG21 proceed with this feature. Here is a paper listing the failures encountered when we merged the pre

[PATCH] D124351: [Clang][WIP] Implement Change scope of lambda trailing-return-type

2022-04-24 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin created this revision. Herald added a project: All. cor3ntin requested review of this revision. Herald added a reviewer: jdoerfert. Herald added subscribers: cfe-commits, sstefan1. Herald added a project: clang. This implements P2036R3 with the changes proposed by D2579R0 applied. That is

[PATCH] D97625: fix check-clang-tools tests that fail due to Windows CRLF line endings

2022-04-24 Thread Aaron Puchert via Phabricator via cfe-commits
aaronpuchert added a comment. In D97625#3337018 , @dmgreen wrote: > I'm not sure it will do much where it is. It won't, to quote **gitattributes**(5): > When deciding what attributes are assigned to a path, Git consults > `$GIT_DIR/info/attributes` file

[PATCH] D124348: [1/2][RISCV]Add Intrinsics for B extension in Clang

2022-04-24 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added a comment. The "B extension" terminology no longer exists. Comment at: clang/include/clang/Basic/BuiltinsRISCV.def:29 +TARGET_BUILTIN(__builtin_riscv_cpopw_64, "WiWi", "nc", "zbb,64bit") +TARGET_BUILTIN(__builtin_riscv_ctz_32, "ZiZi", "nc", "zbb") +TARGET_BUI

[PATCH] D124349: [analyzer] Get direct binding for specific punned case

2022-04-24 Thread Vince Bridgers via Phabricator via cfe-commits
vabridgers updated this revision to Diff 424796. vabridgers added a comment. clang-format Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124349/new/ https://reviews.llvm.org/D124349 Files: clang/lib/StaticAnalyzer/Core/RegionStore.cpp clang/tes

[PATCH] D124349: [analyzer] Get direct binding for specific punned case

2022-04-24 Thread Vince Bridgers via Phabricator via cfe-commits
vabridgers created this revision. vabridgers added reviewers: NoQ, steakhal. Herald added subscribers: manas, ASDenysPetrov, martong, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a project: All. vabridgers requested review of this r

[PATCH] D114837: format: Remove redundant calls to guessIsObjC to speed up clang-format on unknown file types

2022-04-24 Thread David Van Cleve via Phabricator via cfe-commits
davidvc1 added a comment. Herald added a project: All. @curdeius , the PR description mentions the reason: when you pipe input from stdin, clang-format has to run through the "is it objective C?" codepath, and this is the codepath with the bug. On the other hand, when you pass a .cpp file as a

[PATCH] D124221: Add new builtin __builtin_reflect_struct.

2022-04-24 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D124221#3469251 , @rsmith wrote: > In D124221#3468706 , @aaron.ballman > wrote: > >> Thank you for looking into this! I've also thought that the >> `__builtin_dump_struct` imple

[PATCH] D124348: [1/2][RISCV]Add Intrinsics for B extension in Clang

2022-04-24 Thread Chang Hu via Phabricator via cfe-commits
joker881 created this revision. Herald added subscribers: sunshaoce, VincentWu, luke957, vkmr, frasercrmck, evandro, luismarques, apazos, sameer.abuasal, s.egerton, Jim, benna, psnobl, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, kito-cheng, niosHD, sa

[PATCH] D54943: [clang-tidy] implement const-transformation for misc-const-correctness

2022-04-24 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth updated this revision to Diff 424788. JonasToth added a comment. - fix: remove clangAnalysis link in cppcoreguidelines and add it in misc Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54943/new/ https://reviews.llvm.org/D54943 Files: c

[PATCH] D54943: [clang-tidy] implement const-transformation for cppcoreguidelines-const-correctness

2022-04-24 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth updated this revision to Diff 424787. JonasToth added a comment. - refactor: rename check to 'misc-const-correctness' and adjust the tests accordingly - docs: adjust release notes and adjust check docs slightly Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https:/

[PATCH] D121838: Generalize "check-all" umbrella targets, use for check-clang-tools

2022-04-24 Thread Louis Dionne via Phabricator via cfe-commits
ldionne resigned from this revision. ldionne added a comment. I think @phosek is the right person to look at this. I looked at it and it seems fine, but I don't know how the runtimes tests are setup well enough to spot an issue if there were one. Nit: I'd suggest rebasing and re-uploading the p

[PATCH] D119481: run-clang-tidy: Fix infinite loop on windows

2022-04-24 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. Sorry for the long delay, i simply forgot. The patch is commited! :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119481/new/ https://reviews.llvm.org/D119481 ___ cfe-commits

[PATCH] D119481: run-clang-tidy: Fix infinite loop on windows

2022-04-24 Thread Jonas Toth via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG3f0f20366622: run-clang-tidy: Fix infinite loop on windows (authored by JonasToth). Herald added a project: All. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org

[clang-tools-extra] 3f0f203 - run-clang-tidy: Fix infinite loop on windows

2022-04-24 Thread Jonas Toth via cfe-commits
Author: Jonas Toth Date: 2022-04-24T17:17:02+02:00 New Revision: 3f0f20366622ee5fd35a1d65d7db5226f5e5751f URL: https://github.com/llvm/llvm-project/commit/3f0f20366622ee5fd35a1d65d7db5226f5e5751f DIFF: https://github.com/llvm/llvm-project/commit/3f0f20366622ee5fd35a1d65d7db5226f5e5751f.diff LO

[PATCH] D124344: [clangd] Output inlay hints with `clangd --check`

2022-04-24 Thread Tobias Ribizel via Phabricator via cfe-commits
upsj created this revision. upsj added a reviewer: sammccall. Herald added subscribers: usaxena95, kadircet, arphaman. Herald added a project: All. upsj requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang-tools-extra. With

[PATCH] D124260: [clang-format] ColumnLimit check for trailing comments alignment acts wrong for multi-byte UTF-8 #47624

2022-04-24 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks added a comment. There seem to be failing tests. Did you run the FormatTests? Comment at: clang/unittests/Format/FormatTestComments.cpp:2861-2864 + EXPECT_EQ("int ab; // utf8 🐉\n" +"int a; // line\n", +format("int ab; // long 🐉\n" +

[libunwind] b3df14b - [runtimes] [CMake] Unify variable names

2022-04-24 Thread Martin Storsjö via cfe-commits
Author: Petr Hosek Date: 2022-04-24T13:06:36+03:00 New Revision: b3df14b6c98702ce50401fd039852787373e4676 URL: https://github.com/llvm/llvm-project/commit/b3df14b6c98702ce50401fd039852787373e4676 DIFF: https://github.com/llvm/llvm-project/commit/b3df14b6c98702ce50401fd039852787373e4676.diff LO

[PATCH] D122841: [analyzer] Add option for AddrSpace in core.NullDereference check

2022-04-24 Thread Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG3566bbe62f2e: [analyzer] Add option for AddrSpace in core.NullDereference check (authored by vabridgers, committed by einvbri ). Repository: rG LLVM Github Monorepo CHAN

[clang] 3566bbe - [analyzer] Add option for AddrSpace in core.NullDereference check

2022-04-24 Thread via cfe-commits
Author: Vince Bridgers Date: 2022-04-24T03:51:49-05:00 New Revision: 3566bbe62f2ef2bf1b736d04a9d6b3c669a66297 URL: https://github.com/llvm/llvm-project/commit/3566bbe62f2ef2bf1b736d04a9d6b3c669a66297 DIFF: https://github.com/llvm/llvm-project/commit/3566bbe62f2ef2bf1b736d04a9d6b3c669a66297.diff

[PATCH] D124341: [clang-tidy][NFC] Replace many instances of std::string where a StringRef would suffice.

2022-04-24 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. Herald added subscribers: carlosgalvezp, arphaman, kbarton, xazax.hun, nemanjai. Herald added a project: All. njames93 requested review of this revision. Herald added a project: clang-tools-extra. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github