[PATCH] D49838: [AST] Sink 'part of explicit cast' down into ImplicitCastExpr

2018-07-27 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC338108: [AST] Sink 'part of explicit cast' down into ImplicitCastExpr (authored by lebedevri, committed by ). Repository: rC Clang https://reviews.llvm.org/D49838 Files: include/clang/AST/Expr.h i

r338108 - [AST] Sink 'part of explicit cast' down into ImplicitCastExpr

2018-07-27 Thread Roman Lebedev via cfe-commits
Author: lebedevri Date: Fri Jul 27 00:27:14 2018 New Revision: 338108 URL: http://llvm.org/viewvc/llvm-project?rev=338108&view=rev Log: [AST] Sink 'part of explicit cast' down into ImplicitCastExpr Summary: As discussed in IRC with @rsmith, it is slightly not good to keep that in the `CastExpr`

Re: [PATCH] D49840: [AST] Add MatchFinder::matchSubtree

2018-07-27 Thread Manuel Klimek via cfe-commits
On Thu, Jul 26, 2018 at 12:44 PM Gabor Marton via Phabricator < revi...@reviews.llvm.org> wrote: > martong added a comment. > > > Usually we use match(anyOf(node), hasDescendant(node)). Or did I > misunderstand what you want? > > My understanding is that, the free function template `match` uses >

[PATCH] D49589: [UBSan] Strengthen pointer checks in 'new' expressions

2018-07-27 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Okay, thank you, that's better, but I should've been clearer. What I was really asking for was this: in *all* the code you're adding in this patch, where you've currently written `IsChecked` or `isChecked` or `NewPointerIsChecked`, please instead write `IsSanitizerChe

[PATCH] D49906: [Docs] Sanitizer update

2018-07-27 Thread David CARLIER via Phabricator via cfe-commits
devnexen created this revision. devnexen added a reviewer: eugenis. devnexen created this object with visibility "All Users". Herald added a subscriber: cfe-commits. - Adding new option detect_write_exec=1 available. Repository: rC Clang https://reviews.llvm.org/D49906 Files: docs/AddressS

[PATCH] D49840: [AST] Add MatchFinder::matchSubtree

2018-07-27 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. > MatchFinder::match allows you to match a node. Wrapping your matcher code > with: > auto m = ; > ast_matchers::match(anyOf(m, hashDescendant(m)), node, context); Okay, I understand and accept that. However, I consider that a different level of abstraction. `ast_matc

Re: [PATCH] D49840: [AST] Add MatchFinder::matchSubtree

