[PATCH] D50119: Compiler support for P1144R0 "__is_trivially_relocatable(T)"

2018-11-14 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: docs/LanguageExtensions.rst:1096 + equivalent to copying the underlying bytes and then dropping the source object + on the floor. * ``__is_destructible`` (MSVC 2013) Quuxplusone wrote: > rjmccall wrote: > >

[PATCH] D53771: [clang-tidy] Avoid C arrays check

2018-11-14 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL346835: [clang-tidy] Avoid C arrays check (authored by lebedevri, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D53771?vs=173514=173996#toc

[clang-tools-extra] r346835 - [clang-tidy] Avoid C arrays check

2018-11-14 Thread Roman Lebedev via cfe-commits
Author: lebedevri Date: Wed Nov 14 01:01:08 2018 New Revision: 346835 URL: http://llvm.org/viewvc/llvm-project?rev=346835=rev Log: [clang-tidy] Avoid C arrays check Summary: [[ https://bugs.llvm.org/show_bug.cgi?id=39224 | PR39224 ]] As discussed, we can't always do the transform automatically

[PATCH] D53934: [clangd] Improve code completion for ObjC methods

2018-11-14 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE346836: [clangd] Improve code completion for ObjC methods (authored by sammccall, committed by ). Changed prior to commit: https://reviews.llvm.org/D53934?vs=173737=173997#toc Repository: rCTE

[PATCH] D53329: Generate DIFile with main program if source is not available

2018-11-14 Thread Yonghong Song via Phabricator via cfe-commits
yonghong-song added a comment. F7545597: clang-crash.tar @dblaikie I got a standalone reproducible test now. -bash-4.4$ pwd /home/yhs/work/bcc/clang-crash -bash-4.4$ ls clang-test.cpp compile.sh README ttest.c ttest.h -bash-4.4$ README has

[PATCH] D52674: [AST] Add Obj-C discriminator to MS ABI RTTI

2018-11-14 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In https://reviews.llvm.org/D52674#1297893, @smeenai wrote: > In https://reviews.llvm.org/D52674#1297879, @rjmccall wrote: > > > I'm not worried about the mangler being re-used for multiple declarations, > > I'm worried about a global flag changing how we mangle all

[clang-tools-extra] r346836 - [clangd] Improve code completion for ObjC methods

2018-11-14 Thread Sam McCall via cfe-commits
Author: sammccall Date: Wed Nov 14 01:05:19 2018 New Revision: 346836 URL: http://llvm.org/viewvc/llvm-project?rev=346836=rev Log: [clangd] Improve code completion for ObjC methods Summary: Previously code completion did not work well for Objective-C methods which contained multiple arguments as

[PATCH] D54475: [clangd] Allow observation of changes to global CDBs.

2018-11-14 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clangd/Function.h:90 +class Event { +public: + // A Listener is the callback through which events are delivered. I assume the `Event` is supposed to be used only with non-reference and non-const qualified types.

[PATCH] D54450: Get the correct range of tokens for preprocessor conditions

2018-11-14 Thread Miklos Vajna via Phabricator via cfe-commits
vmiklos added a comment. As far as I see GCC warns on these 3 things. Comment at: lib/Lex/PPDirectives.cpp:553 } else { const SourceLocation CondBegin = CurPPLexer->getSourceLocation(); // Restore the value of LexingRawMode so that identifiers

[PATCH] D54309: [AST] Allow limiting the scope of common AST traversals (getParents, RAV).

2018-11-14 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. sammccall marked 2 inline comments as done. Closed by commit rC346847: [AST] Allow limiting the scope of common AST traversals (getParents, RAV). (authored by sammccall, committed by ). Changed prior to commit:

[PATCH] D54309: [AST] Allow limiting the scope of common AST traversals (getParents, RAV).

2018-11-14 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 174000. sammccall marked 2 inline comments as done. sammccall added a comment. Address review comments. Remove special case for TUDecl since no-parents is now handled. Repository: rC Clang https://reviews.llvm.org/D54309 Files:

[PATCH] D54309: [AST] Allow limiting the scope of common AST traversals (getParents, RAV).

2018-11-14 Thread Eric Liu via Phabricator via cfe-commits
ioeric accepted this revision. ioeric added a comment. This revision is now accepted and ready to land. lgtm Comment at: lib/ASTMatchers/ASTMatchFinder.cpp:674 + // Nodes may have no parents if: + // a) the node is the TranslationUnitDecl + // a) there is a

[PATCH] D54269: Introduce shard storage to auto-index.

2018-11-14 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Thanks, mostly interface tweaks now. Comment at: clangd/index/Background.cpp:187 + BackgroundIndexStorage *IndexStorage = getIndexStorage(Directory); + if (!IndexStorage) +elog("No index storage for: {0}", Directory); I think

[PATCH] D54473: [sanitizers] Initial implementation for -fsanitize=init-locals

2018-11-14 Thread Alexander Potapenko via Phabricator via cfe-commits
glider added a comment. In https://reviews.llvm.org/D54473#1297460, @kcc wrote: > This new flag inhibits the warnings from -Wuninitialized, right? > While this is fine for experimenting (and I want to have this in ToT to > enable wide experimentation) > we should clearly state (in the

[clang-tools-extra] r346852 - [clangd] Replace StringRef in SymbolLocation with a char pointer.

2018-11-14 Thread Haojian Wu via cfe-commits
Author: hokein Date: Wed Nov 14 03:55:45 2018 New Revision: 346852 URL: http://llvm.org/viewvc/llvm-project?rev=346852=rev Log: [clangd] Replace StringRef in SymbolLocation with a char pointer. Summary: This would save us 8 bytes per ref, and buy us ~40MB in total for llvm index (from ~300MB to

[PATCH] D53427: [clangd] Replace StringRef in SymbolLocation with a char pointer.

2018-11-14 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL346852: [clangd] Replace StringRef in SymbolLocation with a char pointer. (authored by hokein, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM

[PATCH] D52296: [Clang] - Add '-gsplit-dwarf[=split, =single]' version for '-gsplit-dwarf' option.

2018-11-14 Thread George Rimar via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC346837: [Clang] - Add -gsplit-dwarf[=split,=single] version for -gsplit-dwarf… (authored by grimar, committed by ). Changed prior to commit: https://reviews.llvm.org/D52296?vs=173643=173998#toc

r346847 - [AST] Allow limiting the scope of common AST traversals (getParents, RAV).

2018-11-14 Thread Sam McCall via cfe-commits
Author: sammccall Date: Wed Nov 14 02:33:30 2018 New Revision: 346847 URL: http://llvm.org/viewvc/llvm-project?rev=346847=rev Log: [AST] Allow limiting the scope of common AST traversals (getParents, RAV). Summary: The goal is to allow analyses such as clang-tidy checks to run on a subset of the

[PATCH] D54475: [clangd] Allow observation of changes to global CDBs.

2018-11-14 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 174014. sammccall marked 3 inline comments as done. sammccall added a comment. Address comments. Add missing OverlayCDB->Base watching (oops!) Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D54475 Files: clangd/Function.h

[PATCH] D53809: Fix invalid address space generation for clk_event_t

2018-11-14 Thread Alexey Sotkin via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC346838: [OpenCL] Fix invalid address space generation for clk_event_t (authored by AlexeySotkin, committed by ). Repository: rC Clang https://reviews.llvm.org/D53809 Files:

[PATCH] D54519: [clangd] Fix no results returned for global symbols in dexp

2018-11-14 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added a reviewer: ioeric. Herald added subscribers: kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. For symbols in global namespace (without any scope), we need to add global scope "" to the fuzzy request. Repository: rCTE Clang Tools Extra

r346838 - [OpenCL] Fix invalid address space generation for clk_event_t

2018-11-14 Thread via cfe-commits
Author: AlexeySotkin Date: Wed Nov 14 01:40:05 2018 New Revision: 346838 URL: http://llvm.org/viewvc/llvm-project?rev=346838=rev Log: [OpenCL] Fix invalid address space generation for clk_event_t Summary: Addrspace(32) was generated when putting 0 in clk_event_t * event_ret parameter for

r346837 - [Clang] - Add '-gsplit-dwarf[=split, =single]' version for '-gsplit-dwarf' option.

2018-11-14 Thread George Rimar via cfe-commits
Author: grimar Date: Wed Nov 14 01:22:16 2018 New Revision: 346837 URL: http://llvm.org/viewvc/llvm-project?rev=346837=rev Log: [Clang] - Add '-gsplit-dwarf[=split,=single]' version for '-gsplit-dwarf' option. The DWARF5 specification says(Appendix F.1): "The sections that do not require

[PATCH] D54539: [CodeGen] Replace '@' characters in block descriptors' symbol names with '\1' on ELF targets.

2018-11-14 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. In https://reviews.llvm.org/D54539#1298949, @rjmccall wrote: > This should not be changing the actual `@`-encoding value. If we want to use > the `@`-encoding in the symbol name, we can change it when naming the symbol, > provided that \1 is not legal in the

[PATCH] D53329: Generate DIFile with main program if source is not available

2018-11-14 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. Thanks for this - though it looks like the test program hits an assertion failure (for me at least - before it gets to the interesting point. clang-test: /usr/local/google/home/blaikie/dev/llvm/src/lib/ExecutionEngine/MCJIT/MCJIT.cpp:204: virtual void

[PATCH] D40218: [Clang] Add __builtin_launder

2018-11-14 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. In https://reviews.llvm.org/D40218#1298943, @Romain-Geissler-1A wrote: > Is there any news on this code review ? Is it ready to land ? I think so, but there were some changes regarding incomplete types since Richard last looked at it. I wanted him to sign off on the

[PATCH] D54550: Mark lambda decl as invalid if a captured variable has an invalid type.

2018-11-14 Thread Jorge Gorbe Moya via Phabricator via cfe-commits
jgorbe marked 2 inline comments as done. jgorbe added inline comments. Comment at: clang/lib/Sema/SemaExpr.cpp:14946 + // as invalid as well. + if (const CXXRecordDecl *RD = FieldType->getAsCXXRecordDecl()) { +if (RD->isInvalidDecl()) { rsmith wrote: >

[PATCH] D53329: Generate DIFile with main program if source is not available

2018-11-14 Thread Yonghong Song via Phabricator via cfe-commits
yonghong-song added a comment. You compiled with the assertion on, which triggered the issue. I should have thought about this. Sorry. For error, clang-test: /usr/local/google/home/blaikie/dev/llvm/src/lib/ExecutionEngine/MCJIT/MCJIT.cpp:204: virtual void

[PATCH] D54556: [analyzer] MoveChecker Pt.1: Give MisusedMovedObject checker a more consistent name.

2018-11-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added reviewers: dcoughlin, xazax.hun, a.sidorin, george.karpenkov, szepet, rnkovacs, Szelethus. Herald added subscribers: cfe-commits, dkrupp, donat.nagy, mikhail.ramalho, baloghadamsoftware, mgorny. NoQ edited the summary of this revision. NoQ added a dependency:

[PATCH] D53818: [ASTImporter] Changed use of Import to Import_New in ASTImporter.

2018-11-14 Thread Aleksei Sidorin via Phabricator via cfe-commits
a_sidorin added a comment. Herald added a reviewer: shafik. Herald added a subscriber: gamesh411. Hi Balasz, As I guess, the next step is to convert all `Import`calls to `Import_New` and then rename `Import_New` into `Import`. If so, why aren't we able to just change the behaviour of `Import`

[PATCH] D54553: [clangd] Fix crash hovering on non-decltype trailing return

2018-11-14 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle created this revision. Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous, MaskRay, ioeric, ilya-biryukov. More specifically, hovering on "auto" in auto main() -> int { return 0; } Signed-off-by: Marc-Andre Laperle Repository: rCTE Clang Tools Extra

[PATCH] D51575: [clang-tidy/checks] Implement a clang-tidy check to verify Google Objective-C function naming conventions 

2018-11-14 Thread Stephane Moore via Phabricator via cfe-commits
stephanemoore added a comment. I received commit access yesterday so I believe I should be able to land this myself (after I get myself set up and land a test commit). Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D51575 ___

[PATCH] D54166: [AST] Store the string data in StringLiteral in a trailing array of chars

2018-11-14 Thread Bruno Ricci via Phabricator via cfe-commits
riccibruno marked 2 inline comments as done. riccibruno added a comment. In https://reviews.llvm.org/D54166#1298889, @rjmccall wrote: > IIRC, abbreviations just silently don't take effect if the record doesn't > conform; so things will appear to work, but the size on disk will be bigger. I

[PATCH] D54550: Mark lambda decl as invalid if a captured variable has an invalid type.

2018-11-14 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. Thanks! Comment at: clang/lib/Sema/SemaExpr.cpp:14946 + // as invalid as well. + if (const CXXRecordDecl *RD = FieldType->getAsCXXRecordDecl()) { +if (RD->isInvalidDecl()) { You'll need to use

r346915 - CGDecl::emitStoresForConstant fix synthesized constant's name

2018-11-14 Thread JF Bastien via cfe-commits
Author: jfb Date: Wed Nov 14 16:19:18 2018 New Revision: 346915 URL: http://llvm.org/viewvc/llvm-project?rev=346915=rev Log: CGDecl::emitStoresForConstant fix synthesized constant's name Summary: The name of the synthesized constants for constant initialization was using mangling for statics,

[PATCH] D54166: [AST] Store the string data in StringLiteral in a trailing array of chars

2018-11-14 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall added a comment. This revision is now accepted and ready to land. LGTM. Repository: rC Clang https://reviews.llvm.org/D54166 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D54539: [CodeGen] Replace '@' characters in block descriptors' symbol names with '\1' on ELF targets.

2018-11-14 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Oh, I see, sorry. Please rename these functions to make their purpose clear. Also, you could reasonably do this substitution on all targets. Repository: rC Clang https://reviews.llvm.org/D54539 ___ cfe-commits mailing

[PATCH] D53329: Generate DIFile with main program if source is not available

2018-11-14 Thread Yonghong Song via Phabricator via cfe-commits
yonghong-song added a comment. F7549230: clang-crash-x86.tar Just attached a new test case (clang-crash-x86.tar) which works even if the compiler is compiled with assertion on. JIT now generates x86-64 code instead of BPF code. The error message looks like:

LLVM buildmaster will be restarted tonight

2018-11-14 Thread Galina Kistanova via cfe-commits
Hello everyone, LLVM buildmaster will be updated and restarted after 6PM Pacific time today. Thanks Galina ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D54560: [analyzer] MoveChecker Pt.3: Improve warning messages a bit.

2018-11-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added reviewers: dcoughlin, xazax.hun, a.sidorin, george.karpenkov, szepet, rnkovacs, Szelethus. Herald added subscribers: cfe-commits, dkrupp, donat.nagy, mikhail.ramalho, baloghadamsoftware. The warning piece traditionally describes the bug itself, i.e., "//The

[PATCH] D54529: [clangd] Add USR to textDocument/definition response

2018-11-14 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. I don't think we should be using `textDocument/definition` here, and I agree with Sam that a new method would be better. We don't actually need the semantic guarantees/constrains imposed by LSP's description of `textDocument/definition`, as we want to find any

r346907 - [codeview] Make "clang -g" emit codeview by default when targetting MSVC

2018-11-14 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Wed Nov 14 14:59:27 2018 New Revision: 346907 URL: http://llvm.org/viewvc/llvm-project?rev=346907=rev Log: [codeview] Make "clang -g" emit codeview by default when targetting MSVC Summary: If you're using the Microsoft ABI, chances are that you want PDBs and codeview debug

[PATCH] D54055: CGDecl::emitStoresForConstant fix synthesized constant's name

2018-11-14 Thread JF Bastien via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. jfb marked an inline comment as done. Closed by commit rL346915: CGDecl::emitStoresForConstant fix synthesized constants name (authored by jfb, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM

[PATCH] D54526: [AST] Pack BinaryOperator

2018-11-14 Thread Bruno Ricci via Phabricator via cfe-commits
riccibruno marked an inline comment as done. riccibruno added a comment. Added some inline comments. Comment at: include/clang/AST/Expr.h:3220 - SourceLocation getExprLoc() const LLVM_READONLY { return OpLoc; } - SourceLocation getOperatorLoc() const { return OpLoc; } -

[PATCH] D54547: PTH-- Remove feature entirely-

2018-11-14 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added inline comments. Comment at: include/clang/Driver/Options.td:261 MetaVarName<"">; -def ccc_pch_is_pch : Flag<["-"], "ccc-pch-is-pch">, InternalDriverOpt, - HelpText<"Use lazy PCH for precompiled headers">; The default behavior is exactly to

[PATCH] D54547: PTH-- Remove feature entirely-

2018-11-14 Thread Chandler Carruth via Phabricator via cfe-commits
chandlerc added a comment. Should likely add release notes about this. Also might be worth sending a note to cfe-dev as a heads up and give folks some time to say "wait wait". Repository: rC Clang https://reviews.llvm.org/D54547 ___

[PATCH] D54489: Implement -frecord-command-line (-frecord-gcc-switches)

2018-11-14 Thread Scott Linder via Phabricator via cfe-commits
scott.linder updated this revision to Diff 174104. scott.linder retitled this revision from "Implement -frecord-gcc-switches" to "Implement -frecord-command-line (-frecord-gcc-switches)". scott.linder added a comment. Change canonical option name to -frecord-command-line and add an alias from

[PATCH] D54499: [codeview] Make "clang -g" emit codeview by default when targetting MSVC

2018-11-14 Thread Reid Kleckner via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC346907: [codeview] Make clang -g emit codeview by default when targetting MSVC (authored by rnk, committed by ). Herald added a subscriber: cfe-commits. Changed prior to commit:

[PATCH] D54550: Mark lambda decl as invalid if a captured variable has an invalid type.

2018-11-14 Thread Jorge Gorbe Moya via Phabricator via cfe-commits
jgorbe created this revision. jgorbe added a reviewer: rsmith. This causes the compiler to crash when trying to compute a layout for the lambda closure type (see included test). Repository: rC Clang https://reviews.llvm.org/D54550 Files: clang/lib/Sema/SemaExpr.cpp

[PATCH] D54550: Mark lambda decl as invalid if a captured variable has an invalid type.

2018-11-14 Thread Jorge Gorbe Moya via Phabricator via cfe-commits
jgorbe updated this revision to Diff 174118. jgorbe added a comment. Fixed some issues pointed out in review comments: - call to getBaseElementType before checking type validity. - when the type is incomplete, mark not only the lambda closure type as invalid but also the field Also, added a

[PATCH] D54557: [analyzer] MoveChecker Pt.2: Restrict the warning to STL objects and locals.

2018-11-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added reviewers: dcoughlin, xazax.hun, a.sidorin, george.karpenkov, szepet, rnkovacs, Szelethus. Herald added subscribers: cfe-commits, dkrupp, donat.nagy, mikhail.ramalho, baloghadamsoftware. This patch implements the post important part of the plan proposed in

[PATCH] D54525: [AST] Pack MemberExpr

2018-11-14 Thread Bruno Ricci via Phabricator via cfe-commits
riccibruno added inline comments. Comment at: include/clang/AST/Expr.h:2802 - friend class ASTReader; - friend class ASTStmtWriter; }; Having this at the bottom is so painful for the reader, and people seems to put them at the top of the class usually. But

[PATCH] D40218: [Clang] Add __builtin_launder

2018-11-14 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF updated this revision to Diff 174109. EricWF added a comment. Merge with upstream. https://reviews.llvm.org/D40218 Files: include/clang/Basic/Builtins.def include/clang/Basic/DiagnosticSemaKinds.td lib/AST/ExprConstant.cpp lib/CodeGen/CGBuiltin.cpp lib/Sema/SemaChecking.cpp

[PATCH] D54553: [clangd] Fix crash hovering on non-decltype trailing return

2018-11-14 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle updated this revision to Diff 174117. malaperle added a comment. Fix comment in test Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D54553 Files: clangd/XRefs.cpp unittests/clangd/XRefsTests.cpp Index: unittests/clangd/XRefsTests.cpp

[PATCH] D54166: [AST] Store the string data in StringLiteral in a trailing array of chars

2018-11-14 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In https://reviews.llvm.org/D54166#1299149, @riccibruno wrote: > In https://reviews.llvm.org/D54166#1298889, @rjmccall wrote: > > > IIRC, abbreviations just silently don't take effect if the record doesn't > > conform; so things will appear to work, but the size on

[PATCH] D54489: Implement -frecord-command-line (-frecord-gcc-switches)

2018-11-14 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: docs/ClangCommandLineReference.rst:797 + +Generate a section .LLVM.command.line containing the clang driver command line. + 1. Is this section always called `.LLVM.command.line`, or does it differ by target

[PATCH] D54166: [AST] Store the string data in StringLiteral in a trailing array of chars

2018-11-14 Thread Bruno Ricci via Phabricator via cfe-commits
riccibruno added a comment. In https://reviews.llvm.org/D54166#1299230, @rjmccall wrote: > In https://reviews.llvm.org/D54166#1299149, @riccibruno wrote: > > > In https://reviews.llvm.org/D54166#1298889, @rjmccall wrote: > > > > > IIRC, abbreviations just silently don't take effect if the record

[PATCH] D54453: Remove myself as owner of clang-query.

2018-11-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. I'll go ahead and add myself as code owner. Peter can remove himself at his leisure. Repository: rL LLVM https://reviews.llvm.org/D54453

[PATCH] D51575: [clang-tidy/checks] Implement a clang-tidy check to verify Google Objective-C function naming conventions 

2018-11-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D51575#1297664, @stephanemoore wrote: > Thanks for the review everyone! > > Let me know if there are any further changes that you want me to make or any > further action required on my part to land this  It's good to go in -- do you

[PATCH] D54161: [AST] Pack DeclRefExpr, UnaryOperator, MemberExpr and BinaryOperator

2018-11-14 Thread Bruno Ricci via Phabricator via cfe-commits
riccibruno abandoned this revision. riccibruno added a comment. Broken into pieces and sent individually for review. Repository: rC Clang https://reviews.llvm.org/D54161 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D53427: [clangd] Replace StringRef in SymbolLocation with a char pointer.

2018-11-14 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added inline comments. Comment at: clang-tools-extra/trunk/clangd/index/Index.h:71 + // via llvm::StringRef. + const char *FileURI = ""; }; hokein wrote: > alexfh wrote: > > If the users of the SymbolLocation have a way to get a common "context", > >

r346866 - Reverted D52835 to fix review comments

2018-11-14 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed Nov 14 06:27:51 2018 New Revision: 346866 URL: http://llvm.org/viewvc/llvm-project?rev=346866=rev Log: Reverted D52835 to fix review comments Removed: cfe/trunk/test/Sema/impcast-integer-float.c Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td

[PATCH] D54391: Fix compatibility with z3-4.8.1

2018-11-14 Thread Mikhail Ramalho via Phabricator via cfe-commits
mikhail.ramalho added a comment. Since we're supporting version 4.8.1 now, the cmake file should be changed to "minimum" instead of "exact". Repository: rL LLVM https://reviews.llvm.org/D54391 ___ cfe-commits mailing list

[PATCH] D53427: [clangd] Replace StringRef in SymbolLocation with a char pointer.

2018-11-14 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clang-tools-extra/trunk/clangd/index/Index.h:71 + // via llvm::StringRef. + const char *FileURI = ""; }; alexfh wrote: > hokein wrote: > > alexfh wrote: > > > If the users of the SymbolLocation have a way to get a

[PATCH] D52835: [Diagnostics] Check integer to floating point number implicit conversions

2018-11-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D52835#1298428, @xbolva00 wrote: > Reverted. > Ok, I will address your comments soon. Thanks! I'm sorry for the delayed reviews -- there were wg21 meetings last week, which several of the reviewers were attending. Repository: rC

[PATCH] D54269: Introduce shard storage to auto-index.

2018-11-14 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet updated this revision to Diff 174017. kadircet marked 10 inline comments as done. kadircet added a comment. - Address comments. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D54269 Files: clangd/index/Background.cpp clangd/index/Background.h

[PATCH] D54204: [clangd] Initial clang-tidy diagnostics support.

2018-11-14 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. Looks mostly good, just a few nits. This patch contains two parts (clang-tidy and clangd), I think we could split into two, but I'm not insisting, up to you. Comment at: clang-tidy/modernize/LoopConvertUtils.h:59 /// \brief Run the analysis on

[clang-tools-extra] r346856 - Adding myself as the code owner for clang-query as discussed in https://reviews.llvm.org/D54453.

2018-11-14 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Wed Nov 14 05:03:50 2018 New Revision: 346856 URL: http://llvm.org/viewvc/llvm-project?rev=346856=rev Log: Adding myself as the code owner for clang-query as discussed in https://reviews.llvm.org/D54453. Modified: clang-tools-extra/trunk/CODE_OWNERS.TXT Modified:

[PATCH] D54525: [AST] Pack MemberExpr

2018-11-14 Thread Bruno Ricci via Phabricator via cfe-commits
riccibruno created this revision. riccibruno added a reviewer: dblaikie. riccibruno added a project: clang. Herald added a subscriber: cfe-commits. Use the newly available space in the bit-fields of `Stmt` to store some data from `MemberExpr`. This saves one pointer per `MemberExpr`.

[PATCH] D53427: [clangd] Replace StringRef in SymbolLocation with a char pointer.

2018-11-14 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tools-extra/trunk/clangd/index/Index.h:71 + // via llvm::StringRef. + const char *FileURI = ""; }; alexfh wrote: > If the users of the SymbolLocation have a way to get a common "context", you > could keep a

[PATCH] D54349: [clang-tidy] new check 'readability-redundant-preprocessor'

2018-11-14 Thread Miklos Vajna via Phabricator via cfe-commits
vmiklos updated this revision to Diff 174021. vmiklos marked 2 inline comments as done. https://reviews.llvm.org/D54349 Files: clang-tidy/readability/CMakeLists.txt clang-tidy/readability/ReadabilityTidyModule.cpp clang-tidy/readability/RedundantPreprocessorCheck.cpp

[PATCH] D54524: [AST] Pack UnaryOperator

2018-11-14 Thread Bruno Ricci via Phabricator via cfe-commits
riccibruno created this revision. riccibruno added a reviewer: dblaikie. riccibruno added a project: clang. Herald added a subscriber: cfe-commits. Use the newly available space in the bit-fields of `Stmt` to store some data from `UnaryOperator`. This saves 8 bytes per `UnaryOperator`.

r346864 - [AST][NFC] Order the bit-field classes of Stmt like in StmtNodes.td

2018-11-14 Thread Bruno Ricci via cfe-commits
Author: brunoricci Date: Wed Nov 14 06:19:34 2018 New Revision: 346864 URL: http://llvm.org/viewvc/llvm-project?rev=346864=rev Log: [AST][NFC] Order the bit-field classes of Stmt like in StmtNodes.td Reorder the bit-field classes and the members of the anonymous union so that they both match the

r346865 - [Diagnostics] Check integer to floating point number implicit conversions

2018-11-14 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed Nov 14 06:24:33 2018 New Revision: 346865 URL: http://llvm.org/viewvc/llvm-project?rev=346865=rev Log: [Diagnostics] Check integer to floating point number implicit conversions Summary: GCC already catches these situations so we should handle it too. GCC warns in C++

[PATCH] D52835: [Diagnostics] Check integer to floating point number implicit conversions

2018-11-14 Thread Dávid Bolvanský via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC346865: [Diagnostics] Check integer to floating point number implicit conversions (authored by xbolva00, committed by ). Changed prior to commit: https://reviews.llvm.org/D52835?vs=172509=174030#toc

[PATCH] D54269: Introduce shard storage to auto-index.

2018-11-14 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added inline comments. Comment at: clangd/index/Background.h:39 + + virtual llvm::Expected + loadShard(llvm::StringRef ShardIdentifier) const = 0; sammccall wrote: > sammccall wrote: > > docs > Hmm, we're going to attempt to load the shard

[PATCH] D54269: Introduce shard storage to auto-index.

2018-11-14 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet updated this revision to Diff 174019. kadircet added a comment. - Get rid off getIndexStorage and use IndexStorageCreator directly. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D54269 Files: clangd/index/Background.cpp clangd/index/Background.h

[PATCH] D54473: [sanitizers] Initial implementation for -fsanitize=init-locals

2018-11-14 Thread Alexander Potapenko via Phabricator via cfe-commits
glider added inline comments. Comment at: include/clang/Basic/Sanitizers.def:163 +// Initialize local variables. +SANITIZER("init-locals", InitLocals) + lebedev.ri wrote: > Unless i'm mistaken, I suspect you may see some surprising behavior here, >

[PATCH] D54450: Get the correct range of tokens for preprocessor conditions

2018-11-14 Thread Miklos Vajna via Phabricator via cfe-commits
vmiklos added a comment. Oh, and running the `check-clang-tools` target, this currently results in: Failing Tests (3): Clang Tools :: modularize/ProblemsInconsistent.modularize Clang Tools :: pp-trace/pp-trace-conditional.cpp Clang Tools :: pp-trace/pp-trace-macro.cpp

[PATCH] D53488: [clang-tidy] Improving narrowing conversions

2018-11-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: test/clang-tidy/cppcoreguidelines-narrowing-conversions.cpp:79-81 + // TODO: Provide an automatic fix if the number is exactly representable in the destination type. + f += 2.0; + // CHECK-MESSAGES: :[[@LINE-1]]:5: warning:

[PATCH] D54523: [Preamble] Reuse preamble even if an unsaved file does not exist

2018-11-14 Thread Nikolai Kosjar via Phabricator via cfe-commits
nik created this revision. Herald added a subscriber: cfe-commits. When a preamble is created an unsaved file not existing on disk is already part of PrecompiledPreamble::FilesInPreamble. However, when checking whether the preamble can be re-used, a failed stat of such an unsaved file invalidated

[PATCH] D54349: [clang-tidy] new check 'readability-redundant-preprocessor'

2018-11-14 Thread Miklos Vajna via Phabricator via cfe-commits
vmiklos marked 2 inline comments as done. vmiklos added inline comments. Comment at: clang-tidy/readability/ReadabilityTidyModule.cpp:84 +CheckFactories.registerCheck( +"readability-redundant-preprocessor"); CheckFactories.registerCheck(

[PATCH] D54526: [AST] Pack BinaryOperator

2018-11-14 Thread Bruno Ricci via Phabricator via cfe-commits
riccibruno created this revision. riccibruno added a reviewer: dblaikie. riccibruno added a project: clang. Herald added a subscriber: cfe-commits. Use the newly available space in the bit-fields of `Stmt`. This saves 8 bytes per `BinaryOperator`. Repository: rC Clang

[PATCH] D52835: [Diagnostics] Check integer to floating point number implicit conversions

2018-11-14 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. Ok, I will address your comments soon. Repository: rC Clang https://reviews.llvm.org/D52835 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D54269: Introduce shard storage to auto-index.

2018-11-14 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. just some nits. Main thing is the LoggingStorage - again I think this may have been a misunderstanding. Comment at: clangd/index/Background.cpp:76 +else + elog("Error while reading shard {0}: {1}", ShardIdentifier, +

[PATCH] D53427: [clangd] Replace StringRef in SymbolLocation with a char pointer.

2018-11-14 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added inline comments. Comment at: clang-tools-extra/trunk/clangd/index/Index.h:71 + // via llvm::StringRef. + const char *FileURI = ""; }; If the users of the SymbolLocation have a way to get a common "context", you could keep a list of filenames in

[PATCH] D41005: Reuse preamble even if an unsaved file does not exist

2018-11-14 Thread Nikolai Kosjar via Phabricator via cfe-commits
nik updated this revision to Diff 174022. nik added a comment. Addressed comments. Repository: rC Clang https://reviews.llvm.org/D41005 Files: include/clang/Frontend/ASTUnit.h lib/Frontend/ASTUnit.cpp lib/Frontend/PrecompiledPreamble.cpp unittests/Frontend/PCHPreambleTest.cpp

[PATCH] D54563: [analyzer] MoveChecker Pt.4: Add a few more state reset methods.

2018-11-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added reviewers: dcoughlin, xazax.hun, a.sidorin, george.karpenkov, szepet, rnkovacs, Szelethus. Herald added subscribers: cfe-commits, dkrupp, donat.nagy, mikhail.ramalho, baloghadamsoftware. This covers methods that //may// reset the state depending on the value

[PATCH] D54565: Introduce `-Wc++14-compat-ctad` as a subgroup of `-Wc++14-compat`

2018-11-14 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone updated this revision to Diff 174150. Quuxplusone added a comment. Fix naming. (Uploaded an earlier diff by accident.) Repository: rC Clang https://reviews.llvm.org/D54565 Files: include/clang/Basic/DiagnosticGroups.td include/clang/Basic/DiagnosticSemaKinds.td Index:

[PATCH] D54565: Introduce `-Wc++14-compat-ctad` as a subgroup of `-Wc++14-compat`

2018-11-14 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone updated this revision to Diff 174152. Quuxplusone added a comment. Third time's the charm! Repository: rC Clang https://reviews.llvm.org/D54565 Files: include/clang/Basic/DiagnosticGroups.td include/clang/Basic/DiagnosticSemaKinds.td Index:

[PATCH] D53417: [Clang][Sema][PowerPC] Choose a better candidate in overload function call if there is a compatible vector conversion instead of ambiguous call error

2018-11-14 Thread Hubert Tong via Phabricator via cfe-commits
hubert.reinterpretcast accepted this revision. hubert.reinterpretcast added a comment. This revision is now accepted and ready to land. LGTM. Comment at: clang/test/Sema/altivec-generic-overload.c:73 + + __v16sc *gv1_p = convert1(gv1); + __v16uc *gv2_p = convert1(gv2);

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

2018-11-14 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete added inline comments. Comment at: lib/Sema/Sema.cpp:2006-2019 +bool Sema::isDeclaratorFunctionLike(const Declarator ) { + assert(D.getCXXScopeSpec().isSet() && + "can only be called for qualified names"); + LookupResult LR(*this, D.getIdentifier(),

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

2018-11-14 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 174158. Rakete marked 11 inline comments as done. Rakete added a comment. Addressed review comments :) Repository: rC Clang https://reviews.llvm.org/D53847 Files: include/clang/Basic/DiagnosticSemaKinds.td include/clang/Parse/Parser.h

r346926 - Stmt bits: Make ExprBits relative to StmtBits

2018-11-14 Thread David Blaikie via cfe-commits
Author: dblaikie Date: Wed Nov 14 19:04:18 2018 New Revision: 346926 URL: http://llvm.org/viewvc/llvm-project?rev=346926=rev Log: Stmt bits: Make ExprBits relative to StmtBits Seems like it makes it a bit easier to read/validate/update in the future. Modified:

r346927 - Rewrite-imports on crash: Simplify handling

2018-11-14 Thread David Blaikie via cfe-commits
Author: dblaikie Date: Wed Nov 14 19:04:19 2018 New Revision: 346927 URL: http://llvm.org/viewvc/llvm-project?rev=346927=rev Log: Rewrite-imports on crash: Simplify handling -frewrite-imports already implies -frewrite-includes (it piggy-backs on/extends the implementation) so there's no need to

r346929 - NFC cleanup: Prefer make_unique over reset(new T())

2018-11-14 Thread David Blaikie via cfe-commits
Author: dblaikie Date: Wed Nov 14 19:04:23 2018 New Revision: 346929 URL: http://llvm.org/viewvc/llvm-project?rev=346929=rev Log: NFC cleanup: Prefer make_unique over reset(new T()) Modified: cfe/trunk/lib/Parse/ParsePragma.cpp Modified: cfe/trunk/lib/Parse/ParsePragma.cpp URL:

r346928 - Fix combining pragma __debug dump & parser_crash with -E

2018-11-14 Thread David Blaikie via cfe-commits
Author: dblaikie Date: Wed Nov 14 19:04:21 2018 New Revision: 346928 URL: http://llvm.org/viewvc/llvm-project?rev=346928=rev Log: Fix combining pragma __debug dump & parser_crash with -E Previously these would be transformed into annotation tokens and the preprocessor would then assume they were

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

2018-11-14 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete added inline comments. Comment at: include/clang/Parse/Parser.h:2119 DeclSpecContext DSC = DeclSpecContext::DSC_normal, - LateParsedAttrList *LateAttrs = nullptr); + LateParsedAttrList *LateAttrs = nullptr) { +return ParseDeclarationSpecifiers(DS,

[PATCH] D53702: [ASTImporter] Set redecl chain of functions before any other import

2018-11-14 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 reviewer: shafik. Herald added a subscriber: gamesh411. Hi Gabor, The change looks fine. Thanks! Repository: rC Clang https://reviews.llvm.org/D53702

[PATCH] D54557: [analyzer] MoveChecker Pt.2: Restrict the warning to STL objects and locals.

2018-11-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. So, like, with locals it should be possible to easily and intuitively suppress the false positive, even if there is one, by simply using an extra variable, and additionally there's the `[[clang::reinitializes]]` attribute added by @xazax.hun that will help people suppress

  1   2   >