Re: [PATCH] D21279: Fix some issues in clang-format's AlignConsecutive modes

2016-08-10 Thread Ben Harper via cfe-commits
PING. Is there anything I can do to make reviewing easier? For example, I could run my code vs master on some large code bases (eg linux kernel, chromium), and verify that there are no crashes, and also manually spot check some results. Ben On Wed, 20 Jul 2016 at 21:43 Ben Harper wrote: > bmh

r278315 - bindings: expose diagnostic formatting to Python

2016-08-10 Thread Saleem Abdulrasool via cfe-commits
Author: compnerd Date: Thu Aug 11 00:31:07 2016 New Revision: 278315 URL: http://llvm.org/viewvc/llvm-project?rev=278315&view=rev Log: bindings: expose diagnostic formatting to Python This makes it easier for tools using the Python libclang bindings to display diagnostics in a manner consistent w

Re: [PATCH] D23284: Add -Rpass-with-hotness

2016-08-10 Thread Adam Nemet via cfe-commits
anemet updated this revision to Diff 67653. anemet added a comment. Since -Rpass-with-hotness is not part of R_group, we need to manually forward it to clang -cc1. I've also extended the test to cover this bug. https://reviews.llvm.org/D23284 Files: include/clang/Basic/DiagnosticDriverKinds.

[libcxx] r278311 - Add missing REQUIRES for C++14

2016-08-10 Thread Eric Fiselier via cfe-commits
Author: ericwf Date: Wed Aug 10 22:33:41 2016 New Revision: 278311 URL: http://llvm.org/viewvc/llvm-project?rev=278311&view=rev Log: Add missing REQUIRES for C++14 Modified: libcxx/trunk/test/libcxx/utilities/any/size_and_alignment.pass.cpp libcxx/trunk/test/libcxx/utilities/any/small_typ

Re: [libcxx] r278191 - test/hard_link_count(): Fix test on darwin

2016-08-10 Thread Eric Fiselier via cfe-commits
Thanks Matthias. My apoligies, I lost track of this patch. On Tue, Aug 9, 2016 at 7:31 PM, Bruno Cardoso Lopes via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Thanks Matthias! > > On Tue, Aug 9, 2016 at 6:02 PM, Matthias Braun via cfe-commits > wrote: > > Author: matze > > Date: Tue Aug

Re: [PATCH] D22782: Added 'inline' attribute to __init to inline the basic_string's constructor

