[PATCH] D99106: [ASTMatchers][NFC] Use SmallVector when building variadic matcher descriptor

2021-03-23 Thread Nathan James via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG8298899e56cd: [ASTMatchers][NFC] Use SmallVector when building variadic matcher descriptor (authored by njames93). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.o

[PATCH] D98275: [clang-tidy] Fix mpi checks when running multiple TUs per clang-tidy process

2021-03-24 Thread Nathan James via Phabricator via cfe-commits
njames93 marked an inline comment as done. njames93 added inline comments. Comment at: clang-tools-extra/clang-tidy/mpi/BufferDerefCheck.cpp:29-30 + if (!FuncClassifier) +FuncClassifier.emplace(*Result.Context); + aaron.ballman wrote: > This is racy, but I

[PATCH] D98745: [clang] Add fixit for Wreorder-ctor

2021-03-24 Thread Nathan James via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG279ea930fa21: [clang] Add fixit for Wreorder-ctor (authored by njames93). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D98745/new/ https://reviews.llvm.org/

[PATCH] D98275: [clang-tidy] Fix mpi checks when running multiple TUs per clang-tidy process

2021-03-24 Thread Nathan James via Phabricator via cfe-commits
njames93 marked 2 inline comments as done. njames93 added inline comments. Comment at: clang-tools-extra/clang-tidy/mpi/BufferDerefCheck.cpp:29-30 + if (!FuncClassifier) +FuncClassifier.emplace(*Result.Context); + aaron.ballman wrote: > njames93 wrote: > >

[PATCH] D98275: [clang-tidy] Fix mpi checks when running multiple TUs per clang-tidy process

2021-03-25 Thread Nathan James via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. njames93 marked an inline comment as done. Closed by commit rG02d7ef3181dd: [clang-tidy] Fix mpi checks when running multiple TUs per clang-tidy process (authored by njames93). Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D98296: [clang-tidy] Simplify readability checks to not need ignoring* matchers

2021-03-27 Thread Nathan James via Phabricator via cfe-commits
njames93 accepted this revision. njames93 added inline comments. This revision is now accepted and ready to land. Comment at: clang-tools-extra/clang-tidy/readability/DeletedDefaultCheck.cpp:31 isMoveAssignmentOperator()), -isDefault

[PATCH] D99646: [clang-tidy] misc-std-stream-objects-outside-main: a new check

