[PATCH] D56370: [clangd] Add support for type hierarchy (super types only for now)

2019-03-10 Thread Nathan Ridge via Phabricator via cfe-commits
nridge added a comment. Unfortunately, there is a further problem: the Theia client-side implementation of type hierarchy has recently merged, and their code has changed so that they do require `typeHierarchy/resolve` to be supported. They ask for 1 level in the initial request, ignore any

[PATCH] D56370: [clangd] Add support for type hierarchy (super types only for now)

2019-03-10 Thread Nathan Ridge via Phabricator via cfe-commits
nridge updated this revision to Diff 190041. nridge added a comment. Fix a (somewhat amusing) typo where I wrote '0' instead of 'O' in a fromJSON() implementation (Does the fact that this didn't cause any test failures suggest that the fromJSON() functions aren't exercised by any tests?)

[PATCH] D56370: [clangd] Add support for type hierarchy (super types only for now)

2019-03-10 Thread Nathan Ridge via Phabricator via cfe-commits
nridge marked an inline comment as done. nridge added a comment. The updated patch addresses the infinite recursion issue by bailing on dependent bases for now, as Sam suggested. I will implement the more comprehensive suggested fix ("bail out once we see instantiations of the same template

[PATCH] D56370: [clangd] Add support for type hierarchy (super types only for now)

2019-03-10 Thread Nathan Ridge via Phabricator via cfe-commits
nridge updated this revision to Diff 190040. nridge added a comment. Address the infinite recursion issue Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56370/new/ https://reviews.llvm.org/D56370 Files:

[PATCH] D58556: [LibTooling] Add "smart" retrieval of AST-node source to FixIt library

2019-03-10 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 190039. ymandel marked an inline comment as done. ymandel edited the summary of this revision. ymandel added a comment. Remove unneeded includes. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58556/new/

[PATCH] D56851: [ASTMatchers] Adds `CXXMemberCallExpr` matcher `invokedAtType`.

2019-03-10 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 190038. ymandel added a comment. Herald added a project: clang. Removed unneeded includes. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56851/new/ https://reviews.llvm.org/D56851 Files:

[PATCH] D58556: [LibTooling] Add "smart" retrieval of AST-node source to FixIt library

2019-03-10 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel marked 7 inline comments as done. ymandel added inline comments. Comment at: clang/include/clang/Tooling/FixIt.h:73 +// context. In contrast with \p getText(), this function selects a source range +// "automatically", extracting text that a reader might intuitively

[PATCH] D58556: [LibTooling] Add "smart" retrieval of AST-node source to FixIt library

2019-03-10 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 190037. ymandel marked an inline comment as done. ymandel edited the summary of this revision. ymandel added a comment. This update significantly simplifies the change. It removes any "smarts", instead allowing the user to request the extension of the

[PATCH] D59197: [NFC][clang][PCH][ObjC] Add some missing `VisitStmt(S);`

2019-03-10 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri created this revision. lebedev.ri added reviewers: arphaman, sammccall, smeenai, aprantl, rsmith. lebedev.ri added a project: clang. These ObjC AST classes inherit from Stmt, but don't call `VisitStmt(S);`. Some were founded with help of existing tests (with `NumStmtFields` bumped to

[PATCH] D59196: [NFC][clang][PCH] ASTStmtReader::VisitStmt(): fixup faulty assert.

2019-03-10 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri created this revision. lebedev.ri added reviewers: rsmith, rtrieu, riccibruno. lebedev.ri added a project: clang. While this is NFC - `NumStmtFields` **is** currently `0`, the assert is faulty. It's not checking that `VisitStmt()` is called when `getIdx()` returns `NumStmtFields`. It

[PATCH] D59195: [analyzer] Remove the default value arg from getChecker*Option

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, baloghadamsoftware, xazax.hun, rnkovacs. Szelethus added a project: clang. Herald added subscribers: cfe-commits, Charusso, jdoerfert, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, szepet, whisperity. Herald added a

[PATCH] D58777: [analyzer] Fix an assertation failurure for invalid sourcelocation, add a new debug checker

2019-03-10 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D58777#1423809 , @Szelethus wrote: > creduce can only work on a preprocessed file `clang -E -frewrite-includes` to the rescue! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58777/new/ https://reviews.llvm.org/D58777

[PATCH] D57860: [analyzer] Validate checker option names and values

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190023. Szelethus added a comment. Herald added subscribers: Charusso, jdoerfert. Refactored the entire patch, NFC compared to the earlier diff. This was needed as in a followup revision, much of the code would be rewritten. CHANGES SINCE LAST ACTION

[PATCH] D57855: [analyzer] Reimplement checker options

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190022. Szelethus marked an inline comment as done. Szelethus added a comment. Adding `explicit` to `CheckerInfo`'s constructor. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57855/new/ https://reviews.llvm.org/D57855 Files:

[PATCH] D57855: [analyzer] Reimplement checker options

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus marked 2 inline comments as done. Szelethus added inline comments. Comment at: lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp:371 +// We can't get away with binaryFind here, as it uses lower_bound. +auto CheckerIt = llvm::find(Checkers,

[PATCH] D57922: [analyzer] Insert checker options into AnalyzerOption::ConfigTable

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190021. Szelethus added a comment. Removed every piece of code not directly related to inserting checker option to the config table, moving it to a new patch. This essentially restores the revision to it's earliest state, except that it's even simpler: no

[PATCH] D53847: [C++2a] P0634r3: Down with typename!

2019-03-10 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 190013. Rakete added a comment. Don't relookup the qualified-id and use the cached one instead if possible. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D53847/new/ https://reviews.llvm.org/D53847

[PATCH] D58668: [ASTImporter] Fix redecl failures of FunctionTemplateSpec

2019-03-10 Thread Aleksei Sidorin via Phabricator via cfe-commits
a_sidorin accepted this revision. a_sidorin added a comment. This revision is now accepted and ready to land. Thanks! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58668/new/ https://reviews.llvm.org/D58668 ___

[PATCH] D53847: [C++2a] P0634r3: Down with typename!

2019-03-10 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete added a comment. rsmith: > Some thoughts on this: > > - Can this be unified with the lookup code in HandleDeclarator? This is > really the same lookup, repeated in two places. What I wrote: > I don't think so, because HandleDeclarator is called after having already > parsed the

[PATCH] D53847: [C++2a] P0634r3: Down with typename!

2019-03-10 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 190012. Rakete added a comment. Herald added a subscriber: jdoerfert. Herald added a project: clang. Fix a bug where `T::value` inside a functional cast in a template argument would be interpreted as a function type. Also added the missing test file

[PATCH] D58573: [analyzer] Move UninitializedObject out of alpha

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D58573#1422198 , @NoQ wrote: > Also, hmm, how about the following heuristics (looked at the positive in > `rtags` and thought about this): > > - if the field is public, don't warn (the structure seems to be used simply > as

[PATCH] D55358: [ASTImporter] Fix import of NestedNameSpecifierLoc.

2019-03-10 Thread Aleksei Sidorin via Phabricator via cfe-commits
a_sidorin accepted this revision. a_sidorin added a comment. This revision is now accepted and ready to land. Herald added a subscriber: rnkovacs. Looks good! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55358/new/ https://reviews.llvm.org/D55358

[PATCH] D52610: [Esan] Port cache frag to FreeBSD

2019-03-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski resigned from this revision. krytarowski added a comment. Herald added a project: clang. ESan is now discontinued. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D52610/new/ https://reviews.llvm.org/D52610

[PATCH] D33029: [clang-format] add option for dangling parenthesis

2019-03-10 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. In D33029#1423947 , @lebedev.ri wrote: > In D33029#1423944 , @MyDeveloperDay > wrote: > > > Adding the unit tests lets us see how this option will work in various > > cases, it

[PATCH] D33029: [clang-format] add option for dangling parenthesis

2019-03-10 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In D33029#1423944 , @MyDeveloperDay wrote: > Adding the unit tests lets us see how this option will work in various cases, > it will let us understand that its not breaking anything else. > > I personally don't like to see

[PATCH] D59087: [clang-format] [PR25010] AllowShortIfStatementsOnASingleLine not working if an "else" statement is present

2019-03-10 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay planned changes to this revision. MyDeveloperDay added a comment. In D59087#1423942 , @reuk wrote: > Does it make sense to allow `AllowShortIfElseStatementsOnASingleLine` to be > enabled when `AllowShortIfStatementsOnASingleLine` is not? >

[PATCH] D59087: [clang-format] [PR25010] AllowShortIfStatementsOnASingleLine not working if an "else" statement is present

2019-03-10 Thread Reuben Thomas via Phabricator via cfe-commits
reuk added a comment. Does it make sense to allow `AllowShortIfElseStatementsOnASingleLine` to be enabled when `AllowShortIfStatementsOnASingleLine` is not? Perhaps it would be better to have `AllowShortIfStatementsOnASingleLine` be represented by an enum with values `Never`, `WithoutElse`,

[PATCH] D33029: [clang-format] add option for dangling parenthesis

2019-03-10 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Adding the unit tests lets us see how this option will work in various cases, it will let us understand that its not breaking anything else. I personally don't like to see revisions like this sit for 2 years with nothing happening, I don't see anything wrong

[PATCH] D55170: [clang-format]: Add NonEmptyParentheses spacing option

2019-03-10 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. In D55170#1423798 , @reuk wrote: > Thanks for the review, and for approving this PR. It's very much appreciated! > > I don't have merge rights - could someone commit this for me please? I'd actively encourage you to go