2018-07-27 Thread Manuel Klimek via cfe-commits
On Fri, Jul 27, 2018 at 10:39 AM Gabor Marton via Phabricator < revi...@reviews.llvm.org> wrote: > martong added a comment. > > > MatchFinder::match allows you to match a node. Wrapping your matcher > code with: > > auto m = ; > > ast_matchers::match(anyOf(m, hashDescendant(m)), node, context);

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-27 Thread Martin Probst via Phabricator via cfe-commits
mprobst added inline comments. Comment at: unittests/Format/FormatTestComments.cpp:3109 +TEST_F(FormatTestComments, IndentsLongJavadocAnnotatedLines) { + FormatStyle Style = getGoogleStyle(FormatStyle::LK_Java); + Style.ColumnLimit = 60; mprobst wrote: > add a

[clang-tools-extra] r338116 - [clangd] Return Dex Iterators

2018-07-27 Thread Kirill Bobyrev via cfe-commits
Author: omtcyfz Date: Fri Jul 27 02:54:27 2018 New Revision: 338116 URL: http://llvm.org/viewvc/llvm-project?rev=338116&view=rev Log: [clangd] Return Dex Iterators The original Dex Iterators patch (https://reviews.llvm.org/rL338017) caused problems for Clang 3.6 and Clang 3.7 due to the compiler

[PATCH] D49840: [AST] Add MatchFinder::matchSubtree

2018-07-27 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. > Finder.match also has an overload that takes the node. Can you wrap "Pattern" > above in the anyOf(hasDescendant(...), ...) and match on the node instead of > the full AST? Ok, I changed and wrapped the pattern: template NodeType *match(const Decl *D, const Matc

[PATCH] D46013: [ARM] Conform to AAPCS when passing overaligned composites as arguments

2018-07-27 Thread Momchil Velikov via Phabricator via cfe-commits
chill updated this revision to Diff 157662. chill added a comment. Fixed to properly examine the canonical type when getting it's unadjusted alignment. https://reviews.llvm.org/D46013 Files: include/clang/AST/ASTContext.h include/clang/AST/RecordLayout.h lib/AST/ASTContext.cpp lib/AST/

[PATCH] D46013: [ARM] Conform to AAPCS when passing overaligned composites as arguments

2018-07-27 Thread Momchil Velikov via Phabricator via cfe-commits
chill marked an inline comment as done. chill added a comment. Thanks for pointing this! https://reviews.llvm.org/D46013 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D48958: [clang][ubsan] Implicit Cast Sanitizer - integer truncation - clang part

2018-07-27 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri updated this revision to Diff 157665. lebedev.ri marked 9 inline comments as done and 2 inline comments as done. lebedev.ri edited the summary of this revision. lebedev.ri added a comment. Hopefully address @rsmith review notes: - s/cast/conversion/ where appropriate - Some wording in

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: ClangTidy.cpp:612 + + FileManager *Files = new FileManager(FileSystemOptions()); + vfs::FileSystem &FileSystem = *Files->getVirtualFileSystem(); Eugene.Zelenko wrote: > You could use auto here, because type is in new

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Ahmad Nouralizadeh via Phabricator via cfe-commits
TheAhmad updated this revision to Diff 157667. TheAhmad marked an inline comment as done. TheAhmad added a comment. Added auto at line 612. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D49890 Files: ClangTidy.cpp Index: ClangTidy.cpp ===

[PATCH] D49910: Reviewers:

2018-07-27 Thread Martin Böhme via Phabricator via cfe-commits
mboehme created this revision. Herald added a subscriber: cfe-commits. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D49910 Files: clang-tidy/bugprone/UseAfterMoveCheck.cpp docs/clang-tidy/checks/bugprone-use-after-move.rst test/clang-tidy/bugprone-use-after-move.cpp Inde

[PATCH] D49910: Reviewers:

2018-07-27 Thread Martin Böhme via Phabricator via cfe-commits
mboehme updated this revision to Diff 157669. mboehme added a comment. [clang-tidy] Recognize [[clang::reinitializes]] attribute in bugprone-use-after-move. This allows member functions to be marked as reinitializing the object. After a moved-from object has been reinitialized, the check will n

[PATCH] D49911: Summary:Add clang::reinitializes attribute

2018-07-27 Thread Martin Böhme via Phabricator via cfe-commits
mboehme created this revision. Herald added a subscriber: cfe-commits. This is for use by clang-tidy's bugprone-use-after-move check -- see corresponding clang-tidy patch at https://reviews.llvm.org/D49910. Repository: rC Clang https://reviews.llvm.org/D49911 Files: include/clang/Basic/Att

[PATCH] D49758: [clangd] allow clients to pass in compilationDatabaseChanges in the 'workspace/didChangeConfiguration' request

2018-07-27 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In https://reviews.llvm.org/D49758#1177747, @arphaman wrote: > In https://reviews.llvm.org/D49758#1174629, @ilya-biryukov wrote: > > > The mode of operation where compile commands come from the client seems > > useful, but I wonder if there's any value in mixing it

[PATCH] D49240: [libc++] Introduce _LIBCPP_HIDE_FROM_ABI to replace _LIBCPP_INLINE_VISIBILITY

2018-07-27 Thread Louis Dionne via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCXX338122: [libc++] Introduce _LIBCPP_HIDE_FROM_ABI to replace _LIBCPP_INLINE_VISIBILITY (authored by ldionne, committed by ). Herald added a subscriber: cfe-commits. Changed prior to commit: https://rev

[libcxx] r338122 - [libc++] Introduce _LIBCPP_HIDE_FROM_ABI to replace _LIBCPP_INLINE_VISIBILITY

2018-07-27 Thread Louis Dionne via cfe-commits
Author: ldionne Date: Fri Jul 27 05:46:03 2018 New Revision: 338122 URL: http://llvm.org/viewvc/llvm-project?rev=338122&view=rev Log: [libc++] Introduce _LIBCPP_HIDE_FROM_ABI to replace _LIBCPP_INLINE_VISIBILITY Summary: This commit introduces a new macro, _LIBCPP_HIDE_FROM_ABI, whose goal is to

[PATCH] D49240: [libc++] Introduce _LIBCPP_HIDE_FROM_ABI to replace _LIBCPP_INLINE_VISIBILITY

2018-07-27 Thread Louis Dionne via Phabricator via cfe-commits
ldionne added a comment. Note: I resolved Eric's comments before pushing. Repository: rCXX libc++ https://reviews.llvm.org/D49240 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Ahmad Nouralizadeh via Phabricator via cfe-commits
TheAhmad updated this revision to Diff 157676. TheAhmad marked 4 inline comments as done. TheAhmad added a comment. Used make_pair instead of constructor call. Used unique_ptr. Used named cast. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D49890 Files: ClangTidy.cpp Index:

[PATCH] D49589: [UBSan] Strengthen pointer checks in 'new' expressions

2018-07-27 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff updated this revision to Diff 157677. sepavloff added a comment. Updated patch Use `SanitizerCheck` instead of `Check` in method and enum names. No functional changes. Repository: rC Clang https://reviews.llvm.org/D49589 Files: lib/CodeGen/CGClass.cpp lib/CodeGen/CGExprCXX.cpp

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. I'm not sure what this differential *actually* does. That being said https://clang.llvm.org/docs/JSONCompilationDatabase.html#format > directory: The working directory of the compilation. All paths specified in > the command or file fields must be either absolute or

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Also, please upload the patches with full context (`-U9`), and the patch is misformed, the `ClangTidy.cpp` isn't in the root directory. Also, tests. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D49890 _

[PATCH] D49725: [OpenCL] Forbid size dependent types used as kernel arguments

2018-07-27 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia accepted this revision. Anastasia added a comment. LGTM! Thanks! Repository: rC Clang https://reviews.llvm.org/D49725 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D49840: [AST] Add MatchFinder::matchSubtree

2018-07-27 Thread Manuel Klimek via cfe-commits
On Fri, Jul 27, 2018 at 12:43 PM Gabor Marton via Phabricator < revi...@reviews.llvm.org> wrote: > martong added a comment. > > > Finder.match also has an overload that takes the node. Can you wrap > "Pattern" above in the anyOf(hasDescendant(...), ...) and match on the node > instead of the full

[PATCH] D49758: [clangd] allow clients to pass in compilationDatabaseChanges in the 'workspace/didChangeConfiguration' request

2018-07-27 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clangd/Protocol.h:429 + // The changes that happened to the compilation database. + llvm::Optional>> + compilationDatabaseChanges; arphaman wrote: > ilya-biryukov wrote: > > - Maybe add a comment that the ke

[PATCH] D49723: [OpenCL] Check for invalid kernel arguments in array types

2018-07-27 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia added a comment. In https://reviews.llvm.org/D49723#1174837, @asavonic wrote: > In https://reviews.llvm.org/D49723#1173352, @Anastasia wrote: > > > Btw, has this restriction been removed from CL 2.0? > > > No, it applies for CL2.0 as well. It seems however the restriction on pointer t

[PATCH] D49914: [libc++] Add the _LIBCPP_HIDE_FROM_ABI_AFTER_V1 macro

2018-07-27 Thread Louis Dionne via Phabricator via cfe-commits
ldionne created this revision. ldionne added reviewers: EricWF, mclow.lists. Herald added subscribers: cfe-commits, dexonsmith, christof. ldionne added a comment. This is the second step of the proposal aiming to remove uses of `__always_inline__` in the visibility macros. This proposal is docume

[PATCH] D49914: [libc++] Add the _LIBCPP_HIDE_FROM_ABI_AFTER_V1 macro

2018-07-27 Thread Louis Dionne via Phabricator via cfe-commits
ldionne added a comment. This is the second step of the proposal aiming to remove uses of `__always_inline__` in the visibility macros. This proposal is documented on the list here: http://lists.llvm.org/pipermail/cfe-dev/2018-July/058633.html Repository: rCXX libc++ https://reviews.llvm.or

[PATCH] D49862: [clang-tidy] Fix a crash in fuchsia-multiple-inheritance

2018-07-27 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 157680. ilya-biryukov marked an inline comment as done. ilya-biryukov added a comment. - Move the test into an existing file Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D49862 Files: clang-tidy/fuchsia/MultipleInheritanceCheck.cpp

[PATCH] D49862: [clang-tidy] Fix a crash in fuchsia-multiple-inheritance

2018-07-27 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. (Duplicates https://reviews.llvm.org/D49158) Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D49862 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-27 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 157681. krasimir marked 3 inline comments as done. krasimir added a comment. - Address review comments Repository: rC Clang https://reviews.llvm.org/D49797 Files: lib/Format/BreakableToken.cpp lib/Format/BreakableToken.h lib/Format/ContinuationInd

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-27 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir marked an inline comment as done. krasimir added inline comments. Comment at: lib/Format/BreakableToken.cpp:526 + 0, Content[LineIndex].find_first_of(Blanks)); + if (FirstWord == "@param") +return Style.ContinuationIndentWidth; mprobst wrote: >

[PATCH] D38320: [clang] Fix serializers for `TypeTemplateParmDecl` + related types

2018-07-27 Thread Steve O'Brien via Phabricator via cfe-commits
elsteveogrande updated this revision to Diff 157682. elsteveogrande added a comment. Herald added a subscriber: chrib. Rebase very old diff Repository: rC Clang https://reviews.llvm.org/D38320 Files: lib/Serialization/ASTReaderDecl.cpp lib/Serialization/ASTWriterDecl.cpp test/PCH/cxx-t

[PATCH] D49862: [clang-tidy] Fix a crash in fuchsia-multiple-inheritance

2018-07-27 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL338124: [clang-tidy] Fix a crash in fuchsia-multiple-inheritance (authored by ibiryukov, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D49862 Fi

[clang-tools-extra] r338124 - [clang-tidy] Fix a crash in fuchsia-multiple-inheritance

2018-07-27 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Fri Jul 27 07:05:39 2018 New Revision: 338124 URL: http://llvm.org/viewvc/llvm-project?rev=338124&view=rev Log: [clang-tidy] Fix a crash in fuchsia-multiple-inheritance Summary: See the test case for a repro. Reviewers: juliehockett, ioeric, hokein, aaron.ballman Reviewe

[PATCH] D49840: [AST] Add MatchFinder::matchSubtree

2018-07-27 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. > If you know the node is a decl, wrapping it in decl() should be enough. > Does this work? > auto WrappedMatcher = decl(anyOf(...)); Unfortunately this gives again the private ctor error (the same error when I called explicitly the overload with the `DeclarationMatche

[PATCH] D49723: [OpenCL] Check for invalid kernel arguments in array types

2018-07-27 Thread Andrew Savonichev via Phabricator via cfe-commits
asavonic added a comment. In https://reviews.llvm.org/D49723#1178127, @Anastasia wrote: > In https://reviews.llvm.org/D49723#1174837, @asavonic wrote: > > > In https://reviews.llvm.org/D49723#1173352, @Anastasia wrote: > > > > > Btw, has this restriction been removed from CL 2.0? > > > > > > No,

[PATCH] D49723: [OpenCL] Check for invalid kernel arguments in array types

2018-07-27 Thread Andrew Savonichev via Phabricator via cfe-commits
asavonic updated this revision to Diff 157685. asavonic marked an inline comment as done. asavonic added a comment. Fix assert. Repository: rC Clang https://reviews.llvm.org/D49723 Files: lib/Sema/SemaDecl.cpp test/SemaOpenCL/invalid-kernel-parameters.cl Index: test/SemaOpenCL/invalid-k

[PATCH] D49916: [CodeGen] Add to emitted DebugLoc information about coverage when it's required

2018-07-27 Thread calixte via Phabricator via cfe-commits
calixte created this revision. calixte added reviewers: marco-c, davidxl. Herald added a subscriber: cfe-commits. Some lines have a hit counter where they should not have one. Cleanup stuff is located to the last line of the body which is most of the time a '}'. And Exception stuff is added at th

[PATCH] D49723: [OpenCL] Check for invalid kernel arguments in array types

2018-07-27 Thread Andrew Savonichev via Phabricator via cfe-commits
asavonic updated this revision to Diff 157688. asavonic added a comment. Rollback accidentally squashed commit. Repository: rC Clang https://reviews.llvm.org/D49723 Files: lib/Sema/SemaDecl.cpp test/SemaOpenCL/invalid-kernel-parameters.cl Index: test/SemaOpenCL/invalid-kernel-parameter

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. In https://reviews.llvm.org/D49890#1178103, @lebedev.ri wrote: > I'm not sure what this differential *actually* does. This is a follow up from this discussion on the mailing list: http://clang-developers.42468.n3.nabble.com/Fwd-Running-Clang-Tidy-on-a-Large-Project-t

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: ClangTidy.cpp:612 + + std::unique_ptr Files = + make_unique(FileSystemOptions()); in this case you can use `auto` again, because the type of the `unique_ptr` is clear from the `make_unique` call. Repository:

[PATCH] D49899: Make test/Driver/fuchsia.c(pp) work with lld or gold

2018-07-27 Thread David Greene via Phabricator via cfe-commits
greened updated this revision to Diff 157689. greened added a comment. The Fuchsia driver relies on lld so invoke clang with -fuse-ld=lld. This gets the test passing when the clang default linker is something other than lld. https://reviews.llvm.org/D49899 Files: test/Driver/fuchsia.c tes

[PATCH] D49918: [clang-tidy] Sequence declaration in while statement before the condition

2018-07-27 Thread Martin Böhme via Phabricator via cfe-commits
mboehme created this revision. mboehme added a reviewer: ilya-biryukov. Herald added subscribers: cfe-commits, xazax.hun. Fixes https://bugs.llvm.org/show_bug.cgi?id=36516. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D49918 Files: clang-tidy/utils/ExprSequence.cpp test/cl

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In https://reviews.llvm.org/D49890#1178211, @JonasToth wrote: > In https://reviews.llvm.org/D49890#1178103, @lebedev.ri wrote: > > > I'm not sure what this differential *actually* does. > > > This is a follow up from this discussion on the mailing list: > http://clang

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Ahmad Nouralizadeh via Phabricator via cfe-commits
TheAhmad added a comment. The most comprehensive fix is to support all possible valid compilation databases. The current fix is the fastest one. > Can you just make clang-tidy respect the directory value? This is exactly what I did. I prepended the directory value to the file value and stored

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-27 Thread Martin Probst via Phabricator via cfe-commits
mprobst accepted this revision. mprobst added inline comments. This revision is now accepted and ready to land. Comment at: lib/Format/Format.cpp:814 +// by qualified identifiers. +GoogleStyle.CommentPragmas = "(taze:|^/[ \t]*<|@see|@exports|@module|@mods)"; GoogleS

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Ahmad Nouralizadeh via Phabricator via cfe-commits
TheAhmad added a comment. > Also, tests. What should I provide for tests? Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D49890 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/c

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: ClangTidy.cpp:614 + vfs::FileSystem &FileSystem = *Files->getVirtualFileSystem(); + auto InitialWorkingDir = FileSystem.getCurrentWorkingDirectory(); + if (!InitialWorkingDir) TheAhmad wrote: > Eugene.Zelenko wrote:

[PATCH] D49914: [libc++] Add the _LIBCPP_HIDE_FROM_ABI_AFTER_V1 macro

2018-07-27 Thread Louis Dionne via Phabricator via cfe-commits
ldionne updated this revision to Diff 157696. ldionne added a comment. Document the macro in the official documentation instead of the header, per Eric's comment on a previous patch of mine. Repository: rCXX libc++ https://reviews.llvm.org/D49914 Files: libcxx/docs/DesignDocs/VisibilityMac

[PATCH] D49890: Clang-Tidy Export Problem

2018-07-27 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. Actually, maybe this patch is relevant for clang-tooling itself (where the compilation-database stuff actually is). @alexfh what is your opinion on that? `llvm/tools/clang/unittests/Tooling/CompilationDatabaseTest.cpp` This is the path for the unittests there. `llvm/t

[PATCH] D38320: [clang] Fix serializers for `TypeTemplateParmDecl` + related types

2018-07-27 Thread Steve O'Brien via Phabricator via cfe-commits
elsteveogrande added a comment. cc @rsmith as this has to do with modules. Verified that (1) existing tests pass on trunk; (2) the new test included here fails when applied to trunk; (3) all tests (including new test) pass when this patch is applied. Repository: rC Clang https://reviews.ll

[PATCH] D49511: [Sema/Attribute] Check for noderef attribute

2018-07-27 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: include/clang/Basic/AttrDocs.td:3426 + let Content = [{ +The ``noderef`` attribute causes clang to throw a warning whenever a pointer marked with +this attribute is dereferenced. This is ideally used with pointers that point to

[PATCH] D47618: __c11_atomic_load's _Atomic can be const

2018-07-27 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia added inline comments. Comment at: test/SemaOpenCL/atomic-ops.cl:61 __opencl_atomic_load(d, memory_order_seq_cst, memory_scope_work_group); - __opencl_atomic_load(ci, memory_order_seq_cst, memory_scope_work_group); // expected-error {{address argument to atomic ope

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-27 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: lib/Format/Format.cpp:814 +// by qualified identifiers. +GoogleStyle.CommentPragmas = "(taze:|^/[ \t]*<|@see|@exports|@module|@mods)"; GoogleStyle.MaxEmptyLinesToKeep = 3; mprobst wrote: > `@exports` isn't

[PATCH] D49723: [OpenCL] Check for invalid kernel arguments in array types

2018-07-27 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia accepted this revision. Anastasia added a comment. LGTM! Thanks! Repository: rC Clang https://reviews.llvm.org/D49723 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D48958: [clang][ubsan] Implicit Cast Sanitizer - integer truncation - clang part

2018-07-27 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Oops, forgot to submit the inline comments. (It is inconvenient that they aren't submitted with the rest.) Comment at: docs/ReleaseNotes.rst:292 + store = store + 768; // before addition, 'store' was promoted to int. +(void)consume((

[PATCH] D47154: Try to make builtin address space declarations not useless

2018-07-27 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia accepted this revision. Anastasia added a comment. This revision is now accepted and ready to land. LGTM from OpenCL side! Thanks! Comment at: test/SemaOpenCL/numbered-address-space.cl:9 +void test_numeric_as_to_generic_explicit_cast(__attribute__((address_space(3)))

[PATCH] D49223: [AST] Check described template at structural equivalence check.

2018-07-27 Thread Gabor Marton via Phabricator via cfe-commits
martong accepted this revision. martong added a comment. This revision is now accepted and ready to land. LGTM. Repository: rC Clang https://reviews.llvm.org/D49223 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi

[PATCH] D47154: Try to make builtin address space declarations not useless

2018-07-27 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl requested changes to this revision. yaxunl added inline comments. This revision now requires changes to proceed. Comment at: lib/Basic/Targets/AMDGPU.h:398 + + LangAS getCUDABuiltinAddressSpace(unsigned AS) const override { +return LangAS::Default; I

[PATCH] D49914: [libc++] Add the _LIBCPP_HIDE_FROM_ABI_AFTER_V1 macro

2018-07-27 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added a comment. This looks correct to me, but I wouldn't mind having someone else take a look too. Comment at: libcxx/include/__config:798 -// Just so we can migrate to _LIBCPP_HIDE_FROM_ABI gradually. -#define _LIBCPP_INLINE_VISIBILITY _LIBCPP_HIDE_FROM_ABI - -#

[PATCH] D49701: [ASTMatchers] Introduce a matcher for `ObjCIvarExpr`, support getting it's declaration

2018-07-27 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. @aaron.ballman @alexfh Further concerns? https://reviews.llvm.org/D49701 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D47154: Try to make builtin address space declarations not useless

2018-07-27 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added inline comments. Comment at: include/clang/Basic/TargetInfo.h:1157 + /// language address space. + virtual LangAS getCUDABuiltinAddressSpace(unsigned AS) const { +return getLangASFromTargetAS(AS); I think this function is not needed. Although

[PATCH] D49701: [ASTMatchers] Introduce a matcher for `ObjCIvarExpr`, support getting it's declaration

2018-07-27 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. LGTM! Comment at: clang/include/clang/ASTMatchers/ASTMatchersInternal.h:44 #include "clang/AST/Expr.h" +#include "clang/AST/ExprObjC.h" #include "clang/AST/Ex

[PATCH] D47154: Try to make builtin address space declarations not useless

2018-07-27 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added inline comments. Comment at: test/CodeGenOpenCL/builtins-amdgcn.cl:3 +// RUN: %clang_cc1 -cl-std=CL2.0 -triple amdgcn-unknown-unknown -S -emit-llvm -o - %s | FileCheck -enable-var-scope %s +// RUN: %clang_cc1 -cl-std=CL2.0 -triple amdgcn-unknown-unknown-opencl -S -

r338135 - Add missing temporary materialization conversion on left-hand side of .

2018-07-27 Thread Richard Smith via cfe-commits
Author: rsmith Date: Fri Jul 27 10:13:18 2018 New Revision: 338135 URL: http://llvm.org/viewvc/llvm-project?rev=338135&view=rev Log: Add missing temporary materialization conversion on left-hand side of . in some member function calls. Specifically, when calling a conversion function, we would fa

[PATCH] D49589: [UBSan] Strengthen pointer checks in 'new' expressions

2018-07-27 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. Thanks, that'll do. Repository: rC Clang https://reviews.llvm.org/D49589 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://li

Re: [PATCH] D49898: Make test/Driver/baremetal.cpp work with linkers other than lld

2018-07-27 Thread Jon Roelofs via cfe-commits
LGTM Jon On Thu, Jul 26, 2018 at 10:12 PM David Greene via Phabricator < revi...@reviews.llvm.org> wrote: > greened created this revision. > greened added reviewers: jroelofs, hans, probinson, ismail, rtrieu. > Herald added a subscriber: cfe-commits. > > This test fails if clang is configure wit

[PATCH] D49758: [clangd] allow clients to pass in compilationDatabaseChanges in the 'workspace/didChangeConfiguration' request

2018-07-27 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. In https://reviews.llvm.org/D49758#1178056, @ilya-biryukov wrote: > In https://reviews.llvm.org/D49758#1177747, @arphaman wrote: > > > In https://reviews.llvm.org/D49758#1174629, @ilya-biryukov wrote: > > > > > The mode of operation where compile commands come from the c

[PATCH] D47154: Try to make builtin address space declarations not useless

2018-07-27 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added a comment. In https://reviews.llvm.org/D47154#1108813, @tra wrote: > CUDA does not expose explicit AS on clang size. All pointers are treated as > generic and we infer specific address space only in LLVM. > `__nvvm_atom_*_[sg]_*` builtins should probably be removed as they are > i

[PATCH] D49701: [ASTMatchers] Introduce a matcher for `ObjCIvarExpr`, support getting it's declaration

2018-07-27 Thread George Karpenkov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL338137: [ASTMatchers] Introduce a matcher for `ObjCIvarExpr`, support getting it's… (authored by george.karpenkov, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: http

r338137 - [ASTMatchers] Introduce a matcher for `ObjCIvarExpr`, support getting it's declaration.

2018-07-27 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Fri Jul 27 10:26:11 2018 New Revision: 338137 URL: http://llvm.org/viewvc/llvm-project?rev=338137&view=rev Log: [ASTMatchers] Introduce a matcher for `ObjCIvarExpr`, support getting it's declaration. ObjCIvarExpr is *not* a subclass of MemberExpr, and a separate ma

[libcxxabi] r338138 - [demangler] Support for reference collapsing

2018-07-27 Thread Erik Pilkington via cfe-commits
Author: epilk Date: Fri Jul 27 10:27:40 2018 New Revision: 338138 URL: http://llvm.org/viewvc/llvm-project?rev=338138&view=rev Log: [demangler] Support for reference collapsing llvm.org/PR38323 Modified: libcxxabi/trunk/src/cxa_demangle.cpp libcxxabi/trunk/test/test_demangle.pass.cpp Mo

[PATCH] D49589: [UBSan] Strengthen pointer checks in 'new' expressions

2018-07-27 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff added a comment. @rjmccall Thank you! Repository: rC Clang https://reviews.llvm.org/D49589 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r338139 - [OPENMP] Static variables on device must be externally visible.

2018-07-27 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Fri Jul 27 10:37:32 2018 New Revision: 338139 URL: http://llvm.org/viewvc/llvm-project?rev=338139&view=rev Log: [OPENMP] Static variables on device must be externally visible. Do not mark static variable as internal on the device as they must be visible from the host to be m

r338140 - [ASTMatchers] Introduce a matcher for `ObjCIvarExpr`, support getting it's declaration

2018-07-27 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Fri Jul 27 10:40:59 2018 New Revision: 338140 URL: http://llvm.org/viewvc/llvm-project?rev=338140&view=rev Log: [ASTMatchers] Introduce a matcher for `ObjCIvarExpr`, support getting it's declaration ObjCIvarExpr is *not* a subclass of MemberExpr, and a separate mat

[PATCH] D49920: [clangd] [WIP] Find references of local symbols

2018-07-27 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle created this revision. Herald added subscribers: cfe-commits, arphaman, mgrang, jkorous, MaskRay, ioeric, ilya-biryukov. We do not have a global index of references but we can find the references of local symbols within the AST in the mean time. Also, since we will not record local symb

[PATCH] D43871: [modules] No longer include stdlib.h from mm_malloc.h.

2018-07-27 Thread Raphael Isemann via Phabricator via cfe-commits
teemperor planned changes to this revision. teemperor marked an inline comment as done. teemperor added a comment. (Just marking this as "Plan changes" because otherwise it's just stuck in my "Waiting on review" queue). https://reviews.llvm.org/D43871

[PATCH] D49922: [P0936R0] add [[clang::lifetimebound]] attribute

2018-07-27 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith created this revision. rsmith added a reviewer: aaron.ballman. Herald added a reviewer: javed.absar. Herald added a subscriber: kristof.beyls. This patch adds support for a new attribute, [[clang::lifetimebound]], that indicates that the lifetime of a function result is related to one of t

r338141 - Fix typos in comment.

2018-07-27 Thread Richard Smith via cfe-commits
Author: rsmith Date: Fri Jul 27 11:06:54 2018 New Revision: 338141 URL: http://llvm.org/viewvc/llvm-project?rev=338141&view=rev Log: Fix typos in comment. Modified: cfe/trunk/include/clang/AST/TypeLoc.h Modified: cfe/trunk/include/clang/AST/TypeLoc.h URL: http://llvm.org/viewvc/llvm-project

[PATCH] D48341: [clang-doc] Refactoring mapper to map by scope

2018-07-27 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett added a comment. any further thoughts on this? https://reviews.llvm.org/D48341 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D49922: [P0936R0] add [[clang::lifetimebound]] attribute

2018-07-27 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: include/clang/AST/TypeLoc.h:96-97 /// Convert to the specified TypeLoc type, returning a null TypeLoc if - /// this TypeLock is not of the desired type. It will consider type - /// adjustments from a type that wad written as a T to a

Re: r338139 - [OPENMP] Static variables on device must be externally visible.

2018-07-27 Thread Jonas Hahnfeld via cfe-commits
Hi Alexey, from what I can see this change can't handle the case where there are static variables with the same name in multiple TUs. (The same problem exists for static CUDA kernels with -fcuda-rdc. I found that nvcc mangles the function names in this case, but didn't have time yet to prepare

[PATCH] D49766: Fix a crash when an error occurs in Template and the initializer is a nullptr for C++17

2018-07-27 Thread Balaji Iyer via Phabricator via cfe-commits
bviyer updated this revision to Diff 157721. bviyer added a comment. I have fixed all the changes requested by Erik along with shortening the test case. Repository: rC Clang https://reviews.llvm.org/D49766 Files: include/clang/AST/TemplateBase.h test/SemaObjCXX/class-templ-error-null-in

[PATCH] D49865: Inform the AST of #pragma FENV_ACCESS use

2018-07-27 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. Thanks, this is definitely a step in the right direction. Comment at: include/clang/AST/Expr.h:3257-3261 + // Get the FENV_ACCESS status of this operator. Only meaningful for + // operations on floating point types. + bool isFENVAccessOn() const { +

r338149 - [analyzer] Extend NoStoreFuncVisitor to insert a note on IVars

2018-07-27 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Fri Jul 27 11:26:40 2018 New Revision: 338149 URL: http://llvm.org/viewvc/llvm-project?rev=338149&view=rev Log: [analyzer] Extend NoStoreFuncVisitor to insert a note on IVars The note is added in the following situation: - We are throwing a nullability-related war

[PATCH] D49914: [libc++] Add the _LIBCPP_HIDE_FROM_ABI_AFTER_V1 macro

2018-07-27 Thread Louis Dionne via Phabricator via cfe-commits
ldionne added inline comments. Comment at: libcxx/include/__config:798 -// Just so we can migrate to _LIBCPP_HIDE_FROM_ABI gradually. -#define _LIBCPP_INLINE_VISIBILITY _LIBCPP_HIDE_FROM_ABI - -#ifndef _LIBCPP_EXTERN_TEMPLATE_INLINE_VISIBILITY -# if !defined(_LIBCPP_DISABLE_VI

Re: r337746 - [clang-cl] Expose -fblocks and -fno-builtin as driver flags

2018-07-27 Thread Reid Kleckner via cfe-commits
On Wed, Jul 25, 2018 at 4:39 AM Nico Weber wrote: > I thought about adding -fblocks when that thread happened, but since > there's no runtime for them that just works exposing it doesn't seem very > helpful. Maybe we should instead change the warning text to not suggest > -fblocks when building o

[PATCH] D49766: Fix a crash when an error occurs in Template and the initializer is a nullptr for C++17

2018-07-27 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington accepted this revision. erik.pilkington added a comment. This revision is now accepted and ready to land. LGTM, thanks! Do you have your commit rights yet? Comment at: include/clang/AST/TemplateBase.h:469 + +// Allow more additional argument kinds for the co

[PATCH] D49899: Force test/Driver/fuchsia.c(pp) to use lld

2018-07-27 Thread Rui Ueyama via Phabricator via cfe-commits
ruiu added a comment. > The Fuchsia driver relies on lld so invoke clang with -fuse-ld=lld. This gets > the test passing when the clang default linker is something other than lld. Does it work if lld is not installed at all? I believe if the driver cannot find a specified linker, it reports an

[PATCH] D49439: [Sema] Fix a crash while converting constructors to deduction guides

2018-07-27 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Sema/SemaTemplate.cpp:1899-1907 // Canonicalize the type. This (for instance) replaces references to // typedef members of the current ins

[PATCH] D49766: Fix a crash when an error occurs in Template and the initializer is a nullptr for C++17

2018-07-27 Thread Balaji Iyer via Phabricator via cfe-commits
bviyer updated this revision to Diff 157730. bviyer added a comment. Fixed the comment as you suggested. I do not have check in rights yet. Can you please check it in for me? Repository: rC Clang https://reviews.llvm.org/D49766 Files: include/clang/AST/TemplateBase.h test/SemaObjCXX/cla

[PATCH] D49511: [Sema/Attribute] Check for noderef attribute

2018-07-27 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. In https://reviews.llvm.org/D49511#1170693, @leonardchan wrote: > Done. I opted for not using `ExpressionEvaluationContextRecord` because I > don't think I was using it correctly. A few other tests in sema failed when I > tried pushing and popping from the stack holding

[PATCH] D49920: [clangd] [WIP] Find references of local symbols

2018-07-27 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle updated this revision to Diff 157732. malaperle added a comment. Fix silly bug I introduced in last minute clean-up. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D49920 Files: clangd/ClangdLSPServer.cpp clangd/ClangdLSPServer.h clangd/ClangdServer.cpp clangd/

[PATCH] D49920: [clangd] [WIP] Find references of local symbols

2018-07-27 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle planned changes to this revision. malaperle added a comment. Needs tests. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D49920 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/l

[PATCH] D49927: [libc++] Exclude posix_l/strtonum fallback inclusion for newlib > 2.4

2018-07-27 Thread Jordan Rupprecht via Phabricator via cfe-commits
rupprecht created this revision. rupprecht added reviewers: ldionne, rsmith. Herald added a reviewer: EricWF. Herald added subscribers: cfe-commits, christof. [libc++] Exclude posix_l/strtonum fallback inclusion for newlib > 2.4 r338122 changed the linkage of some methods which revealed an existi

  1   2   >