2021-03-31 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Is it not wise to also check the c standard library. So check for function refs to these names in the global or std namespace. `printf`, `vprintf`, `puts`, `putchar`, `scanf`, `scanf`, `getchar` and `gets` It may be a bit of a pain checking for usages of `stdin` and `std

[PATCH] D99646: [clang-tidy] misc-std-stream-objects-outside-main: a new check

2021-04-01 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. In D99646#2663733 , @mgartmann wrote: > Hi @njames93, > I can see your point, I am going to add this functionality. > > However, I do not completely understand what you mean with //check for > function refs to these names in the

[PATCH] D97653: [clang-tidy] Fix RenamerClangTidy checks breaking lambda captures.

2021-04-06 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Ping? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97653/new/ https://reviews.llvm.org/D97653 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[PATCH] D99993: [clang-tidy] bugprone-argument-comment: ignore name mismatches for decls from system headers

2021-04-06 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. In D3#2672624 , @Eugene.Zelenko wrote: > Why `--header-filter` command line option or `HeaderFilterRegex` > configuration file option could not solve this problem? That's for suppressing warnings emitted in header files. Th

[PATCH] D100092: [clang-tidy] cppcoreguidelines-declare-loop-variable-in-the-initializer: a new check

2021-04-09 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. I'd argue this check isn't following the enforcement specified in the relevant guideline: Enforcement: Warn when a variable modified inside the for-statement is declared outside the loop and not being used outside the loop. All this is checking is that there is a

[PATCH] D97653: [clang-tidy] Fix RenamerClangTidy checks breaking lambda captures.

2021-04-10 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. In D97653#2675005 , @aaron.ballman wrote: > In D97653#2593287 , @njames93 wrote: > >> Where would be a good place for testing refersToDefaultCapture support? > > Thank you for your patienc

[PATCH] D97683: [clang-tidy] Add include to misc-uniqueptr-reset-release

2021-04-10 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Herald added a project: clang-tools-extra. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97683/new/ https://reviews.llvm.org/D97683 ___ cfe-commits mailing list cfe-commits

[PATCH] D96286: [clangd] Change TidyProvider cache to use a linked list approach

2021-04-10 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Herald added a project: clang-tools-extra. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96286/new/ https://reviews.llvm.org/D96286 ___ cfe-commits mailing list cfe-commits

[PATCH] D97653: [clang-tidy] Fix RenamerClangTidy checks breaking lambda captures.

2021-04-10 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 336645. njames93 added a comment. Use implicit capture instead of default capture. @aaron.ballman, Unfortunately the AST dump tests don't work as implicit captures don't appear to show up in the textual representation. Repository: rG LLVM Github Monorep

[PATCH] D99231: [AST] Add introspection support for more base nodes

2021-04-11 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang/include/clang/AST/DeclCXX.h:2270 SourceLocation getEllipsisLoc() const { -assert(isPackExpansion() && "Initializer is not a pack expansion"); +if (!isPackExpansion()) + return {}; I'm not sure abou

[PATCH] D100343: [AST][NFC] Remove temporary ASTTU file from Introspection generation.

2021-04-12 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added a reviewer: steveire. Herald added a subscriber: mgorny. njames93 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. We can use the Preprocessor to remap this file, cleaning up the cmake code. R

[PATCH] D100343: [AST][NFC] Remove temporary ASTTU file from Introspection generation.

2021-04-12 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 336960. njames93 added a comment. Add new line at the end of remapped file. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100343/new/ https://reviews.llvm.org/D100343 Files: clang/lib/Tooling/CMakeLists.txt

[PATCH] D97683: [clang-tidy] Add include to misc-uniqueptr-reset-release

2021-04-12 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 336982. njames93 added a comment. Add store options method. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97683/new/ https://reviews.llvm.org/D97683 Files: clang-tools-extra/clang-tidy/misc/UniqueptrResetRe

[PATCH] D97683: [clang-tidy] Add include to misc-uniqueptr-reset-release

2021-04-12 Thread Nathan James via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG27dfcd978edc: [clang-tidy] Add include to misc-uniqueptr-reset-release (authored by njames93). Repository: rG LLVM Github Monorepo CHAN

[PATCH] D100378: [AST] Use IntrusiveRefCntPtr for Introspection LocationCall.

2021-04-13 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added a reviewer: steveire. njames93 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D100378 Files: clang/include/clang/Tooling/Node

[PATCH] D100378: [AST] Use IntrusiveRefCntPtr for Introspection LocationCall.

2021-04-13 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang/lib/Tooling/NodeIntrospection.cpp:60 + if (LHS.first == RHS.first) +return LHS.second->name() < RHS.second->name(); + return LHS.first < RHS.first; This is a slight change in behaviour, The old implementatio

[PATCH] D100343: [AST][NFC] Remove temporary ASTTU file from Introspection generation.

2021-04-13 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 337249. njames93 added a comment. Use InMemoryFileSystem instead of Remapped files, turns out they don't work if the file doesn't exist on disk. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100343/new/ https

[PATCH] D99231: [AST] Add introspection support for more base nodes

2021-04-13 Thread Nathan James via Phabricator via cfe-commits
njames93 added subscribers: aaron.ballman, rsmith. njames93 added inline comments. Comment at: clang/include/clang/AST/DeclCXX.h:2270 SourceLocation getEllipsisLoc() const { -assert(isPackExpansion() && "Initializer is not a pack expansion"); +if (!isPackExpansion()) +

[PATCH] D100423: [AST] Add a print method to Introspection LocationCall

2021-04-13 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added a reviewer: steveire. njames93 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Add a print method that takes a raw_ostream. Change LocationCallFormatterCpp::format to call that method. Reposi

[PATCH] D100378: [AST] Use IntrusiveRefCntPtr for Introspection LocationCall.

2021-04-14 Thread Nathan James via Phabricator via cfe-commits
njames93 marked an inline comment as done. njames93 added inline comments. Comment at: clang/lib/Tooling/NodeIntrospection.cpp:60 + if (LHS.first == RHS.first) +return LHS.second->name() < RHS.second->name(); + return LHS.first < RHS.first; dblaikie wrote:

[PATCH] D100378: [AST] Use IntrusiveRefCntPtr for Introspection LocationCall.

2021-04-14 Thread Nathan James via Phabricator via cfe-commits
njames93 marked an inline comment as done. njames93 added inline comments. Comment at: clang/lib/Tooling/NodeIntrospection.cpp:60 + if (LHS.first == RHS.first) +return LHS.second->name() < RHS.second->name(); + return LHS.first < RHS.first; dblaikie wrote:

[PATCH] D100378: [AST] Use IntrusiveRefCntPtr for Introspection LocationCall.

2021-04-14 Thread Nathan James via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. njames93 marked an inline comment as done. Closed by commit rGb23abbeab1d7: [AST] Use IntrusiveRefCntPtr for Introspection LocationCall. (authored by njames93). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTI

[PATCH] D100343: [AST][NFC] Remove temporary ASTTU file from Introspection generation.

2021-04-14 Thread Nathan James via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGbfb6c2874be8: [AST][NFC] Remove temporary ASTTU file from Introspection generation. (authored by njames93). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100

[PATCH] D100530: [AST][Introspection] Add a check to detect if introspection is supported.

2021-04-15 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added a reviewer: steveire. Herald added a subscriber: mgorny. njames93 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This could probably be made into a compile time constant, but that would invol

[PATCH] D100423: [AST] Add a print method to Introspection LocationCall

2021-04-15 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 337724. njames93 added a comment. Tweak implementaion to make the print a static method of FormatterCpp. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100423/new/ https://reviews.llvm.org/D100423 Files: cla

[PATCH] D100423: [AST] Add a print method to Introspection LocationCall

2021-04-15 Thread Nathan James via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG542e7806e610: [AST] Add a print method to Introspection LocationCall (authored by njames93). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100423/new/ https

[PATCH] D100530: [AST][Introspection] Add a check to detect if introspection is supported.

2021-04-15 Thread Nathan James via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGf019e5f73ed7: [AST][Introspection] Add a check to detect if introspection is supported. (authored by njames93). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/

[PATCH] D100548: [AST] Fix location call storage with common last-invocation

2021-04-15 Thread Nathan James via Phabricator via cfe-commits
njames93 accepted this revision. njames93 added a comment. This revision is now accepted and ready to land. LGTM Comment at: clang/lib/Tooling/NodeIntrospection.cpp:33 } - result += (vec.back()->name() + "()").str(); + result += (vec.front()->name() + "()").str(); retur

[PATCH] D100516: [AST] Add TypeLoc support to node introspection

2021-04-15 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang/lib/Tooling/DumpTool/ASTSrcLocProcessor.cpp:158-159 BN.getNodeAs("stmtOrDeclBase"); +const auto *TypeLocBase = BN.getNodeAs("typeLocBase"); +const auto *ExprBase = BN.getNodeAs("exprBase"); if (const auto *N

[PATCH] D100516: [AST] Add TypeLoc support to node introspection

2021-04-15 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang/unittests/Introspection/IntrospectionTest.cpp:1294 + +#ifndef _WIN32 +TEST(Introspection, SourceLocations_TypeOfTypeLoc) { steveire wrote: > njames93 wrote: > > Can you add a comment explaining the issues with thi

[PATCH] D100638: [AST][Introspection] Avoid creating temporary strings when comparing LocationCalls.

2021-04-16 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added a reviewer: steveire. njames93 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Adds a bit of boiler plate, but removing the need to build temporary strings to compare the calls definitely wort

[PATCH] D100638: [AST][Introspection] Avoid creating temporary strings when comparing LocationCalls.

2021-04-16 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang/lib/Tooling/NodeIntrospection.cpp:84 + + auto LI = Left.rbegin(), LE = Left.rend(), RI = Right.rbegin(); + for (; LI != LE; ++LI, ++RI) { steveire wrote: > Would it make sense to compare the sizes `(leftsize < r

[PATCH] D100516: [AST] Add TypeLoc support to node introspection

2021-04-17 Thread Nathan James via Phabricator via cfe-commits
njames93 accepted this revision. njames93 added a comment. This revision is now accepted and ready to land. LGTM, just a few nits before landing please. Comment at: clang/lib/Tooling/DumpTool/ASTSrcLocProcessor.cpp:172-176 + if (TypeLocBase && Node->getName() == "getLocalS

[PATCH] D93978: [clangd] Use dirty filesystem when performing cross file tweaks

2021-04-17 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 338294. njames93 marked 4 inline comments as done. njames93 added a comment. Address comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93978/new/ https://reviews.llvm.org/D93978 Files: clang-tools-ext

[PATCH] D100638: [AST][Introspection] Avoid creating temporary strings when comparing LocationCalls.

2021-04-17 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 338356. njames93 added a comment. Rebase and remove Args from comparison. Add quick check for skippig common prefix calls. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100638/new/ https://reviews.llvm.org/D10

[PATCH] D100719: [Introspection] Dont emit json if unchanged.

2021-04-18 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added a reviewer: steveire. njames93 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Saves running the generate inc script in the, somewhat common, case where the json file doesn't need changing.

[PATCH] D100712: [AST] Add NestedNameSpecifierLoc accessors to node introspection

2021-04-18 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang/lib/Tooling/DumpTool/generate_cxx_src_locs.py:57 InstanceDecoration = "*" -if CladeName == "TypeLoc": +if CladeName == "TypeLoc" or CladeName == "NestedNameSpecifierLoc": InstanceDecoration =

[PATCH] D100723: [AST] Fix comparison to of SourceRanges in container

2021-04-18 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang/lib/Tooling/NodeIntrospection.cpp:47 std::pair const &RHS) const { - if (!LHS.first.isValid() || !RHS.first.isValid()) -return false; Maybe we should assert the ranges (or locations) are valid before ins

[PATCH] D100712: [AST] Add NestedNameSpecifierLoc accessors to node introspection

2021-04-18 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang/unittests/Introspection/IntrospectionTest.cpp:280 STRING_LOCATION_STDPAIR(MethodDecl, getTypeSpecStartLoc()) })); // clang-format on I'm not entirely sure on the case, but the windows bot is giving a [[ ht