2016-08-10 Thread Eric Fiselier via cfe-commits
On Mon, Aug 8, 2016 at 9:32 AM, David Blaikie via cfe-commits < cfe-commits@lists.llvm.org> wrote: > I'm still (as per another similar thread) a bit concerned this is working > around a compiler optimizer bug - I'd love to see a standalone example of > this behavior (that adding the inline keyword

Re: [PATCH] D23125: Modules: add command line option to support loading prebuilt modules on demand, without parsing any module map

2016-08-10 Thread Bruno Cardoso Lopes via cfe-commits
bruno added inline comments. Comment at: lib/Frontend/CompilerInstance.cpp:1438-1450 @@ -1437,3 +1437,15 @@ // Search for a module with the given name. Module = PP->getHeaderSearchInfo().lookupModule(ModuleName); -if (!Module) { +HeaderSearchOptions &HSOpts = +

Re: [PATCH] D22711: Diagnose invalid failure memory orderings.

2016-08-10 Thread JF Bastien via cfe-commits
jfb added a comment. Warnings look correct. Could they be made more useful by suggesting that `acq_rel` be `acquire` instead, and `release` be `relaxed` instead? https://reviews.llvm.org/D22711 ___ cfe-commits mailing list cfe-commits@lists.llvm.or

r278306 - [Order Files] Don't use empty order files

2016-08-10 Thread Chris Bieneman via cfe-commits
Author: cbieneman Date: Wed Aug 10 19:19:51 2016 New Revision: 278306 URL: http://llvm.org/viewvc/llvm-project?rev=278306&view=rev Log: [Order Files] Don't use empty order files LD64 does optimization on symbol layouts that gets disabled whenever an order file is passed (even if it is empty). Th

Re: [PATCH] D22711: Diagnose invalid failure memory orderings.

2016-08-10 Thread Eric Fiselier via cfe-commits
EricWF added a comment. ping. Clang correctly lowers the invalid memory orders, so do we want these diagnostics? https://reviews.llvm.org/D22711 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/

Re: [PATCH] D23125: Modules: add command line option to support loading prebuilt modules on demand, without parsing any module map

2016-08-10 Thread Manman Ren via cfe-commits
manmanren added a comment. Thanks, Manman Comment at: include/clang/Lex/HeaderSearchOptions.h:96-97 @@ -95,1 +95,4 @@ + /// \brief The directory used to load prebuilt module files. + std::string PrebuiltModulePath; + rsmith wrote: > It would seem preferable

Re: [PATCH] D23003: [ObjC Availability] Warn upon unguarded use of partially available declaration

2016-08-10 Thread Manman Ren via cfe-commits
manmanren added a comment. This looks pretty good. Can you add a few more testing cases for templates such as @available inside the template function, @available enclosing the template instantiation? Cheers, Manman Comment at: lib/Sema/SemaDeclAttr.cpp:6634 @@ +6633,3 @@ + /

Re: [libcxx] r278282 - std:: quailfy the calls for cend/crend/cbegin/cend. Fixes bug 28927.

2016-08-10 Thread Eric Fiselier via cfe-commits
I would support merging this change. /Eric On Wed, Aug 10, 2016 at 3:20 PM, Hans Wennborg via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Should we merge this to 3.9? Looks like a straight-forward fix for > something that was hit by real code. > > Thanks, > Hans > > On Wed, Aug 10, 2016 a

Re: [PATCH] D23385: Implement __has_constant_initializer(obj) expression traits.

2016-08-10 Thread Eric Fiselier via cfe-commits
EricWF updated this revision to Diff 67635. EricWF added a comment. Check the initializers of TLS_Dynamic variables since they may actually be non-dynamic. https://reviews.llvm.org/D23385 Files: include/clang/AST/Expr.h include/clang/Basic/DiagnosticSemaKinds.td include/clang/Basic/Expre

Re: [PATCH] D23385: Implement __has_constant_initializer(obj) expression traits.

2016-08-10 Thread Eric Fiselier via cfe-commits
EricWF added a comment. Open questions: - What should __has_constant_initializer do for non-static inputs? Currently it returns false. - Do I need to do more to handle value dependent inputs? - Should expression traits SFINAE? https://reviews.llvm.org/D23385 __

[PATCH] D23385: Implement __has_constant_initializer(obj) expression traits.

2016-08-10 Thread Eric Fiselier via cfe-commits
EricWF created this revision. EricWF added reviewers: aaron.ballman, rsmith, majnemer. EricWF added a subscriber: cfe-commits. Safe static initialization is hard to do correctly in C++. The static initialization order fiasco often causes bugs when variables are dynamically initialized. However

Re: [PATCH] D23125: Modules: add command line option to support loading prebuilt modules on demand, without parsing any module map

2016-08-10 Thread Richard Smith via cfe-commits
rsmith added inline comments. Comment at: include/clang/Lex/HeaderSearchOptions.h:96-97 @@ -95,1 +95,4 @@ + /// \brief The directory used to load prebuilt module files. + std::string PrebuiltModulePath; + It would seem preferable to allow multiple of these, to

Re: [PATCH] D23096: [Sema] Pass CombineWithOuterScope = true to constructor of LocalInstantiationScope

2016-08-10 Thread Akira Hatanaka via cfe-commits
ahatanak updated this revision to Diff 67623. ahatanak added a comment. Handle the case in which the enum is declared inside a member function and add test cases. The variable template test case still crashes. It looks like it crashes whenever the lambda expression takes a default argument: te

Re: [PATCH] D23331: Implement LWG 2148: Make non-enum default hash specialization well-formed

2016-08-10 Thread Eric Fiselier via cfe-commits
EricWF accepted this revision. EricWF added a reviewer: EricWF. EricWF added a comment. This revision is now accepted and ready to land. In https://reviews.llvm.org/D23331#511204, @mclow.lists wrote: > This looks good to me. > However, we don't //usually// change libc++ for issue resolutions tha

RE: [clang-tools-extra] r278257 - [clang-tidy] enhance readability-else-after-return

2016-08-10 Thread Yung, Douglas via cfe-commits
Hi Kirill, I believe your change is causing the PS4 bots to be red. Specifically, the test you added makes use of "throw" which doesn't work on the PS4 target since exceptions are disabled by default on the PS4 target. I think explicitly enabling exceptions should fix the test and propose the f

[libcxx] r278300 - Implement LWG 2148: Make non-enum default hash specialization well-formed

2016-08-10 Thread Eric Fiselier via cfe-commits
Author: ericwf Date: Wed Aug 10 17:45:26 2016 New Revision: 278300 URL: http://llvm.org/viewvc/llvm-project?rev=278300&view=rev Log: Implement LWG 2148: Make non-enum default hash specialization well-formed Summary: This patch removes the static_assert for non-enum types in the primary hash temp

Re: [PATCH] D23125: Modules: add command line option to support loading prebuilt modules on demand, without parsing any module map

2016-08-10 Thread Manman Ren via cfe-commits
manmanren updated this revision to Diff 67621. manmanren added a comment. Addressing Richard's comments. https://reviews.llvm.org/D23125 Files: docs/Modules.rst include/clang/Driver/Options.td include/clang/Lex/HeaderSearch.h include/clang/Lex/HeaderSearchOptions.h include/clang/Seria

[clang-tools-extra] r278295 - [Documentation] Improve consistency.

2016-08-10 Thread Eugene Zelenko via cfe-commits
Author: eugenezelenko Date: Wed Aug 10 17:00:49 2016 New Revision: 278295 URL: http://llvm.org/viewvc/llvm-project?rev=278295&view=rev Log: [Documentation] Improve consistency. Mention Clang-rename Emacs integration in release notes. Modified: clang-tools-extra/trunk/docs/ReleaseNotes.rst

Re: r278264 - Reapply [Sema] Add sizeof diagnostics for bzero

2016-08-10 Thread Bruno Cardoso Lopes via cfe-commits
Hi Joerg, > Given that bzero is pretty much non-standard at this point, I strongly > dislike the approach of checking only the function name. Thanks for the feedback. bzero it's widely used though, I think it's a usability win to perform a diagnostic here, despite bzero being non-standard. Is th

Re: [PATCH] D23375: Add kfree( ) to MallocChecker.cpp

2016-08-10 Thread Andrew Wells via cfe-commits
andrewmw94 updated this revision to Diff 67610. andrewmw94 added a comment. Change the test file kmalloc-linux.c to use kfree( ). Sorry if there was a way to put both patch files together; I wasn't able to find one. Repository: rL LLVM https://reviews.llvm.org/D23375 Files: kmalloc-linux

[PATCH] D23375: Add kfree( ) to MallocChecker.cpp

2016-08-10 Thread Andrew Wells via cfe-commits
andrewmw94 created this revision. andrewmw94 added reviewers: zaks.anna, dcoughlin, dergachev.a. andrewmw94 added a subscriber: cfe-commits. andrewmw94 set the repository for this revision to rL LLVM. andrewmw94 added a project: clang-c. Adds the kfree( ) function to MallocChecker.cpp Repository:

Re: [PATCH] D23361: [OpenCL] AMDGCN: Fix size_t type

2016-08-10 Thread Matt Arsenault via cfe-commits
arsenm added a subscriber: arsenm. Comment at: lib/Basic/Targets.cpp:2008-2010 @@ +2007,5 @@ + uint64_t getOpenCLMaxPointerWidth() const override { +if (GPU <= GK_CAYMAN) + return 32; +return 64; + } Should use ternary operator and check the triple

Re: [libcxx] r278282 - std:: quailfy the calls for cend/crend/cbegin/cend. Fixes bug 28927.

2016-08-10 Thread Hans Wennborg via cfe-commits
Should we merge this to 3.9? Looks like a straight-forward fix for something that was hit by real code. Thanks, Hans On Wed, Aug 10, 2016 at 1:04 PM, Marshall Clow via cfe-commits wrote: > Author: marshall > Date: Wed Aug 10 15:04:46 2016 > New Revision: 278282 > > URL: http://llvm.org/viewvc/ll

Re: [PATCH] D22910: Add support for CXXOperatorCallExpr in Expr::HasSideEffects

2016-08-10 Thread Richard Smith via cfe-commits
rsmith added a comment. If `IncludePossibleEffects` is false, the goal of `HasSideEffect` is to determine whether we think the user intended for the expression to have a side-effect. It seems reasonable to assume that any use of an assignment operator had that intent, so (since it seems like th

Re: [PATCH] D22782: Added 'inline' attribute to __init to inline the basic_string's constructor

2016-08-10 Thread Laxman Sole via cfe-commits
laxmansole updated this revision to Diff 67597. laxmansole added a comment. Added inline attribute to the forward/input iterator __init's. Thanks @EricWF for suggestion. https://reviews.llvm.org/D22782 Files: libcxx/include/string Index: libcxx/include/string ===

Re: [PATCH] D23353: [clang-tidy] Add check 'misc-use-after-move'

2016-08-10 Thread Eugene Zelenko via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tidy/misc/UseAfterMoveCheck.cpp:512 @@ +511,3 @@ +} +void UseAfterMoveFinder::getReinits( +const CFGBlock *Block, const ValueDecl *MovedVariable, Please insert empty line before. Repository: rL LLVM

Re: [PATCH] D23003: [ObjC Availability] Warn upon unguarded use of partially available declaration

2016-08-10 Thread Erik Pilkington via cfe-commits
erik.pilkington updated this revision to Diff 67582. erik.pilkington added a comment. This new patch rebases on top of r277887, and addresses Manman's comments. After looking through the AST nodes, I realized I neglected to emit a diagnostic for member expressions. I also noticed that function p

[libcxx] r278282 - std:: quailfy the calls for cend/crend/cbegin/cend. Fixes bug 28927.

2016-08-10 Thread Marshall Clow via cfe-commits
Author: marshall Date: Wed Aug 10 15:04:46 2016 New Revision: 278282 URL: http://llvm.org/viewvc/llvm-project?rev=278282&view=rev Log: std:: quailfy the calls for cend/crend/cbegin/cend. Fixes bug 28927. Added: libcxx/trunk/test/std/iterators/iterator.range/begin-end.fail.cpp Modified: li

Re: r278264 - Reapply [Sema] Add sizeof diagnostics for bzero

2016-08-10 Thread Joerg Sonnenberger via cfe-commits
On Wed, Aug 10, 2016 at 06:34:47PM -, Bruno Cardoso Lopes via cfe-commits wrote: > Author: bruno > Date: Wed Aug 10 13:34:47 2016 > New Revision: 278264 > > URL: http://llvm.org/viewvc/llvm-project?rev=278264&view=rev > Log: > Reapply [Sema] Add sizeof diagnostics for bzero Given that bzero

[clang-tools-extra] r278279 - [Documentation] Fix style and grammar mistake in Clang-tidy readability-else-after-return description spotted by Alexander Kornienko.

2016-08-10 Thread Eugene Zelenko via cfe-commits
Author: eugenezelenko Date: Wed Aug 10 14:49:38 2016 New Revision: 278279 URL: http://llvm.org/viewvc/llvm-project?rev=278279&view=rev Log: [Documentation] Fix style and grammar mistake in Clang-tidy readability-else-after-return description spotted by Alexander Kornienko. Modified: clang-t

Re: [PATCH] D23279: clang-reorder-fields

2016-08-10 Thread Alexander Shaposhnikov via cfe-commits
alexshap added a comment. > Well, multi-TU support is needed for many tools and it is far beyond one tool > implementation details if we want it to be nice. I want to >have multi-TU > support in the clang-refactor, but it is still in designing stage at the > moment. At first, one translation un

Re: r277787 - [Sema] Add sizeof diagnostics for bzero

2016-08-10 Thread Bruno Cardoso Lopes via cfe-commits
This typo was exactly the reason why, r278264. Thanks On Fri, Aug 5, 2016 at 10:09 AM, David Majnemer wrote: > > > On Thu, Aug 4, 2016 at 4:55 PM, Bruno Cardoso Lopes via cfe-commits > wrote: >> >> Author: bruno >> Date: Thu Aug 4 18:55:22 2016 >> New Revision: 277787 >> >> URL: http://llvm.org

r278264 - Reapply [Sema] Add sizeof diagnostics for bzero

2016-08-10 Thread Bruno Cardoso Lopes via cfe-commits
Author: bruno Date: Wed Aug 10 13:34:47 2016 New Revision: 278264 URL: http://llvm.org/viewvc/llvm-project?rev=278264&view=rev Log: Reapply [Sema] Add sizeof diagnostics for bzero Reapply r277787. For memset (and others) we can get diagnostics like: struct stat { int x; }; void foo(struct st

[clang-tools-extra] r278263 - [Documentation] Highlighting consistency and spelling mistake fix in Clang-tidy readability-else-after-return description.

2016-08-10 Thread Eugene Zelenko via cfe-commits
Author: eugenezelenko Date: Wed Aug 10 13:30:14 2016 New Revision: 278263 URL: http://llvm.org/viewvc/llvm-project?rev=278263&view=rev Log: [Documentation] Highlighting consistency and spelling mistake fix in Clang-tidy readability-else-after-return description. Modified: clang-tools-extra/

Re: [PATCH] D23279: clang-reorder-fields

2016-08-10 Thread Alexander Shaposhnikov via cfe-commits
alexshap added a comment. 0. the tool relies on the compilation database from day one (like the other clang tools using tooling::RefactoringTool) 1. regarding TUs:. A. just in case how it works: it uses the full name of record to find the definition, then it changes the definition, then it fin

Re: [PATCH] D23343: [clang-tidy] modernize-make-{smart_ptr} private ctor bugfix

2016-08-10 Thread Aaron Ballman via cfe-commits
aaron.ballman added inline comments. Comment at: test/clang-tidy/modernize-make-shared.cpp:109 @@ +108,3 @@ + void create() { +auto ptr = std::shared_ptr(new Private(42)); + } Prazek wrote: > aaron.ballman wrote: > > Add comments explaining why make_shared i

[clang-tools-extra] r278262 - [Release Notes] Consistency in Clang-tidy entries' style.

2016-08-10 Thread Eugene Zelenko via cfe-commits
Author: eugenezelenko Date: Wed Aug 10 13:15:51 2016 New Revision: 278262 URL: http://llvm.org/viewvc/llvm-project?rev=278262&view=rev Log: [Release Notes] Consistency in Clang-tidy entries' style. Modified: clang-tools-extra/trunk/docs/ReleaseNotes.rst Modified: clang-tools-extra/trunk/docs

Re: [PATCH] D23343: [clang-tidy] modernize-make-{smart_ptr} private ctor bugfix

2016-08-10 Thread Eugene Zelenko via cfe-commits
Eugene.Zelenko added a subscriber: Eugene.Zelenko. Comment at: docs/ReleaseNotes.rst:78 @@ -77,1 +77,3 @@ +- Bugfix for `modernize-make-unique + `_ I think will be better to have //Fixed

Re: [PATCH] D23125: Modules: add command line option to support loading prebuilt modules on demand, without parsing any module map

2016-08-10 Thread Manman Ren via cfe-commits
manmanren added a comment. In https://reviews.llvm.org/D23125#510632, @rsmith wrote: > This doesn't seem like quite the right user interface for this feature. The > module cache is volatile, and it's not really reasonable for people to assume > they know what is and isn't within it. Instead, it

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-10 Thread Kirill Bobyrev via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278257: [clang-tidy] enhance readability-else-after-return (authored by omtcyfz). Changed prior to commit: https://reviews.llvm.org/D23265?vs=67513&id=67561#toc Repository: rL LLVM https://reviews.l

[clang-tools-extra] r278257 - [clang-tidy] enhance readability-else-after-return

2016-08-10 Thread Kirill Bobyrev via cfe-commits
Author: omtcyfz Date: Wed Aug 10 13:05:47 2016 New Revision: 278257 URL: http://llvm.org/viewvc/llvm-project?rev=278257&view=rev Log: [clang-tidy] enhance readability-else-after-return `readability-else-after-return` only warns about `return` calls, but LLVM Coding Standars stat that `throw`, `co

Re: [PATCH] D17990: [clang-tidy] minor improvements in modernise-deprecated-headers check

2016-08-10 Thread Kirill Bobyrev via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278254: [clang-tidy] minor improvements in modernise-deprecated-headers check (authored by omtcyfz). Changed prior to commit: https://reviews.llvm.org/D17990?vs=67551&id=67560#toc Repository: rL LLVM

[clang-tools-extra] r278255 - [Documentation] Fix grammar mistakes in docs/clang-tidy/index.rst spotted by Alexander Kornienko.

2016-08-10 Thread Eugene Zelenko via cfe-commits
Author: eugenezelenko Date: Wed Aug 10 13:02:15 2016 New Revision: 278255 URL: http://llvm.org/viewvc/llvm-project?rev=278255&view=rev Log: [Documentation] Fix grammar mistakes in docs/clang-tidy/index.rst spotted by Alexander Kornienko. Modified: clang-tools-extra/trunk/docs/clang-tidy/inde

[clang-tools-extra] r278254 - [clang-tidy] minor improvements in modernise-deprecated-headers check

2016-08-10 Thread Kirill Bobyrev via cfe-commits
Author: omtcyfz Date: Wed Aug 10 13:01:45 2016 New Revision: 278254 URL: http://llvm.org/viewvc/llvm-project?rev=278254&view=rev Log: [clang-tidy] minor improvements in modernise-deprecated-headers check This patch introduces a minor list of changes as proposed by Richard Smith in the mailing lis

Re: [PATCH] D23353: [clang-tidy] Add check 'misc-use-after-move'

2016-08-10 Thread Eugene Zelenko via cfe-commits
Eugene.Zelenko added a subscriber: Eugene.Zelenko. Comment at: docs/ReleaseNotes.rst:75 @@ +74,3 @@ + + This check warns if an object is used after it has been moved, without an + intervening reinitialization. Please remove //This check// and capitalize //warns/

[PATCH] D23361: [OpenCL] AMDGCN: Fix size_t type

2016-08-10 Thread Yaxun Liu via cfe-commits
yaxunl created this revision. yaxunl added reviewers: nhaustov, Anastasia. yaxunl added subscribers: cfe-commits, tstellarAMD. Pointers of certain GPUs in AMDGCN target in private address space is 32 bit but pointers in other address spaces are 64 bit. size_t type should be defined as 64 bit for

Re: [PATCH] D23279: clang-reorder-fields

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyf0 added a subscriber: omtcyf0. omtcyf0 added a comment. In https://reviews.llvm.org/D23279#511439, @bcraig wrote: > I will agree that compilation databases are a (mostly) necessary, but not > sufficient part of the solution. The refactoring tool will need to be > careful about changing t

Re: [PATCH] D23279: clang-reorder-fields

2016-08-10 Thread Ben Craig via cfe-commits
bcraig added a comment. In https://reviews.llvm.org/D23279#511266, @omtcyfz wrote: > In https://reviews.llvm.org/D23279#511202, @bcraig wrote: > > > In https://reviews.llvm.org/D23279#511187, @omtcyfz wrote: > > > > > In https://reviews.llvm.org/D23279#510234, @alexshap wrote: > > > > > > > > I d

Re: [PATCH] D17990: [clang-tidy] minor improvements in modernise-deprecated-headers check

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyf0 added a comment. In https://reviews.llvm.org/D17990#511429, @alexfh wrote: > In https://reviews.llvm.org/D17990#511424, @omtcyf0 wrote: > > > Revert changes. > > > Thanks! If Aaron has no objections, good to go. Great! Thank you! https://reviews.llvm.org/D17990

[PATCH] trivial documentation fix regarding Obj-C ARC objc_arc_weak_reference_unavailable

2016-08-10 Thread Sean McBride via cfe-commits
Fixed incorrect docs that referred to: objc_arc_weak_unavailable when it should be: objc_arc_weak_reference_unavailable Cheers, Sean objc_arc_weak_unavailable-typo.patch Description: Binary data ___ cfe-commits mailing list cfe-commits@lists.llvm.or

Re: [PATCH] D17990: [clang-tidy] minor improvements in modernise-deprecated-headers check

2016-08-10 Thread Alexander Kornienko via cfe-commits
alexfh added a comment. In https://reviews.llvm.org/D17990#511424, @omtcyf0 wrote: > Revert changes. Thanks! If Aaron has no objections, good to go. https://reviews.llvm.org/D17990 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://li

Re: [PATCH] D17990: [clang-tidy] minor improvements in modernise-deprecated-headers check

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyf0 updated this revision to Diff 67551. omtcyf0 marked an inline comment as not done. omtcyf0 added a comment. Revert changes. https://reviews.llvm.org/D17990 Files: clang-tidy/modernize/DeprecatedHeadersCheck.cpp docs/clang-tidy/checks/modernize-deprecated-headers.rst test/clang-tid

Re: r278234 - [OpenCL] Change block descriptor address space to constant.

2016-08-10 Thread Hans Wennborg via cfe-commits
Merged together with r278235 in r278248. Thanks, Hans On Wed, Aug 10, 2016 at 10:25 AM, Anastasia Stulova via cfe-commits wrote: > Hi Hans, > > Is it still possible to merge this change in release 3.9 branch. This is just > a minor bug fix we have found with Clang Blocks and only affects OpenCL

Re: [PATCH] D17990: [clang-tidy] minor improvements in modernise-deprecated-headers check

2016-08-10 Thread Alexander Kornienko via cfe-commits
alexfh added inline comments. Comment at: clang-tidy/modernize/DeprecatedHeadersCheck.cpp:83 @@ +82,3 @@ + for (const auto &Key : DeleteHeaders) { +DeleteHeadersSet.insert(Key); + } No danger of dangling references here, since `StringMap` copies keys. See `

RE: r278234 - [OpenCL] Change block descriptor address space to constant.

2016-08-10 Thread Anastasia Stulova via cfe-commits
Hi Hans, Is it still possible to merge this change in release 3.9 branch. This is just a minor bug fix we have found with Clang Blocks and only affects OpenCL. PS, it goes together with a typo fix in the next commit r278235. Thanks in advance, Anastasia -Original Message- From: cfe-com

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-10 Thread Alexander Kornienko via cfe-commits
alexfh accepted this revision. alexfh added a comment. This revision is now accepted and ready to land. LG https://reviews.llvm.org/D23265 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com

Re: [PATCH] D23343: [clang-tidy] modernize-make-{smart_ptr} private ctor bugfix

2016-08-10 Thread Piotr Padlewski via cfe-commits
Prazek added inline comments. Comment at: test/clang-tidy/modernize-make-shared.cpp:109 @@ +108,3 @@ + void create() { +auto ptr = std::shared_ptr(new Private(42)); + } aaron.ballman wrote: > Add comments explaining why make_shared is not correct. Also, plea

Re: [PATCH] D23353: [clang-tidy] Add check 'misc-use-after-move'

2016-08-10 Thread Piotr Padlewski via cfe-commits
Prazek added a subscriber: Prazek. Prazek added a reviewer: Prazek. Prazek added a comment. I will review it later, but my first thoughts: 1. I think we should make some other group, because misc seems to be overloaded. I discussed it with Alex months ago - something like bugprone would be good

Re: [PATCH] D13126: New static analyzer checker for loss of sign/precision

2016-08-10 Thread Artem Dergachev via cfe-commits
NoQ added a comment. Wow, i've completely forgot about this one. Sorry about that... I think this checker is good to have in the current shape, and probably incrementally developed. It'd probably move out of alpha whenever it's tweaked to somehow make sure it finds enough real bugs among intent

r278238 - [analyzer] Fix a crash in CloneDetector when calling functions by pointers.

2016-08-10 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Aug 10 11:25:16 2016 New Revision: 278238 URL: http://llvm.org/viewvc/llvm-project?rev=278238&view=rev Log: [analyzer] Fix a crash in CloneDetector when calling functions by pointers. CallExpr may have a null direct callee when the callee function is not known in compi

Re: r278139 - [clang-cl] Make -gline-tables-only imply -gcodeview

2016-08-10 Thread Hans Wennborg via cfe-commits
Sure, r278240. On Wed, Aug 10, 2016 at 3:55 AM, Nico Weber wrote: > Since this flag is new in 3.9, should we merge this there? > > On Tue, Aug 9, 2016 at 1:23 PM, Reid Kleckner via cfe-commits > wrote: >> >> Author: rnk >> Date: Tue Aug 9 12:23:56 2016 >> New Revision: 278139 >> >> URL: http://

Re: [PATCH] D23320: [analyzer] Fixed crash in CloneDetector in function calls.

2016-08-10 Thread Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278238: [analyzer] Fix a crash in CloneDetector when calling functions by pointers. (authored by dergachev). Changed prior to commit: https://reviews.llvm.org/D23320?vs=67345&id=67537#toc Repository:

r278235 - [OpenCL] Fix typo in test that I accidentally introduced in my previous commit.

2016-08-10 Thread Joey Gouly via cfe-commits
Author: joey Date: Wed Aug 10 11:04:14 2016 New Revision: 278235 URL: http://llvm.org/viewvc/llvm-project?rev=278235&view=rev Log: [OpenCL] Fix typo in test that I accidentally introduced in my previous commit. Modified: cfe/trunk/test/CodeGenOpenCL/cl20-device-side-enqueue.cl Modified: cfe/

Re: [PATCH] D23346: [OpenCL] Change block descriptor address space to constant

2016-08-10 Thread Joey Gouly via cfe-commits
joey closed this revision. joey added a comment. Committed r278234. 2 years since my last commit! Repository: rL LLVM https://reviews.llvm.org/D23346 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/l

Re: Modify MallocChecker.cpp to recognize kfree( )

2016-08-10 Thread Artem Dergachev via cfe-commits
Hey, that's a useful patch, i'd like it to be included! There is odd indentation in some places, but in general it looks correct. The usual thing to do nowadays is to put patches on review on Phabricator, would you like to do that? (http://llvm.org/docs/Phabricator.html, http://llvm.org/docs/

Re: [PATCH] D23353: [clang-tidy] Add check 'misc-use-after-move'

2016-08-10 Thread Matt Kulukundis via cfe-commits
fowles added a subscriber: fowles. Comment at: test/clang-tidy/misc-use-after-move.cpp:158 @@ +157,3 @@ +std::move(ptr); +ptr.get(); + } would this warn on: std::unique_ptr ptr; std::move(ptr); ptr->Foo(); I would like it to since that is a likely segfa

r278234 - [OpenCL] Change block descriptor address space to constant.

2016-08-10 Thread Joey Gouly via cfe-commits
Author: joey Date: Wed Aug 10 10:57:02 2016 New Revision: 278234 URL: http://llvm.org/viewvc/llvm-project?rev=278234&view=rev Log: [OpenCL] Change block descriptor address space to constant. The block descriptor is a GlobalVariable in the LLVM IR, so it shouldn't be in the private address space.

Re: [PATCH] D23279: clang-reorder-fields

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyfz added a comment. In https://reviews.llvm.org/D23279#511202, @bcraig wrote: > In https://reviews.llvm.org/D23279#511187, @omtcyfz wrote: > > > In https://reviews.llvm.org/D23279#510234, @alexshap wrote: > > > > > > I do think that an automated tool will do a better job of changing > > > >

Re: [PATCH] D23353: [clang-tidy] Add check 'misc-use-after-move'

2016-08-10 Thread Martin Böhme via cfe-commits
mboehme added a comment. Apologies for the size of this patch. alexfh@ said he was willing to review it as-is -- however, I'm happy to resubmit in smaller pieces if necessary. https://reviews.llvm.org/D23353 ___ cfe-commits mailing list cfe-commits

[PATCH] D23353: [clang-tidy] Add check 'misc-use-after-move'

2016-08-10 Thread Martin Böhme via cfe-commits
mboehme created this revision. mboehme added a reviewer: alexfh. mboehme added a subscriber: cfe-commits. The check warns if an object is used after it has been moved, without an intervening reinitialization. See user-facing documentation for details. https://reviews.llvm.org/D23353 Files: cl

Re: [PATCH] D23279: clang-reorder-fields

2016-08-10 Thread Ben Craig via cfe-commits
bcraig added a comment. In https://reviews.llvm.org/D23279#511187, @omtcyfz wrote: > In https://reviews.llvm.org/D23279#510234, @alexshap wrote: > > > > I do think that an automated tool will do a better job of changing field > > > orderings in a non-breaking way than most people would, mostly d

Re: [PATCH] D23331: Implement LWG 2148: Make non-enum default hash specialization well-formed

2016-08-10 Thread Marshall Clow via cfe-commits
mclow.lists added a comment. This looks good to me. However, we don't //usually// change libc++ for issue resolutions that have not yet adopted. We wait until they've "official". https://reviews.llvm.org/D23331 ___ cfe-commits mailing list cfe-comm

Re: [PATCH] D23279: clang-reorder-fields

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyfz added a comment. In https://reviews.llvm.org/D23279#510234, @alexshap wrote: > > I do think that an automated tool will do a better job of changing field > > orderings in a non-breaking way than most people would, mostly due to > > initializer lists. > > > yeah, that was the original mo

Re: [PATCH] D22220: [clang-tidy] Add check 'misc-move-forwarding-reference'

2016-08-10 Thread Aaron Ballman via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/misc/MoveForwardingReferenceCheck.cpp:64 @@ +63,3 @@ +void MoveForwardingReferenceCheck::registerMatchers(MatchFinder *Finder) { + if (!getLangOpts().CPlusPlus11) +return; sbenza wrote: > I'm guessin

Re: [PATCH] D17990: [clang-tidy] minor improvements in modernise-deprecated-headers check

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyf0 marked an inline comment as done. omtcyf0 added a comment. https://reviews.llvm.org/D17990 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D17990: [clang-tidy] minor improvements in modernise-deprecated-headers check

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyf0 updated this revision to Diff 67519. omtcyf0 added a comment. Address comments. https://reviews.llvm.org/D17990 Files: clang-tidy/modernize/DeprecatedHeadersCheck.cpp docs/clang-tidy/checks/modernize-deprecated-headers.rst test/clang-tidy/modernize-deprecated-headers-cxx03.cpp t

Re: [PATCH] D22220: [clang-tidy] Add check 'misc-move-forwarding-reference'

2016-08-10 Thread Samuel Benzaquen via cfe-commits
sbenza added inline comments. Comment at: clang-tidy/misc/MoveForwardingReferenceCheck.cpp:64 @@ +63,3 @@ +void MoveForwardingReferenceCheck::registerMatchers(MatchFinder *Finder) { + if (!getLangOpts().CPlusPlus11) +return; I'm guessing this is checking Lang

Re: [PATCH] D17990: [clang-tidy] minor improvements in modernise-deprecated-headers check

2016-08-10 Thread Aaron Ballman via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/modernize/DeprecatedHeadersCheck.cpp:79 @@ -69,3 +78,3 @@ for (const auto &KeyValue : std::vector>( {{"fenv.h", "cfenv"}, omtcyfz wrote: > aaron.ballman wrote: > > This will d

Re: [PATCH] D17990: [clang-tidy] minor improvements in modernise-deprecated-headers check

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyfz added a subscriber: omtcyfz. Comment at: clang-tidy/modernize/DeprecatedHeadersCheck.cpp:79 @@ -69,3 +78,3 @@ for (const auto &KeyValue : std::vector>( {{"fenv.h", "cfenv"}, aaron.ballman wrote: > This will definitely fail in M

Re: [clang-tools-extra] r278221 - [clang-rename] merge tests when possible

2016-08-10 Thread Aaron Ballman via cfe-commits
On Wed, Aug 10, 2016 at 9:54 AM, Aaron Ballman wrote: > On Wed, Aug 10, 2016 at 9:28 AM, Kirill Bobyrev via cfe-commits > wrote: >> Author: omtcyfz >> Date: Wed Aug 10 08:28:30 2016 >> New Revision: 278221 >> >> URL: http://llvm.org/viewvc/llvm-project?rev=278221&view=rev >> Log: >> [clang-rename

Re: [PATCH] D23204: Visit lambda capture inits from RecursiveASTVisitor::TraverseLambdaCapture().

2016-08-10 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: include/clang/AST/RecursiveASTVisitor.h:892 @@ -891,1 +891,3 @@ + else +TRY_TO(TraverseStmt(LE->capture_init_begin()[C - LE->capture_begin()])); return true; I'd rather pass in the offset than doing math with what'

Re: [clang-tools-extra] r278221 - [clang-rename] merge tests when possible

2016-08-10 Thread Aaron Ballman via cfe-commits
On Wed, Aug 10, 2016 at 9:28 AM, Kirill Bobyrev via cfe-commits wrote: > Author: omtcyfz > Date: Wed Aug 10 08:28:30 2016 > New Revision: 278221 > > URL: http://llvm.org/viewvc/llvm-project?rev=278221&view=rev > Log: > [clang-rename] merge tests when possible > > The only difference between some t

[clang-tools-extra] r278225 - [clang-rename] fix test introduced in r278221

2016-08-10 Thread Kirill Bobyrev via cfe-commits
Author: omtcyfz Date: Wed Aug 10 08:46:36 2016 New Revision: 278225 URL: http://llvm.org/viewvc/llvm-project?rev=278225&view=rev Log: [clang-rename] fix test introduced in r278221 Modified: clang-tools-extra/trunk/test/clang-rename/ComplicatedClassType.cpp Modified: clang-tools-extra/trunk/t

Re: [PATCH] D22220: [clang-tidy] Add check 'misc-move-forwarding-reference'

2016-08-10 Thread Martin Böhme via cfe-commits
mboehme added a comment. Now that https://reviews.llvm.org/D23004 is submitted, can you take another look? https://reviews.llvm.org/D0 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-co

[clang-tools-extra] r278223 - [clang-rename] remove bunch of deprecated tests

2016-08-10 Thread Kirill Bobyrev via cfe-commits
Author: omtcyfz Date: Wed Aug 10 08:32:37 2016 New Revision: 278223 URL: http://llvm.org/viewvc/llvm-project?rev=278223&view=rev Log: [clang-rename] remove bunch of deprecated tests Removed: clang-tools-extra/trunk/test/clang-rename/ClassAsTemplateArgumentFindByClass.cpp clang-tools-ext

Re: [PATCH] D23158: [clang-rename] merge tests when possible

2016-08-10 Thread Kirill Bobyrev via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278221: [clang-rename] merge tests when possible (authored by omtcyfz). Changed prior to commit: https://reviews.llvm.org/D23158?vs=67516&id=67517#toc Repository: rL LLVM https://reviews.llvm.org/D2

[clang-tools-extra] r278221 - [clang-rename] merge tests when possible

2016-08-10 Thread Kirill Bobyrev via cfe-commits
Author: omtcyfz Date: Wed Aug 10 08:28:30 2016 New Revision: 278221 URL: http://llvm.org/viewvc/llvm-project?rev=278221&view=rev Log: [clang-rename] merge tests when possible The only difference between some tests is -offset passed to clang-rename. It makes sense to merge them into a single file

Re: [PATCH] D23158: [clang-rename] merge tests when possible

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyfz updated this revision to Diff 67516. omtcyfz added a comment. Delete two more files. https://reviews.llvm.org/D23158 Files: test/clang-rename/ClassAsTemplateArgument.cpp test/clang-rename/ClassAsTemplateArgumentFindByClass.cpp test/clang-rename/ClassAsTemplateArgumentFindByTemplat

Re: [PATCH] D23158: [clang-rename] merge tests when possible

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyfz updated this revision to Diff 67515. omtcyfz added a comment. Update files not previouysly added with `git add`. https://reviews.llvm.org/D23158 Files: test/clang-rename/ClassAsTemplateArgument.cpp test/clang-rename/ClassAsTemplateArgumentFindByClass.cpp test/clang-rename/ClassAsT

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyfz updated this revision to Diff 67513. omtcyfz added a comment. Remove braces around single statement in `for` and `if` as Alex proposed. https://reviews.llvm.org/D23265 Files: clang-tidy/readability/ElseAfterReturnCheck.cpp docs/clang-tidy/checks/readability-else-after-return.rst t

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-10 Thread Aaron Ballman via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. LGTM! https://reviews.llvm.org/D23265 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-10 Thread Kirill Bobyrev via cfe-commits
omtcyfz updated this revision to Diff 67512. omtcyfz marked 4 inline comments as done. omtcyfz added a comment. Address comments. https://reviews.llvm.org/D23265 Files: clang-tidy/readability/ElseAfterReturnCheck.cpp docs/clang-tidy/checks/readability-else-after-return.rst test/clang-tidy

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-10 Thread Aaron Ballman via cfe-commits
aaron.ballman added inline comments. Comment at: docs/clang-tidy/checks/readability-else-after-return.rst:14 @@ -8,2 +13,3 @@ -http://llvm.org/docs/CodingStandards.html#don-t-use-else-after-a-return +``` c++ +void foo(int Value) { alexfh wrote: > aaron.ballman w

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-10 Thread Alexander Kornienko via cfe-commits
alexfh added inline comments. Comment at: clang-tidy/readability/ElseAfterReturnCheck.cpp:40 @@ +39,3 @@ + for (const auto *BindingName : {"return", "continue", "break", "throw"}) { +if (Result.Nodes.getNodeAs(BindingName)) { + ControlFlowInterruptor = BindingName; -

Re: [PATCH] D17990: [clang-tidy] minor improvements in modernise-deprecated-headers check

2016-08-10 Thread Aaron Ballman via cfe-commits
aaron.ballman added a subscriber: aaron.ballman. aaron.ballman requested changes to this revision. aaron.ballman added a reviewer: aaron.ballman. This revision now requires changes to proceed. Comment at: clang-tidy/modernize/DeprecatedHeadersCheck.cpp:79 @@ -69,3 +78,3 @@ fo

  1   2   >