Re: [PATCH] D13318: Add a utility function to add target information to a command line

2015-10-06 Thread Manuel Klimek via cfe-commits
klimek closed this revision. klimek added a comment. Submitted as r249391. http://reviews.llvm.org/D13318 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r249391 - Adds a way for tools to deduce the target config from a compiler name.

2015-10-06 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Tue Oct 6 05:45:03 2015 New Revision: 249391 URL: http://llvm.org/viewvc/llvm-project?rev=249391&view=rev Log: Adds a way for tools to deduce the target config from a compiler name. Adds `addTargetAndModeForProgramName`, a utility function that will add appropriate `-target

Re: [PATCH] D13469: Create interfaces and tests for the overlapping replacements fix in clang-tidy.

2015-10-06 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: unittests/clang-tidy/OverlappingReplacementsTest.cpp:133 @@ +132,3 @@ + +TEST(OverlappingReplacementsTest, TestingChecksWorkAsExpected) { + const char Code[] = I'd split it up and give the tests better names. TestingCheck

Re: [PATCH] D13469: Create interfaces and tests for the overlapping replacements fix in clang-tidy.

2015-10-06 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. LG Comment at: unittests/clang-tidy/OverlappingReplacementsTest.cpp:21 @@ +20,3 @@ +const char BoundIf[] = "if"; + +class UseCharCheck : public ClangTidyCheck { --

Re: [PATCH] D13368: [clang-tidy] add check cppcoreguidelines-pro-type-static-cast-downcast

2015-10-06 Thread Manuel Klimek via cfe-commits
klimek added a subscriber: klimek. klimek added a comment. In http://reviews.llvm.org/D13368#260669, @aaron.ballman wrote: > This wasn't a comment on the rule so much as a comment on the diagnostic not > being very helpful.In this case, you're telling the user to not do something, > but it is u

Re: [PATCH] D13368: [clang-tidy] add check cppcoreguidelines-pro-type-static-cast-downcast

2015-10-06 Thread Manuel Klimek via cfe-commits
On Tue, Oct 6, 2015 at 4:12 PM Aaron Ballman wrote: > aaron.ballman added a comment. > > In http://reviews.llvm.org/D13368#260672, @klimek wrote: > > > In http://reviews.llvm.org/D13368#260669, @aaron.ballman wrote: > > > > > This wasn't a comment on the rule so much as a comment on the > diagnos

Re: [PATCH] D13368: [clang-tidy] add check cppcoreguidelines-pro-type-static-cast-downcast

2015-10-06 Thread Manuel Klimek via cfe-commits
On Tue, Oct 6, 2015 at 4:18 PM Aaron Ballman wrote: > On Tue, Oct 6, 2015 at 10:15 AM, Manuel Klimek wrote: > > On Tue, Oct 6, 2015 at 4:12 PM Aaron Ballman > > wrote: > >> > >> aaron.ballman added a comment. > >> > >> In http://reviews.llvm.org/D13368#260672, @klimek wrote: > >> > >> > In http

Re: [PATCH] D13523: ASTMatchers: Keep AllCallbacks in a set instead of a vector

2015-10-07 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. That makes a lot of sense. LG http://reviews.llvm.org/D13523 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bi

[clang-tools-extra] r244586 - Add an IncludeInserter to clang-tidy.

2015-08-11 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Tue Aug 11 06:37:48 2015 New Revision: 244586 URL: http://llvm.org/viewvc/llvm-project?rev=244586&view=rev Log: Add an IncludeInserter to clang-tidy. Will be used to allow checks to insert includes at the right position. Added: clang-tools-extra/trunk/clang-tidy/IncludeI

Re: r244413 - [modules] When building a dependency file, include module maps parsed in the

2015-08-11 Thread Manuel Klimek via cfe-commits
I believe this breaks -fno-module-file-deps. On Sun, Aug 9, 2015 at 6:47 AM Richard Smith via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: rsmith > Date: Sat Aug 8 23:46:57 2015 > New Revision: 244413 > > URL: http://llvm.org/viewvc/llvm-project?rev=244413&view=rev > Log: > [module

[clang-tools-extra] r244587 - Fix shadowing of type with variable.

2015-08-11 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Tue Aug 11 07:02:28 2015 New Revision: 244587 URL: http://llvm.org/viewvc/llvm-project?rev=244587&view=rev Log: Fix shadowing of type with variable. Modified: clang-tools-extra/trunk/clang-tidy/IncludeInserter.cpp Modified: clang-tools-extra/trunk/clang-tidy/IncludeInser

[clang-tools-extra] r244596 - Default initialize from explicitly constructed object.

2015-08-11 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Tue Aug 11 07:13:15 2015 New Revision: 244596 URL: http://llvm.org/viewvc/llvm-project?rev=244596&view=rev Log: Default initialize from explicitly constructed object. Modified: clang-tools-extra/trunk/unittests/clang-tidy/ClangTidyTest.h Modified: clang-tools-extra/trunk

[clang-tools-extra] r244597 - Do not use inheriting constructors.

2015-08-11 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Tue Aug 11 07:59:22 2015 New Revision: 244597 URL: http://llvm.org/viewvc/llvm-project?rev=244597&view=rev Log: Do not use inheriting constructors. Modified: clang-tools-extra/trunk/unittests/clang-tidy/IncludeInserterTest.cpp Modified: clang-tools-extra/trunk/unittests/

[clang-tools-extra] r244598 - Fix strict dependency uncovered by windows bot.

2015-08-11 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Tue Aug 11 08:11:29 2015 New Revision: 244598 URL: http://llvm.org/viewvc/llvm-project?rev=244598&view=rev Log: Fix strict dependency uncovered by windows bot. Modified: clang-tools-extra/trunk/clang-tidy/CMakeLists.txt Modified: clang-tools-extra/trunk/clang-tidy/CMakeL

[clang-tools-extra] r244602 - 1. Disable tests that currently cannot work on windows due to missing path canonicalization in the file manager.

2015-08-11 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Tue Aug 11 09:21:26 2015 New Revision: 244602 URL: http://llvm.org/viewvc/llvm-project?rev=244602&view=rev Log: 1. Disable tests that currently cannot work on windows due to missing path canonicalization in the file manager. 2. Add better output when a clang-tidy unit test fa

[PATCH] D11944: Nativize filename in FileManager::getFile().

2015-08-11 Thread Manuel Klimek via cfe-commits
klimek created this revision. klimek added reviewers: rsmith, chapuni. klimek added a subscriber: cfe-commits. For virtual files to work correctly on Windows, we need to canonicalize the paths before looking into the caches. This is basically a request for comments - if we want to go this route,

Re: [clang-tools-extra] r244596 - Default initialize from explicitly constructed object.

2015-08-11 Thread Manuel Klimek via cfe-commits
nitializer lists like this... > On Aug 11, 2015 5:13 AM, "Manuel Klimek via cfe-commits" < > cfe-commits@lists.llvm.org> wrote: > >> Author: klimek >> Date: Tue Aug 11 07:13:15 2015 >> New Revision: 244596 >> >> URL: http://llvm.org/viewvc/ll

Re: [PATCH] D11944: Nativize filename in FileManager::getFile().

2015-08-11 Thread Manuel Klimek via cfe-commits
klimek added a comment. The case sensitivity stuff is related, but a much larger problem - while the native paths are system dependent, the case sensitivity is file system dependent - I can have case insensitive file systems on any OS. http://reviews.llvm.org/D11944

Re: [clang-tools-extra] r244597 - Do not use inheriting constructors.

2015-08-11 Thread Manuel Klimek via cfe-commits
MSVC 2013 On Tue, Aug 11, 2015 at 5:02 PM David Blaikie wrote: > Unsupported (which compiler(s)?) or just not preferred? > On Aug 11, 2015 6:00 AM, "Manuel Klimek via cfe-commits" < > cfe-commits@lists.llvm.org> wrote: > >> Author: klimek >> Date:

Re: r244413 - [modules] When building a dependency file, include module maps parsed in the

2015-08-11 Thread Manuel Klimek via cfe-commits
Ah, so we need a flag -fno-module-map-file-deps, I assume... On Tue, Aug 11, 2015 at 8:12 PM Richard Smith wrote: > On Tue, Aug 11, 2015 at 4:57 AM, Manuel Klimek wrote: > >> I believe this breaks -fno-module-file-deps. >> > > I don't think so; this affects which module map files end up in the

Re: r244413 - [modules] When building a dependency file, include module maps parsed in the

2015-08-11 Thread Manuel Klimek via cfe-commits
On Tue, Aug 11, 2015 at 8:38 PM Richard Smith wrote: > Those files were parsed as part of building the output, and are legitimate > dependencies of the compilation process; why do you want to suppress them > from the .d file? (I think adding a whole bunch of -fno-*-deps flags is > going in the wr

Re: r232721 - Add option to switch off putting header modules into the dependency file.

2015-08-11 Thread Manuel Klimek via cfe-commits
Back in the day I'm pretty sure you agreed with the general concept :) http://reviews.llvm.org/D8378 I remember that we had problems with absolute paths ending up in the .d file (which should not happen if none of the paths provided are absolute), but I don't remember why we went for not writing th

[clang-tools-extra] r244722 - Reinstantiate better diagnostic, this time with a fatal error so we don't add a dependency onto gtest from the header.

2015-08-12 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Wed Aug 12 02:57:16 2015 New Revision: 244722 URL: http://llvm.org/viewvc/llvm-project?rev=244722&view=rev Log: Reinstantiate better diagnostic, this time with a fatal error so we don't add a dependency onto gtest from the header. Modified: clang-tools-extra/trunk/unitte

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-12 Thread Manuel Klimek via cfe-commits
klimek added a subscriber: klimek. klimek added a comment. Minor nits; I'll want Alex to also take a look, as I had reviewed the original code before, so he probably has more insightful things to say :) Comment at: clang-tidy/modernize/ModernizeTidyModule.cpp:1 @@ +1,2 @@ +//==

Re: [PATCH] D10365: Add cmd to compilation database file format

2015-08-12 Thread Manuel Klimek via cfe-commits
klimek added a comment. Ok, we're very close now :) Thanks for taking the time to work through this! Comment at: ../llvm/tools/clang/lib/Tooling/JSONCompilationDatabase.cpp:299 @@ +298,3 @@ +if (CommandFound) { + ErrorMessage = "Multiple command and arguments fo

Re: [PATCH] D10365: Add cmd to compilation database file format

2015-08-13 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: ../llvm/tools/clang/lib/Tooling/JSONCompilationDatabase.cpp:295 @@ +294,3 @@ +if (CommandFound) { + ErrorMessage = "Multiple command and arguments found"; + return false; You're probably right. I

Re: [PATCH] D11944: Nativize filename in FileManager::getFile().

2015-08-13 Thread Manuel Klimek via cfe-commits
klimek added a comment. In http://reviews.llvm.org/D11944#222975, @rsmith wrote: > In principle, normalizing slashes on Windows makes sense here. But we > shouldn't use `llvm::sys::path::native`, because it's just too broken. Ok, so if I understand you correctly it would make sense to create a

[clang-tools-extra] r244876 - Fix formatting.

2015-08-13 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Thu Aug 13 04:09:28 2015 New Revision: 244876 URL: http://llvm.org/viewvc/llvm-project?rev=244876&view=rev Log: Fix formatting. Modified: clang-tools-extra/trunk/unittests/clang-tidy/ClangTidyTest.h Modified: clang-tools-extra/trunk/unittests/clang-tidy/ClangTidyTest.h U

Re: [PATCH] D11944: Nativize filename in FileManager::getFile().

2015-08-13 Thread Manuel Klimek via cfe-commits
klimek added a comment. In http://reviews.llvm.org/D11944#223597, @chapuni wrote: > I wish, in clang/llvm, internal path separator would be slash. > It'd be better to use backslash where it'd be really required, for example > interface to cmd.exe or MS toolchain. > > For me, native-ization is n

Re: [PATCH] D10365: Add cmd to compilation database file format

2015-08-13 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a reviewer: klimek. klimek added a comment. This revision is now accepted and ready to land. LG with a happy path test. Comment at: ../llvm/tools/clang/unittests/Tooling/CompilationDatabaseTest.cpp:45 @@ -41,1 +44,3 @@ + expectFailure

Re: [PATCH] D12017: Fix IncludeInserter/IncludeSorter bug.

2015-08-13 Thread Manuel Klimek via cfe-commits
klimek added a comment. Please add a regression test. http://reviews.llvm.org/D12017 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D10365: Add cmd to compilation database file format

2015-08-13 Thread Manuel Klimek via cfe-commits
klimek added a comment. Cool, looks good! If you need me to land it let me know. http://reviews.llvm.org/D10365 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D10365: Add cmd to compilation database file format

2015-08-14 Thread Manuel Klimek via cfe-commits
klimek added a comment. Unfortunately I can't get the patch to apply cleanly due to different line endings. http://reviews.llvm.org/D10365 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-co

Re: [PATCH] D10365: Add cmd to compilation database file format

2015-08-14 Thread Manuel Klimek via cfe-commits
klimek added a comment. Solved the line ending problem. http://reviews.llvm.org/D10365 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r245036 - Add structed way to express command line options in the compilation database.

2015-08-14 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Fri Aug 14 04:55:36 2015 New Revision: 245036 URL: http://llvm.org/viewvc/llvm-project?rev=245036&view=rev Log: Add structed way to express command line options in the compilation database. Currently, arguments are passed via the string attribute 'command', assuming a shell-e

Re: [PATCH] D10365: Add cmd to compilation database file format

2015-08-14 Thread Manuel Klimek via cfe-commits
klimek closed this revision. klimek added a comment. Submitted as r245036. Thanks! http://reviews.llvm.org/D10365 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D12017: Fix IncludeInserter/IncludeSorter bug.

2015-08-14 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/IncludeSorter.cpp:144 @@ -138,3 +143,3 @@ IncludeKinds NonEmptyKind = IK_InvalidInclude; - for (int i = IncludeKind - 1; i >= 0; --i) { + for (int i = IK_InvalidInclude - 1; i >= 0; --i) { if (!IncludeBucket[i].empty()

r245040 - Fix AST matcher documentation.

2015-08-14 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Fri Aug 14 06:47:51 2015 New Revision: 245040 URL: http://llvm.org/viewvc/llvm-project?rev=245040&view=rev Log: Fix AST matcher documentation. Fix a bug in the matcher docs where callExpr(on(...)) was in the examples, but didn't work (on() only works for memberCallExpr). Fix

Re: [PATCH] D12471: Correct documentation for numSelectorArgs matcher

2015-08-30 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: include/clang/ASTMatchers/ASTMatchers.h:2140-2153 @@ -2139,16 +2139,16 @@ /// \brief Matches when the selector has the specified number of arguments /// -/// matcher = objCMessageExpr(numSelectorArgs(1)); +/// matcher = objCMessageEx

Re: [PATCH] D11976: [libclang] Return deduced type for auto type, not the one written in the source.

2015-08-30 Thread Manuel Klimek via cfe-commits
klimek added a subscriber: klimek. klimek accepted this revision. klimek added a reviewer: klimek. klimek added a comment. This revision is now accepted and ready to land. As this doesn't break any old tests, and fixes a significant number of issues, LG. Do you need me to submit? http://reviews

Re: [PATCH] fix parentheses location in a CXXConstructExpr

2015-08-31 Thread Manuel Klimek via cfe-commits
On Sat, Aug 29, 2015 at 12:23 PM Olivier Goffart via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Hi, > > Please review the attached patch. > > In Sema::BuildCXXFunctionalCastExpr, if the class has a destructor, the > Op.SrcExpr might be a CXXBindTemporaryExpr which we need to unwrap. > > In

Re: [PATCH] D12446: [PATCH] Enable clang-tidy misc-static-assert for C11

2015-08-31 Thread Manuel Klimek via cfe-commits
klimek added a subscriber: klimek. Comment at: test/clang-tidy/misc-static-assert-c99.c:2 @@ +1,3 @@ +// RUN: %python %S/check_clang_tidy.py %s misc-static-assert %t -- -std=c99 + +void abort() {} aaron.ballman wrote: > I am not certain how to accomplish this with

Re: [PATCH] D12446: [PATCH] Enable clang-tidy misc-static-assert for C11

2015-08-31 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: test/clang-tidy/misc-static-assert-c99.c:1 @@ +1,2 @@ +// RUN: %python %S/check_clang_tidy.py %s misc-static-assert %t -- -std=c99 + alexfh wrote: > Instead of duplicating the test, you could add a second run line in the o

Re: [PATCH] D12407: [clang-format-vs] Add an option to reformat source code when file is saved to disk

2015-08-31 Thread Manuel Klimek via cfe-commits
I'll need to try to build / install it. I'll take a couple of days, I'm currently swamped. Hope that's ok. On Mon, Aug 31, 2015 at 6:25 PM Hans Wennborg wrote: > hans added a comment. > > I also don't know anything about how this plugin works, I just build it :) > I'm hoping Manuel can take a lo

Re: [PATCH] D12407: [clang-format-vs] Add an option to reformat source code when file is saved to disk

2015-08-31 Thread Manuel Klimek via cfe-commits
klimek added a subscriber: klimek. klimek added a comment. I'll need to try to build / install it. I'll take a couple of days, I'm currently swamped. Hope that's ok. http://reviews.llvm.org/D12407 ___ cfe-commits mailing list cfe-commits@lists.llvm.

Re: [PATCH] D12530: Fix several corner cases for loop-convert check.

2015-09-01 Thread Manuel Klimek via cfe-commits
klimek added a comment. Nice! Comment at: clang-tidy/modernize/LoopConvertCheck.cpp:378 @@ +377,3 @@ + for (const auto &U : Usages) { +if (!U.E->isRValue()) + return false; (not necessarily in this CL) please rename E to Expression or similar; I'm fine

Re: [PATCH] D12530: Fix several corner cases for loop-convert check.

2015-09-01 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: test/clang-tidy/modernize-loop-convert-basic.cpp:448 @@ +447,3 @@ +ret = it; + } +} angelgarcia wrote: > klimek wrote: > > This test seems to be missing the it.insert(0) case that was removed from > > the "unsupporte

Re: [PATCH] D12530: Fix several corner cases for loop-convert check.

2015-09-01 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. Learned that I need to learn to read, because the deleted comment was just duplicated. Looks good, great first step towards making this significantly more useful :) http://reviews.llvm.org/D1

Re: [PATCH] D12555: Fix loop-convert crash.

2015-09-02 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a reviewer: klimek. klimek added a comment. This revision is now accepted and ready to land. lg http://reviews.llvm.org/D12555 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/

Re: clang-tools-extra code owners

2015-09-02 Thread Manuel Klimek via cfe-commits
I think that basically encodes what the current state is, and we should have kept that file in a better shape. +Edwin in case he still has a stake in clang-modernize, or knows who might have. On Wed, Sep 2, 2015 at 6:38 PM Aaron Ballman wrote: > I happened to notice that CODE_OWNERS.TXT for clan

Re: clang-tools-extra code owners

2015-09-02 Thread Manuel Klimek via cfe-commits
Thanks for the cleanup! On Wed, Sep 2, 2015 at 10:02 PM Aaron Ballman wrote: > I've updated the code owners list in r246698. Thanks! > > ~Aaron > > On Wed, Sep 2, 2015 at 3:33 PM, Peter Collingbourne > wrote: > > SGTM. > > > > Peter > > > > On Wed, Sep 02, 2015 at 12:38:41PM -0400, Aaron Ballma

libtooling and ast matchers owners

2015-09-03 Thread Manuel Klimek via cfe-commits
After Aaron updated the clang-tools-extra owners, I looked at the clang owners and noticed that I'm not in there for libtooling and ast matchers. Doug suggested 3 years back that I should be in there, but apparently I forgot to update it. Anybody raising objections to me putting myself in for libto

Re: [PATCH] D12597: Two more fixes to loop convert.

2015-09-03 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. lg http://reviews.llvm.org/D12597 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

Re: [PATCH] D12471: Correct documentation for numSelectorArgs matcher

2015-09-03 Thread Manuel Klimek via cfe-commits
klimek added a reviewer: dfsuther. klimek added a comment. +Dean, as I really don't know Obj-C (sorry for the delay in reply, was on vacation) http://reviews.llvm.org/D12471 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.

Re: [PATCH] D12489: [clang-format] Fixed missing space between Obj-C for/in and a typecast

2015-09-03 Thread Manuel Klimek via cfe-commits
klimek added a comment. In the future, please add cfe-commits as subscriber on the initial post, otherwise the initial email will not go to the mailing list. Thx! http://reviews.llvm.org/D12489 ___ cfe-commits mailing list cfe-commits@lists.llvm.or

Re: [PATCH] D12489: [clang-format] Fixed missing space between Obj-C for/in and a typecast

2015-09-03 Thread Manuel Klimek via cfe-commits
klimek added a comment. Oh, and you'll want to add tests :) unittests/Format/FormatTest.cpp http://reviews.llvm.org/D12489 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] fix parentheses location in a CXXConstructExpr

2015-09-03 Thread Manuel Klimek via cfe-commits
On Tue, Sep 1, 2015 at 12:31 AM Olivier Goffart wrote: > On Monday 31. August 2015 08:07:58 Manuel Klimek wrote: > > On Sat, Aug 29, 2015 at 12:23 PM Olivier Goffart via cfe-commits < > > > > cfe-commits@lists.llvm.org> wrote: > > > Hi, > > > > > > Please review the attached patch. > > > > > > In

r246778 - [libclang] Return deduced type for auto type, not the one written in the source.

2015-09-03 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Thu Sep 3 11:11:10 2015 New Revision: 246778 URL: http://llvm.org/viewvc/llvm-project?rev=246778&view=rev Log: [libclang] Return deduced type for auto type, not the one written in the source. It used to work, but was accidentally broken by r179769. The issue with decayed typ

Re: [PATCH] D11976: [libclang] Return deduced type for auto type, not the one written in the source.

2015-09-03 Thread Manuel Klimek via cfe-commits
klimek closed this revision. klimek added a comment. Submitted as r246778. http://reviews.llvm.org/D11976 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D11797: [LIbClang] Report the named type for ElaboratedType

2015-09-03 Thread Manuel Klimek via cfe-commits
klimek added a subscriber: klimek. klimek added a comment. Is this still ready for submission or do you want to change something (not clear after your last comment :) http://reviews.llvm.org/D11797 ___ cfe-commits mailing list cfe-commits@lists.llv

Re: [PATCH] D12631: Avoid repeated replacements on loop-convert check.

2015-09-04 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/modernize/LoopConvertUtils.cpp:465 @@ +464,3 @@ + SourceLocation Begin = U.Range.getBegin(); + while (Begin.isMacroID()) +Begin = Context->getSourceManager().getExpansionLoc(Begin); There should be no need

Re: [PATCH] D12631: Avoid repeated replacements on loop-convert check.

2015-09-04 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/modernize/LoopConvertUtils.cpp:463-470 @@ -462,1 +462,10 @@ +void ForLoopIndexUseVisitor::addUsage(const Usage &U) { + SourceLocation Begin = U.Range.getBegin(); + if (Begin.isMacroID()) +Begin = Context->getSourceManage

Re: [PATCH] D12631: Avoid repeated replacements on loop-convert check.

2015-09-05 Thread Manuel Klimek via cfe-commits
klimek added a comment. Note that I think we should add a regression test that will work with the spelling loc but not with the expansion loc. Something like: #define A \ \ A http://reviews.llvm.org/D12631 ___ cfe-commits mailing list cfe-c

Re: [PATCH] D12666: [LibClang] Fix clang_getCursorAvailability

2015-09-07 Thread Manuel Klimek via cfe-commits
klimek added a subscriber: klimek. klimek accepted this revision. klimek added a reviewer: klimek. klimek added a comment. This revision is now accepted and ready to land. Wow, that goes a long while back into: http://reviews.llvm.org/rL111858 where the current case was handled somewhere else, and

Re: [PATCH] D12675: Avoid using rvalue references with trivially copyable types.

2015-09-07 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/modernize/LoopConvertCheck.cpp:556-557 @@ -555,1 +555,4 @@ DerefByValue = true; +// We can assume that we have at least one Usage, because +// usagesAreConst() returned false. +QualType Type = Us

Re: [PATCH] D11797: [LIbClang] Report the named type for ElaboratedType

2015-09-07 Thread Manuel Klimek via cfe-commits
klimek added a comment. Ok, so looking over the new patch: It seems like attributed types and decayed types are somewhat different from elaborated types: - decayed types don't lose any information if we look through to the original type - attributed types lose only information that can be consi

Re: [PATCH] D12675: Avoid using rvalue references with trivially copyable types.

2015-09-07 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/modernize/LoopConvertCheck.cpp:658-663 @@ -646,7 +657,8 @@ + IsTriviallyCopyable = BeginPointeeType.isTriviallyCopyableType(*Context); } else { // Check for qualified types to avoid conversions from non-const to

Re: [PATCH] D12675: Avoid using rvalue references with trivially copyable types.

2015-09-07 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/modernize/LoopConvertCheck.cpp:555-564 @@ +554,12 @@ +Descriptor.DerefByValue = true; +// Try to find the type of the elements on the container from the +// usages. We can assume that we have at least one

Re: [PATCH] D12675: Avoid using rvalue references with trivially copyable types.

2015-09-07 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/modernize/LoopConvertCheck.cpp:659-664 @@ -646,7 +658,8 @@ + BeginPointeeType.isTriviallyCopyableType(*Context); } else { // Check for qualified types to avoid conversions from non-const to const // i

Re: [PATCH] D12675: Avoid using rvalue references with trivially copyable types.

2015-09-08 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. LG http://reviews.llvm.org/D12675 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [clang-tools-extra] r249399 - Add a new module for the C++ Core Guidelines, and the first checker for those guidelines: cppcoreguidelines-pro-type-reinterpret-cast.

2015-10-07 Thread Manuel Klimek via cfe-commits
On Wed, Oct 7, 2015 at 7:34 PM Aaron Ballman via cfe-commits < cfe-commits@lists.llvm.org> wrote: > On Wed, Oct 7, 2015 at 12:05 PM, Joerg Sonnenberger via cfe-commits > wrote: > > On Tue, Oct 06, 2015 at 01:31:01PM -, Aaron Ballman via cfe-commits > wrote: > >> Log: > >> Add a new module for

Re: [PATCH] D13474: [VFS] Port tooling to use the in-memory file system.

2015-10-09 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. lg http://reviews.llvm.org/D13474 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

Re: r249831 - [VFS] Wire up driver VFS through tooling.

2015-10-09 Thread Manuel Klimek via cfe-commits
On Fri, Oct 9, 2015 at 3:05 PM Benjamin Kramer via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: d0k > Date: Fri Oct 9 08:03:25 2015 > New Revision: 249831 > > URL: http://llvm.org/viewvc/llvm-project?rev=249831&view=rev > Log: > [VFS] Wire up driver VFS through tooling. > > Sadly I

Re: [PATCH] D13639: Add decayedType and hasDecayedType AST matchers

2015-10-11 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. lg http://reviews.llvm.org/D13639 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

Re: [PATCH] D13639: Add decayedType and hasDecayedType AST matchers

2015-10-11 Thread Manuel Klimek via cfe-commits
klimek added a comment. Oh, please also run the docs update script cd docs/tools python ./dump_ast_matchers.py http://reviews.llvm.org/D13639 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo

Re: [PATCH] D13549: Added new options to ClangFormat VSIX package.

2015-10-12 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: lib/Driver/Tools.cpp:2356 @@ -2355,3 +2355,3 @@ CmdArgs.push_back( -Args.MakeArgString("-dwarf-version=" + llvm::itostr(DwarfVersion))); +Args.MakeArgString("-dwarf-version=" + Twine(DwarfVersion))); } ---

Re: [PATCH] D13549: Added new options to ClangFormat VSIX package.

2015-10-12 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: tools/clang-format/ClangFormat.cpp:227 @@ -213,1 +226,3 @@ + llvm::outs() << """; + break; default: curdeius wrote: > klimek wrote: > > For XML, we should only need "<" and "&". Everything else is just impor

Re: [PATCH] D13549: Added new options to ClangFormat VSIX package.

2015-10-12 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: tools/clang-format-vs/ClangFormat/ClangFormatPackage.cs:186 @@ -145,1 +185,3 @@ +if (!string.IsNullOrEmpty(assumeFilename)) + process.StartInfo.Arguments += " -assume-filename \"" + assumeFilename + "\"";

Re: [PATCH] D13549: Added new options to ClangFormat VSIX package.

2015-10-12 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: tools/clang-format-vs/ClangFormat/ClangFormatPackage.cs:186 @@ -145,1 +185,3 @@ +if (!string.IsNullOrEmpty(assumeFilename)) + process.StartInfo.Arguments += " -assume-filename \"" + assumeFilename + "\"";

Re: [PATCH] D13549: Added new options to ClangFormat VSIX package.

2015-10-12 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: tools/clang-format-vs/ClangFormat/ClangFormatPackage.cs:186 @@ -145,1 +185,3 @@ +if (!string.IsNullOrEmpty(assumeFilename)) + process.StartInfo.Arguments += " -assume-filename \"" + assumeFilename + "\"";

Re: r250036 - [VFS] Don't try to be heroic with '.' in paths.

2015-10-12 Thread Manuel Klimek via cfe-commits
I believe we need a more principled approach here :) 1. The first thing we need is to actually produce nice errors when we hit an addFile() with the same path (normalized or non-normalized) I'd propose the following approach: we compare the buffers; if the buffer contents are equal, we declare suc

Re: [PATCH] D13658: [VFS] Let the user decide if they want path normalization.

2015-10-12 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: include/clang/Basic/VirtualFileSystem.h:276 @@ -275,2 +275,3 @@ std::string WorkingDirectory; + bool UseNormalizedPaths; I'd use an in class initializer. Comment at: include/clang/Basic/VirtualFileS

Re: [PATCH] D13658: [VFS] Let the user decide if they want path normalization.

2015-10-12 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. lg Comment at: include/clang/Basic/VirtualFileSystem.h:282 @@ -280,2 +281,3 @@ /// Add a buffer to the VFS with a path. The VFS owns the buffer. - void addFile(const Twine

Re: [PATCH] D13640: [clang-tidy] Add new check cppcoreguidelines-pro-bounds-array-to-pointer-decay

2015-10-13 Thread Manuel Klimek via cfe-commits
klimek added a subscriber: klimek. Comment at: clang-tidy/cppcoreguidelines/ProBoundsArrayToPointerDecayCheck.cpp:40 @@ +39,3 @@ + + diag(MatchedCast->getExprLoc(), "do not (implicitly) convert an array to a pointer"); +} Can't we provide a fixit? http://revi

Re: [PATCH] D13549: Added new options to ClangFormat VSIX package.

2015-10-13 Thread Manuel Klimek via cfe-commits
klimek added reviewers: aaron.ballman, rnk. klimek added a comment. +aaron, as token Windows Wizard +rnk, as I was told you might know people who are in a good position to review MS specific stuff (perhaps engineers from MS might be able to help here? :) http://reviews.llvm.org/D13549 _

Re: [PATCH] D13590: Support every kind of initialization.

2015-10-13 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. lg Comment at: clang-tidy/modernize/MakeUniqueCheck.cpp:125-128 @@ +124,6 @@ + // Direct initialization with initialization list. + // \code + // struct S { S

Re: [PATCH] D10833: Retrieve BinaryOperator::getOpcode and BinaryOperator::getOpcodeStr via libclang and its python interface

2015-10-13 Thread Manuel Klimek via cfe-commits
klimek added a reviewer: milianw. klimek added a comment. +milian - can you take a look at this patch (or do you know somebody who might be in a good position to review) http://reviews.llvm.org/D10833 ___ cfe-commits mailing list cfe-commits@lists.

Re: [PATCH] D13516: Fix overlapping replacements in clang-tidy.

2015-10-13 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/ClangTidyDiagnosticConsumer.cpp:418-419 @@ +417,4 @@ +unsigned Pos; +int Type; +int ErrorId; + }; These need to be documented. Comment at: clang-tidy/ClangTidyDiagnosticConsumer.cp

Re: [PATCH] D13388: Add support for querying the visibility of a cursor

2015-10-13 Thread Manuel Klimek via cfe-commits
klimek added a subscriber: klimek. klimek added a reviewer: milianw. klimek added a comment. This LG, looping in Milian for a second opinion / to find more reviewers :) http://reviews.llvm.org/D13388 ___ cfe-commits mailing list cfe-commits@lists.ll

Re: [PATCH] D12407: [clang-format-vs] Add an option to reformat source code when file is saved to disk

2015-10-13 Thread Manuel Klimek via cfe-commits
klimek added reviewers: aaron.ballman, rnk. klimek added a comment. +aaron for windows specific knowledge +rnk to see whether we can get a reviewer with more MS VS experience (perhaps somebody from MS :) My main concern is that this adds a lot of things that I have no idea whether they are need

Re: [PATCH] D13640: [clang-tidy] Add new check cppcoreguidelines-pro-bounds-array-to-pointer-decay

2015-10-13 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/cppcoreguidelines/ProBoundsArrayToPointerDecayCheck.cpp:40 @@ +39,3 @@ + + diag(MatchedCast->getExprLoc(), "do not (implicitly) convert an array to a pointer"); +} aaron.ballman wrote: > klimek wrote: > > Can

Re: [PATCH] D13504: Prevent modernize-use-auto from emitting a warning when 'auto' was already being used.

2015-10-14 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. lg http://reviews.llvm.org/D13504 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

Re: [PATCH] D13516: Fix overlapping replacements in clang-tidy.

2015-10-14 Thread Manuel Klimek via cfe-commits
klimek added a comment. Comment at: clang-tidy/ClangTidyDiagnosticConsumer.cpp:438-440 @@ +437,5 @@ + int Count[2] = {0, 0}; + // Sit[1][0] will tell if there exists any range that is covered by the + // first set but not by the second one, Sit[1][1] will tell if there is a

Re: [PATCH] D13516: Fix overlapping replacements in clang-tidy.

2015-10-14 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/ClangTidyDiagnosticConsumer.cpp:438-440 @@ +437,5 @@ + int Count[2] = {0, 0}; + // Sit[1][0] will tell if there exists any range that is covered by the + // first set but not by the second one, Sit[1][1] will tell if there is

Re: [PATCH] D13720: Use __SIZE_TYPE__ to fix buildbot failures.

2015-10-14 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. lg http://reviews.llvm.org/D13720 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

Re: [PATCH] D13516: Fix overlapping replacements in clang-tidy.

2015-10-14 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/ClangTidyDiagnosticConsumer.cpp:444-448 @@ +443,7 @@ + }; + // Keep track of the different coverage situations that have been spotted + // during the process: Coverage[Covered][Empty] will tell if there exists any + // range

Re: [PATCH] D13516: Fix overlapping replacements in clang-tidy.

2015-10-14 Thread Manuel Klimek via cfe-commits
klimek added inline comments. Comment at: clang-tidy/ClangTidyDiagnosticConsumer.cpp:495-496 @@ +494,4 @@ + std::vector Apply(NumErrors, true); + for (int I = 0; I < NumErrors; ++I) { +for (int J = I + 1; J < NumErrors; ++J) { + OverlappingKind Kind = I

Re: [PATCH] D13516: Fix overlapping replacements in clang-tidy.

2015-10-14 Thread Manuel Klimek via cfe-commits
klimek added a comment. LG in general now, looks to me like we have very few tests though. My favorite strategy to make sure I have enough tests is to comment out code (or do mutations) as long as the tests still pass. Then write tests that fail with the mutation, then undo the mutation. =

Re: [PATCH] D13549: Added new options to ClangFormat VSIX package.

2015-10-15 Thread Manuel Klimek via cfe-commits
klimek added a comment. We're waiting for Reid to find somebody who is good at reviewing this in detail. Sorry it takes a while, so far we don't have enough trusted Windows experts in the community :( http://reviews.llvm.org/D13549 ___ cfe-commits

Re: [PATCH] D13516: Fix overlapping replacements in clang-tidy.

2015-10-16 Thread Manuel Klimek via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. lg Comment at: clang-tidy/ClangTidyDiagnosticConsumer.cpp:489 @@ +488,3 @@ + std::vector Apply(Errors.size(), true); + int Count = 0; + for (const auto &Event : Events) { -

<    1   2   3   4   5   6   >