[PATCH] D100719: [Introspection] Dont emit json if unchanged.

2021-04-18 Thread Nathan James via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGdb75db85f231: [Introspection] Dont emit json if unchanged. (authored by njames93). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100719/new/ https://reviews

[PATCH] D93978: [clangd] Use dirty filesystem when performing cross file tweaks

2021-04-19 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 338518. njames93 added a comment. Fix up compilation failures and test failures. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93978/new/ https://reviews.llvm.org/D93978 Files: clang-tools-extra/clangd/Clan

[PATCH] D100720: [AST] Update introspection API to use const-ref for copyable types

2021-04-19 Thread Nathan James via Phabricator via cfe-commits
njames93 accepted this revision. njames93 added a comment. This revision is now accepted and ready to land. LG with 1 nit. Comment at: clang/lib/Tooling/DumpTool/generate_cxx_src_locs.py:14 +RefClades = ["NestedNameSpecifierLoc", "TemplateArgumentLoc", "TypeLoc"] + --

[PATCH] D100723: [AST] Fix comparison to of SourceRanges in container

2021-04-19 Thread Nathan James via Phabricator via cfe-commits
njames93 accepted this revision. njames93 added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Tooling/NodeIntrospection.cpp:47 std::pair const &RHS) const { - if (!LHS.first.isValid() || !RHS.first.isValid()) -return false;

[PATCH] D93978: [clangd] Use dirty filesystem when performing cross file tweaks

2021-04-20 Thread Nathan James via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6b4e8f82a3f8: [clangd] Use dirty filesystem when performing cross file tweaks (authored by njames93). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93978/new

[PATCH] D96286: [clangd][NFC] Change TidyProvider cache to use a linked list approach

2021-04-21 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Ping? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96286/new/ https://reviews.llvm.org/D96286 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[PATCH] D99924: [clang-tidy] Avoid bugprone-macro-parentheses warnings after goto argument

2021-04-21 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. In D99924#2706181 , @aaron.ballman wrote: > Adding the CFE mailing list, which was not on the review previously. I think H744 needs updating to add cfe-commits. This used to be handled by the rul

[PATCH] D93844: [clang-format] Add possibility to be based on parent directory

2020-12-27 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. In D93844#2472346 , @MyDeveloperDay wrote: > I'm a little confused why this is needed as clang-format always read up the > directory tree until it see a .clang-format file, perhaps I don't quite > understand the use case. Can't

[PATCH] D93861: [clang-tidy][NFC] Split up some headers

2020-12-28 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added a reviewer: aaron.ballman. Herald added subscribers: usaxena95, kadircet, arphaman, kbarton, xazax.hun, nemanjai. njames93 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Extract the ClangTidy

[PATCH] D93861: [clang-tidy][NFC] Split up some headers

2020-12-28 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 313878. njames93 marked 3 inline comments as done. njames93 added a comment. Fix clang-tidy lint and comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93861/new/ https://reviews.llvm.org/D93861 Files:

[PATCH] D93653: [clangd] Avoid reallocating buffers for each message read:

2020-12-28 Thread Nathan James via Phabricator via cfe-commits
njames93 accepted this revision. njames93 added a comment. This revision is now accepted and ready to land. I'm easy with this. Comment at: clang-tools-extra/clangd/JSONTransport.cpp:202 for (;;) { Out.resize(Size + BufSize); // Handle EINTR which is sent when a de

[PATCH] D93940: [clang-tidy] Add a check for blocking types and functions.

2020-12-30 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Few stylistic nits, Also Theres lots of cases where single stmt if statements have braces, typically we elide those braces. Is it worth flagging methods with Thread safety analysis attributes. These are only used i

[PATCH] D93844: [clang-format] Add possibility to be based on parent directory

2020-12-30 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang/lib/Format/Format.cpp:2962 +llvm::sys::path::filename(FileName)); +if (auto OuterStyle = getStyle(DefaultFormatStyle, FileForLanguage, + Fal

[PATCH] D93977: [clangd] Pass DraftStore to Tweak Apply and Prepare.

2021-01-02 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added reviewers: sammccall, kadircet. Herald added subscribers: usaxena95, arphaman. njames93 requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang. This enables multi file edit tweak

[PATCH] D93978: [clangd] DefineOutline doesn't require implementation file being saved

2021-01-02 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added reviewers: sammccall, kadircet. Herald added subscribers: usaxena95, arphaman. njames93 requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang. The DefineOutline tweak can now ap

[PATCH] D93979: [clang-tidy] Fix windows tests

2021-01-02 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added a reviewer: thakis. Herald added subscribers: kbarton, xazax.hun, nemanjai. njames93 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Attempt to fix the 2 failing tests identifier in 48646. Appe

[PATCH] D93979: [clang-tidy] Fix windows tests

2021-01-02 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. I don't have a (reliable) windows machine to test so can you take a look please Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93979/new/ https://reviews.llvm.org/D93979 ___ cfe-

[PATCH] D93979: [clang-tidy] Fix windows tests

2021-01-03 Thread Nathan James via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG59810c51e761: [clang-tidy] Fix windows tests (authored by njames93). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93979/new/ https://reviews.llvm.org/D9397

[PATCH] D93979: [clang-tidy] Fix windows tests

2021-01-03 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. http://45.33.8.238/win/30678/summary.html It looks like it works, as nothing needed to be built it was a v fast build Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93979/new/ https://reviews.llvm.org/D93979 _

[PATCH] D94131: [clang-tidy] Use new mapAnyOf matcher

2021-01-06 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Theres a few compile errors here in the pre merge. Is this patch based against trunk or some local branch? Comment at: clang-tools-extra/clang-tidy/bugprone/UseAfterMoveCheck.cpp:313 // may be instantiated to use std::move() on built-i

[PATCH] D93978: [clangd] DefineOutline doesn't require implementation file being saved

2021-01-06 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. In D93978#2479440 , @sammccall wrote: > Ah, thanks for working on this! > > A few thoughts: > > - when we're pseudoparsing the file we're going to modify as we do here, > using the new content is strictly better, no downside :-)

[PATCH] D93977: [clangd] Pass DraftStore to Tweak Apply and Prepare.

2021-01-07 Thread Nathan James via Phabricator via cfe-commits
njames93 abandoned this revision. njames93 added a comment. Abandoning in favour of VFS approach Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93977/new/ https://reviews.llvm.org/D93977 ___ cfe-commits m

[PATCH] D93978: [clangd] DefineOutline doesn't require implementation file being saved

2021-01-07 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 315070. njames93 added a comment. Herald added a subscriber: javed.absar. Use VFS instead of DraftStore Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93978/new/ https://reviews.llvm.org/D93978 Files: clang-

[PATCH] D93978: [clangd] DefineOutline doesn't require implementation file being saved

2021-01-07 Thread Nathan James via Phabricator via cfe-commits
njames93 marked 9 inline comments as done. njames93 added inline comments. Comment at: clang-tools-extra/clangd/TUScheduler.h:248 + /// ontop of \p Base. + llvm::IntrusiveRefCntPtr overlayFileContents( + llvm::IntrusiveRefCntPtr Base) const; sammccall wrot

[PATCH] D93978: [clangd] DefineOutline doesn't require implementation file being saved

2021-01-07 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 315235. njames93 marked an inline comment as done. njames93 added a comment. Address most comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93978/new/ https://reviews.llvm.org/D93978 Files: clang-tool

[PATCH] D94293: [clangd] automatically index STL

2021-01-08 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. How does this approach work with differing language standards. For example with an old implementation designed for c++14, `string_view` header won't exist. If the implementation is designed to work with c++17, including that header in c++14 mode will probably be ifdef.

[PATCH] D94359: [clangd] Remove ScratchFS from tests

2021-01-09 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added reviewers: adamcz, hokein, sammccall. Herald added subscribers: usaxena95, kadircet, arphaman. njames93 requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang. This can lead to i

[PATCH] D94359: [clangd] Remove ScratchFS from tests

2021-01-09 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 315596. njames93 added a comment. Fix windows tests failing(hopefully). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94359/new/ https://reviews.llvm.org/D94359 Files: clang-tools-extra/clangd/unittests/Glo

[PATCH] D93978: [clangd] DefineOutline doesn't require implementation file being saved

2021-01-10 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. So I did some tweaking and I have a snapshot filesystem that will hold shared references to the contents, thereby avoiding the need to copy the file contents. It works for rename and tweaks with no visible issues. Reasoning behind this a long term goal of letting a user

[PATCH] D94382: [clangd] Avoid recursion in TargetFinder::add()

2021-01-10 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang-tools-extra/clangd/FindTarget.cpp:333 Decls; + const Decl *CurrentlyProcessing = nullptr; RelSet Flags; Whats the purpose in tracking this? Is the Decls lookup not enough? Comment at:

[PATCH] D94359: [clangd] Remove ScratchFS from tests

2021-01-11 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 315735. njames93 added a comment. Remove extra semi-colon. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94359/new/ https://reviews.llvm.org/D94359 Files: clang-tools-extra/clangd/unittests/GlobalCompilatio

[PATCH] D94359: [clangd] Remove ScratchFS from tests

2021-01-11 Thread Nathan James via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG31732e6f52c8: [clangd] Remove ScratchFS from tests (authored by njames93). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94359/new/ https://reviews.llvm.org

[PATCH] D94390: [clangd] Extend find-refs to include overrides.

2021-01-11 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Should we be providing virtual method overrides when querying definitions, surely that's what query implementations is for? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94390/new/ https://reviews.llvm.org/D94390 ___

[PATCH] D94554: [clangd][WIP] Add a Filesystem that overlays Dirty files.

2021-01-12 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. Herald added subscribers: arphaman, javed.absar. njames93 requested review of this revision. Herald added subscribers: cfe-commits, MaskRay. Herald added a project: clang. Before I start, this should probably be on clangd-dev, but that list seems kinda dead so I've

[PATCH] D94554: [clangd][WIP] Add a Filesystem that overlays Dirty files.

2021-01-13 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 316357. njames93 added a comment. Remove some unrelated changes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94554/new/ https://reviews.llvm.org/D94554 Files: clang-tools-extra/clangd/ClangdLSPServer.cpp

[PATCH] D93452: [clangd] Trim memory periodically

2021-01-13 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. A little follow up, but I've noticed if I have a lot of tabs open in my editor (usually happens as I forget to close them). When clangd starts (or restarts) , in the first minute, memory usage will shoot right up as it starts to do its thing. I've regularly seen it go o

[PATCH] D94554: [clangd][WIP] Add a Filesystem that overlays Dirty files.

2021-01-14 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 316599. njames93 added a comment. Refactor RefCntString out of DraftStore class Remove MTime from Draft, other users of DraftStore don't need to see it. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94554/new/

[PATCH] D94601: [clang-tidy] Use DenseSet in UpgradeDurationConversionsCheck, NFCI

2021-01-14 Thread Nathan James via Phabricator via cfe-commits
njames93 accepted this revision. njames93 added a comment. Seems reasonable, LGTM. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94601/new/ https://reviews.llvm.org/D94601 ___ cfe-commits mailing list cf

[PATCH] D94621: [clang-tidy] add concurrency-async-fs

2021-01-14 Thread Nathan James via Phabricator via cfe-commits
njames93 added a reviewer: aaron.ballman. njames93 added a comment. Is this just flagging all these functions, if so I don't think there's much value in here. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94621/new/ https://reviews.llvm.org/D94621 _

[PATCH] D94785: [clangd] Index local classes, virtual and overriding methods.

2021-01-15 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Thank you for taking the time to fix this and the performance measurements to boot. My only question is does this try and index lambdas, under the hood they are declared as a CXXRecordDecl, defined in function scope? Repository: rG LLVM Github Monorepo CHANGES SINC

[PATCH] D94131: [clang-tidy] Use new mapAnyOf matcher

2021-01-16 Thread Nathan James via Phabricator via cfe-commits
njames93 requested changes to this revision. njames93 added a comment. This revision now requires changes to proceed. Can you either update the description of this patch to include the binaryOperation changes, or remove those changes from here. Comment at: clang-tools-extra/c

[PATCH] D94942: [clangd] Add tweak for implementing abstract class

2021-01-18 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added reviewers: sammccall, kadircet. Herald added subscribers: usaxena95, arphaman, mgorny. njames93 requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang. Add a tweak that will crea

[PATCH] D94942: [clangd] Add tweak for implementing abstract class

2021-01-18 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 317456. njames93 added a comment. Forgot to add the untracked files Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94942/new/ https://reviews.llvm.org/D94942 Files: clang-tools-extra/clangd/refactor/tweaks/C

[PATCH] D94942: [clangd] Add tweak for implementing abstract class

2021-01-19 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 317523. njames93 added a comment. Update printing policy. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94942/new/ https://reviews.llvm.org/D94942 Files: clang-tools-extra/clangd/refactor/tweaks/CMakeLists.

[PATCH] D93978: [clangd] DefineOutline doesn't require implementation file being saved

2021-01-19 Thread Nathan James via Phabricator via cfe-commits
njames93 planned changes to this revision. njames93 added a comment. I've decided I much prefer the implementation in D94554 , So once thats cleaned up and split up, I'll merge changes in here with there. Repository: rG LLVM Github Monorepo CHANGES SINCE LAS

[PATCH] D94554: [clangd][WIP] Add a Filesystem that overlays Dirty files.

2021-01-20 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 317856. njames93 added a comment. Start Splitting this patch up Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94554/new/ https://reviews.llvm.org/D94554 Files: clang-tools-extra/clangd/ClangdLSPServer.cpp

[PATCH] D95043: [clangd] Use Dirty Filesystem for cross file rename.

2021-01-20 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added reviewers: sammccall, kadircet. Herald added subscribers: usaxena95, arphaman, javed.absar. njames93 requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang. Refactor cross file r

[PATCH] D93978: [clangd] DefineOutline doesn't require implementation file being saved

2021-01-20 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 317862. njames93 added a comment. Change implementation to use DirtyFS instead. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93978/new/ https://reviews.llvm.org/D93978 Files: clang-tools-extra/clangd/Clang

[PATCH] D93978: [clangd] DefineOutline doesn't require implementation file being saved

2021-01-20 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 317864. njames93 added a comment. Fixed last series being a little corrupted. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93978/new/ https://reviews.llvm.org/D93978 Files: clang-tools-extra/clangd/ClangdS

[PATCH] D95046: [clangd] Add option to use dirty file contents when building preambles.

2021-01-20 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added reviewers: sammccall, kadircet. Herald added subscribers: usaxena95, arphaman. njames93 requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang. Adds a option `use-dirty-preambles

[PATCH] D94942: [clangd] Add tweak for implementing abstract class

2021-01-20 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 317984. njames93 added a comment. - Replace getFinalOverrides for a manual implementation, that method wasn't quite suited to what was needed w.r.t tracking access. - Add support for template classes with no dependant bases. - Add tests for template classes.

[PATCH] D95131: [CodeComplete] Add ranged for loops code pattern.

2021-01-21 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added reviewers: sammccall, kadircet, klimek, rsmith. njames93 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Add code pattersn for c++ `range for` loops and objective c `for...in` loops. Reposito

<    16   17   18   19   20   21