[PATCH] D60953: [clangd] Respect clang-tidy suppression comments

2019-05-13 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Thanks, this looks nice. Main ideas here: - it'd be nice to get rid of the subclassing in the diag consumer if we can - i'm not sure the logic around LastErrorWasIgnored is completely accurate - can we add a unit test for this? The existing clang-tidy diag tests are in

r360559 - [c++20] P1064R0: Allow virtual function calls in constant expression

2019-05-13 Thread Richard Smith via cfe-commits
Author: rsmith Date: Mon May 13 00:42:10 2019 New Revision: 360559 URL: http://llvm.org/viewvc/llvm-project?rev=360559=rev Log: [c++20] P1064R0: Allow virtual function calls in constant expression evaluation. Modified: cfe/trunk/include/clang/AST/DeclCXX.h

[PATCH] D61845: [builtin] Fixed definitions of builtins that rely on the int/long long type is 32/64 bits

2019-05-13 Thread Karl-Johan Karlsson via Phabricator via cfe-commits
Ka-Ka created this revision. Ka-Ka added reviewers: dylanmckay, spatel, rsmith. Herald added a subscriber: kristina. Herald added a project: clang. The definition of the builtins __builtin_bswap32, __builtin_bitreverse32, __builtin_rotateleft32 and __builtin_rotateright32 rely on that the int

[PATCH] D40381: Parse concept definition

2019-05-13 Thread Saar Raz via Phabricator via cfe-commits
saar.raz added a comment. @rsmith? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D40381/new/ https://reviews.llvm.org/D40381 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

r360563 - PR41845: Detect and reject mismatched inner/outer pack expansion sizes

2019-05-13 Thread Richard Smith via cfe-commits
Author: rsmith Date: Mon May 13 01:31:14 2019 New Revision: 360563 URL: http://llvm.org/viewvc/llvm-project?rev=360563=rev Log: PR41845: Detect and reject mismatched inner/outer pack expansion sizes in fold expressions rather than crashing. Modified: cfe/trunk/include/clang/AST/ExprCXX.h

[PATCH] D61749: [clang-tidy] initial version of readability-static-const-method

2019-05-13 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre marked 2 inline comments as done. mgehre added inline comments. Comment at: clang-tools-extra/test/clang-tidy/readability-static-const-method.cpp:209 +void KeepLambdas() { + auto F = +[]() { return 0; }; + auto F2 = []() { return 0; }; JonasToth wrote:

r360560 - PR41854: Don't assert when constant-evaluating a member function call on an invalid designator.

2019-05-13 Thread Richard Smith via cfe-commits
Author: rsmith Date: Mon May 13 00:51:29 2019 New Revision: 360560 URL: http://llvm.org/viewvc/llvm-project?rev=360560=rev Log: PR41854: Don't assert when constant-evaluating a member function call on an invalid designator. Modified: cfe/trunk/lib/AST/ExprConstant.cpp

[PATCH] D58033: Add option for emitting dbg info for call site parameters

2019-05-13 Thread Djordje Todorovic via Phabricator via cfe-commits
djtodoro updated this revision to Diff 199213. djtodoro edited the summary of this revision. djtodoro added a comment. -Add an input in test/CodeGenCXX/dbg-info-all-calls-described.cpp -Rename the option CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58033/new/

[PATCH] D58035: [clang/DIVar] Emit flag for params that have unchanged values

2019-05-13 Thread Djordje Todorovic via Phabricator via cfe-commits
djtodoro updated this revision to Diff 199214. djtodoro added a comment. -Rebase CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58035/new/ https://reviews.llvm.org/D58035 Files: lib/CodeGen/CGDebugInfo.cpp lib/CodeGen/CGDebugInfo.h Index: lib/CodeGen/CGDebugInfo.h

[PATCH] D59744: Fix i386 ABI "__m64" type bug

2019-05-13 Thread Wei Xiao via Phabricator via cfe-commits
wxiao3 updated this revision to Diff 199233. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59744/new/ https://reviews.llvm.org/D59744 Files: lib/CodeGen/TargetInfo.cpp test/CodeGen/vector.c test/CodeGen/x86_32-arguments-darwin.c test/CodeGen/x86_32-arguments-linux.c

[PATCH] D60748: Fix i386 struct and union parameter alignment

2019-05-13 Thread Wei Xiao via Phabricator via cfe-commits
wxiao3 updated this revision to Diff 199232. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60748/new/ https://reviews.llvm.org/D60748 Files: lib/CodeGen/TargetInfo.cpp test/CodeGen/x86_32-align-linux.c test/CodeGen/x86_32-arguments-linux.c Index:

[PATCH] D60748: Fix i386 struct and union parameter alignment

2019-05-13 Thread Wei Xiao via Phabricator via cfe-commits
wxiao3 updated this revision to Diff 199231. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60748/new/ https://reviews.llvm.org/D60748 Files: lib/CodeGen/TargetInfo.cpp test/CodeGen/vector.c test/CodeGen/x86_32-arguments-darwin.c test/CodeGen/x86_32-arguments-linux.c

[PATCH] D61786: [ASTImporter] Separate unittest files

2019-05-13 Thread Gabor Marton via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC360572: [ASTImporter] Separate unittest files (authored by martong, committed by ). Changed prior to commit: https://reviews.llvm.org/D61786?vs=199225=199226#toc Repository: rC Clang CHANGES SINCE

r360572 - [ASTImporter] Separate unittest files

2019-05-13 Thread Gabor Marton via cfe-commits
Author: martong Date: Mon May 13 03:06:25 2019 New Revision: 360572 URL: http://llvm.org/viewvc/llvm-project?rev=360572=rev Log: [ASTImporter] Separate unittest files Summary: Move generic redecl chain tests and visibility tests into their own separate test files. Reviewers: a_sidorin,

[PATCH] D61851: [clang-tidy] New option for misc-throw-by-value-catch-by-reference

2019-05-13 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware created this revision. baloghadamsoftware added reviewers: alexfh, aaron.ballman, lebedev.ri. baloghadamsoftware added a project: clang-tools-extra. Herald added subscribers: gamesh411, Szelethus, rnkovacs. Herald added a project: clang. Catching trivial objects by value is not

[PATCH] D61841: [clangd] Respect WarningsAsErrors configuration for clang-tidy

2019-05-13 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/ClangdUnit.cpp:346 + std::string CheckName = CTContext->getCheckName(Info.getID()); + if (!CheckName.empty() && WarningAsErrorFilter->contains(CheckName)) { +Level =

[PATCH] D61497: [clangd] Introduce a structured hover response

2019-05-13 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet updated this revision to Diff 199257. kadircet marked 2 inline comments as done. kadircet added a comment. - Address comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61497/new/ https://reviews.llvm.org/D61497 Files:

[PATCH] D61497: [clangd] Introduce a structured hover response

2019-05-13 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet marked 16 inline comments as done. kadircet added a comment. Thanks for also taking a look at the implementation, it is not complete yet. I am rather waiting for a green light on struct itself, so that I can write tests. Comment at:

r360580 - Revert r360559 "[c++20] P1064R0: Allow virtual function calls in constant expression evaluation."

2019-05-13 Thread Hans Wennborg via cfe-commits
Author: hans Date: Mon May 13 06:19:09 2019 New Revision: 360580 URL: http://llvm.org/viewvc/llvm-project?rev=360580=rev Log: Revert r360559 "[c++20] P1064R0: Allow virtual function calls in constant expression evaluation." This caused Chromium builds to hit the new "can't handle virtual calls

[PATCH] D61790: [C++20] add consteval specifier

2019-05-13 Thread Gabor Marton via Phabricator via cfe-commits
martong resigned from this revision. martong added a comment. Herald added a subscriber: rnkovacs. ASTImporter.cpp looks good to me. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61790/new/ https://reviews.llvm.org/D61790

[PATCH] D61786: [ASTImporter] Separate unittest files

2019-05-13 Thread Gabor Marton via Phabricator via cfe-commits
martong marked 8 inline comments as done. martong added a comment. Thanks for the review Alexei! Comment at: clang/unittests/AST/ASTImporterGenericRedeclTest.cpp:20 + +// FIXME put these structs and the tests rely on them into their own separate +// test file!

[PATCH] D61786: [ASTImporter] Separate unittest files

2019-05-13 Thread Gabor Marton via Phabricator via cfe-commits
martong updated this revision to Diff 199225. martong marked 2 inline comments as done. martong added a comment. - Address Alexei's comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61786/new/ https://reviews.llvm.org/D61786 Files:

[PATCH] D60748: Fix i386 struct and union parameter alignment

2019-05-13 Thread Wei Xiao via Phabricator via cfe-commits
wxiao3 added a comment. Any other comments? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60748/new/ https://reviews.llvm.org/D60748 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D60748: Fix i386 struct and union parameter alignment

2019-05-13 Thread Dimitry Andric via Phabricator via cfe-commits
dim added a comment. In fact, it is probably better to turn the OS check around, e.g. *only* increase the alignment for Linux, and nowhere else. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60748/new/ https://reviews.llvm.org/D60748 ___

[PATCH] D61849: Do not list enabled checks when -quiet is given to clang-tidy.

2019-05-13 Thread Sven Panne via Phabricator via cfe-commits
svenpanne created this revision. svenpanne added a reviewer: alexfh. Herald added a project: clang. Herald added a subscriber: cfe-commits. When clang-tidy is given the -quiet flag, do not output the potentially hundreds of enabled check names at the beginning. Repository: rCTE Clang Tools

[PATCH] D59885: [Lex] Allow to consume tokens while preprocessing

2019-05-13 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov marked 2 inline comments as done. ilya-biryukov added a comment. I'll try to explore bringing the overhead down. The fact that `CachingLex` is happening at `LexLevel==1` might help, thanks for pointing that out! Comment at: clang/lib/Lex/PPCaching.cpp:64

[PATCH] D61850: Removed superfluous and slightly annoying newlines in run-clang-tidy's output.

2019-05-13 Thread Sven Panne via Phabricator via cfe-commits
svenpanne created this revision. svenpanne added a reviewer: alexfh. Herald added a project: clang. Herald added a subscriber: cfe-commits. The output of clang-tidy itself already has enough newlines, so the resulting output is more in line with the usual compiler output. Repository: rCTE

[PATCH] D59744: Fix i386 ABI "__m64" type bug

2019-05-13 Thread Wei Xiao via Phabricator via cfe-commits
wxiao3 marked an inline comment as done. wxiao3 added inline comments. Comment at: lib/CodeGen/TargetInfo.cpp:919 /// IsX86_MMXType - Return true if this is an MMX type. bool IsX86_MMXType(llvm::Type *IRType) { - // Return true if the type is an MMX type <2 x i32>, <4 x i16>,

[PATCH] D60748: Fix i386 struct and union parameter alignment

2019-05-13 Thread Dimitry Andric via Phabricator via cfe-commits
dim added subscribers: emaste, dim. dim added a comment. Please also exclude FreeBSD from these changes, since we care a lot about backwards compatibility, and specifically about alignment requirements. (We have run into many issues in our ports collection where upstream assumes everything is

Re: r360559 - [c++20] P1064R0: Allow virtual function calls in constant expression

2019-05-13 Thread Hans Wennborg via cfe-commits
This caused asserts in Chromium, so I've reverted in r360580. There's a repro at https://bugs.chromium.org/p/chromium/issues/detail?id=962458#c1, and I'm working on a reduced version. From: Richard Smith via cfe-commits Date: Mon, May 13, 2019 at 9:39 AM To: > Author: rsmith > Date: Mon May 13

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-13 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D61765#1499957 , @jdoerfert wrote: > Two small changes and then it is fine with me. @tra ? LGTM in general. I would still like to confirm that the changes work with libc++. Repository: rC Clang CHANGES SINCE LAST ACTION

[PATCH] D61851: [clang-tidy] New option for misc-throw-by-value-catch-by-reference

2019-05-13 Thread Torbjörn Klatt via Phabricator via cfe-commits
torbjoernk added inline comments. Comment at: docs/clang-tidy/checks/misc-throw-by-value-catch-by-reference.rst:35-46 +.. option:: WarnOnLargeObject + + Also warns for any large trivial object caught by value. Catching a large + object by value is not dangerous but affects

[PATCH] D61850: Removed superfluous and slightly annoying newlines in run-clang-tidy's output.

2019-05-13 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. I agree with the direction, please ensure that e.g. clang-analyzer-* output looks proper as well and `-quiet` does, too. Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61850/new/ https://reviews.llvm.org/D61850

[PATCH] D61749: [clang-tidy] initial version of readability-static-const-method

2019-05-13 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: clang-tools-extra/test/clang-tidy/readability-static-const-method.cpp:209 +void KeepLambdas() { + auto F = +[]() { return 0; }; + auto F2 = []() { return 0; }; mgehre wrote: > JonasToth wrote: > > Does it pass

[PATCH] D61849: Do not list enabled checks when -quiet is given to run-clang-tidy.

2019-05-13 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth accepted this revision. JonasToth added a comment. This revision is now accepted and ready to land. LGTM Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61849/new/ https://reviews.llvm.org/D61849

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-13 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 199304. gtbercea added a comment. - Exclude clock functions. Reverse inclusion order. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61765/new/ https://reviews.llvm.org/D61765 Files: lib/Driver/ToolChains/Clang.cpp

[PATCH] D61858: Make `__is_base_of` more friendly with unions

2019-05-13 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. Yeah, this seems to match the library wording. (I think it's short-sighted and over-fitting -- this is baking into the library specification that the language happens to not allow unions to have base classes today -- but this isn't the

[PATCH] D59885: [Lex] Allow to consume tokens while preprocessing

2019-05-13 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. Thinking about this some more: distinguishing between "macro expansion" and other cases seems like a proxy for "this token came from inside the preprocessor / lexer" versus "this token was provided by the user", which is also exactly what `IsNewToken` is supposed to

[PATCH] D24892: [clang-tidy] Add option "LiteralInitializers" to cppcoreguidelines-pro-type-member-init

2019-05-13 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre added a comment. Do I wait for @alexfh to turn his red into a green, too? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D24892/new/ https://reviews.llvm.org/D24892 ___ cfe-commits mailing list

r360622 - Introduce the ability to dump the AST to JSON.

2019-05-13 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Mon May 13 14:39:55 2019 New Revision: 360622 URL: http://llvm.org/viewvc/llvm-project?rev=360622=rev Log: Introduce the ability to dump the AST to JSON. This adds the -ast-dump=json cc1 flag (in addition to -ast-dump=default, which is the default if no dump format is

[PATCH] D24892: [clang-tidy] Add option "LiteralInitializers" to cppcoreguidelines-pro-type-member-init

2019-05-13 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre updated this revision to Diff 199330. mgehre added a comment. Fix wrong merge of ReleaseNotes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D24892/new/ https://reviews.llvm.org/D24892 Files:

[PATCH] D61874: [clang-tidy] Fix invalid fixit for readability-static-accessed-through-instance (bug 40544)

2019-05-13 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre created this revision. mgehre added reviewers: aaron.ballman, alexfh, xazax.hun. mgehre added projects: clang, clang-tools-extra. Herald added a subscriber: rnkovacs. Fixed https://bugs.llvm.org/show_bug.cgi?id=40544 Before, we would generate a fixit like `(anonymous

[PATCH] D61865: [clangd] improve help message for limit-results

2019-05-13 Thread Brennan Vincent via Phabricator via cfe-commits
umanwizard created this revision. umanwizard added a reviewer: clang-tools-extra. Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. Make it clear that the default is 100. Repository: rCTE Clang Tools Extra

r360614 - Make more friendly with unions. Reviewed as https://reviews.llvm.org/D61858

2019-05-13 Thread Marshall Clow via cfe-commits
Author: marshall Date: Mon May 13 12:29:23 2019 New Revision: 360614 URL: http://llvm.org/viewvc/llvm-project?rev=360614=rev Log: Make more friendly with unions. Reviewed as https://reviews.llvm.org/D61858 Modified: cfe/trunk/lib/Sema/SemaExprCXX.cpp

[PATCH] D59465: [analyzer] Add a test plugin for checker option handling

2019-05-13 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. I don't see any problems with adding more tests. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59465/new/ https://reviews.llvm.org/D59465 ___ cfe-commits mailing list

[PATCH] D61827: [clang-tidy] modernize-loop-convert: impl const cast iter

2019-05-13 Thread Don Hinton via Phabricator via cfe-commits
hintonda accepted this revision. hintonda added a comment. This revision is now accepted and ready to land. Awesome, thanks... LGTM, but you may want to give @alexfh or @aaron.ballman a day to comment before you commit. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61827/new/

[PATCH] D61634: [clang/llvm] Allow efficient implementation of libc's memory functions in C/C++

2019-05-13 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. My main blocker is that I want to make sure we're moving in the right direction: towards LLVM IR with clear semantics, towards straightforward rules for writing freestanding C code, and towards solutions which behave appropriately for all targets. There's clearly a

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-13 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. In D61765#1500446 , @tra wrote: > In D61765#1500309 , @gtbercea wrote: > > > As soon as libc++ the limits header included in > > > > __clang_cuda_cmath.h:15 > > ``` is not found: > >

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-13 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. In D61765#1500446 , @tra wrote: > In D61765#1500309 , @gtbercea wrote: > > > As soon as libc++ the limits header included in > > > > __clang_cuda_cmath.h:15 > > ``` is not found: > >

[PATCH] D60162: [ThinLTO] Support TargetLibraryInfoImpl in the backend

2019-05-13 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson updated this revision to Diff 199320. tejohnson added a comment. Herald added subscribers: cfe-commits, hiraditya, eraman. Herald added a project: clang. Rework using module flags. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60162/new/

[PATCH] D60162: [ThinLTO] Support TargetLibraryInfoImpl in the backend

2019-05-13 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson added a comment. In D60162#1498392 , @tejohnson wrote: > In D60162#1498288 , @tejohnson wrote: > > > Working on this one again as it previously wasn't causing any issues but > > just now got exposed in

[PATCH] D60910: [WIP] Dumping the AST to JSON

2019-05-13 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman updated this revision to Diff 199316. aaron.ballman marked 2 inline comments as done. aaron.ballman added a comment. Switched to using the JSON streaming interface rather than a custom solution Updated the test cases for the new formatting CHANGES SINCE LAST ACTION

[PATCH] D60163: [ThinLTO] Handle -fno-builtin* options for distributed backends

2019-05-13 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson abandoned this revision. tejohnson added a comment. The parent revision now includes both clang and llvm side changes. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60163/new/ https://reviews.llvm.org/D60163

[PATCH] D60910: [WIP] Dumping the AST to JSON

2019-05-13 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D60910#1495673 , @rsmith wrote: > If you're happy with these two conditions, then I have no concerns with this > moving forward: > > - There is no implied stability for the content or format of the dump between > major

[PATCH] D61742: [Driver][Windows] Add dependent lib argument for profile instr generate

2019-05-13 Thread Reid Kleckner via Phabricator via cfe-commits
rnk accepted this revision. rnk added a comment. This revision is now accepted and ready to land. lgtm CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61742/new/ https://reviews.llvm.org/D61742 ___ cfe-commits mailing list

[PATCH] D61839: [analyzer][WIP] Hide developer-only checker/package options by default

2019-05-13 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D57858#1499414 , @Szelethus wrote: > Checker options are a different kind of animal entirely. I think we should > definitely let the user fine-tune some modeling checkers, for instance, > `unix.DynamicMemoryModeling:Optimistic`,

[PATCH] D57858: [analyzer] Add a new frontend flag to display all checker options

2019-05-13 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D57858#146 , @dkrupp wrote: > Some alpha checkers are considerably more mature than others and are quite > usable. In our experience, there are some users who are keen to run these > checkers on their code and report back any

[PATCH] D61850: Removed superfluous and slightly annoying newlines in run-clang-tidy's output.

2019-05-13 Thread Sven Panne via Phabricator via cfe-commits
svenpanne added a comment. In D61850#1500298 , @JonasToth wrote: > [...] please ensure that e.g. clang-analyzer-* output looks proper as well > and `-quiet` does, too. OK, are there any (unit) tests which I should run? If yes, how exactly? I have a

[PATCH] D61858: Make `__is_base_of` more friendly with unions

2019-05-13 Thread Louis Dionne via Phabricator via cfe-commits
ldionne accepted this revision. ldionne added a comment. This revision is now accepted and ready to land. I'm not a frontend expert, but this looks reasonable to me. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61858/new/ https://reviews.llvm.org/D61858

[PATCH] D61804: Support building shared and static libraries simultaneously

2019-05-13 Thread Wink Saville via Phabricator via cfe-commits
winksaville added a comment. > Arch Linux is in an unsupported state, and your patch isn't the way forward. OK, I'll filed a bug, https://bugs.archlinux.org/task/62624 > Let's rewind. > > Why do "some people like shared libraries"? There are usually two reasons > people cite for linking

[PATCH] D61707: [Preprocessor] Fix crash emitting note with framework location for "file not found" error.

2019-05-13 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. Ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61707/new/ https://reviews.llvm.org/D61707 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D24892: [clang-tidy] Add option "LiteralInitializers" to cppcoreguidelines-pro-type-member-init

2019-05-13 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D24892#1500371 , @mgehre wrote: > Do I wait for @alexfh to turn his red into a green, too? I think you covered all of the concerns he raised. If he doesn't give you an LG in the next 24 hours, I think you can go ahead

[PATCH] D61861: DeleteNullPointerCheck now deletes until the end brace of the condition

2019-05-13 Thread Jonathan Camilleri via Phabricator via cfe-commits
J-Camilleri updated this revision to Diff 199315. J-Camilleri added a comment. Added a new unit test and restored the modified test as it was. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61861/new/ https://reviews.llvm.org/D61861 Files:

[PATCH] D61804: Support building shared and static libraries simultaneously

2019-05-13 Thread Wink Saville via Phabricator via cfe-commits
winksaville added a comment. In D61804#1500409 , @beanz wrote: > My change should not have decreased build time from trunk, nor should it have > reduced the number of build steps. That patch should generate > lib/libClang_shared.so, which will export

[PATCH] D61827: [clang-tidy] modernize-loop-convert: impl const cast iter

2019-05-13 Thread Torbjörn Klatt via Phabricator via cfe-commits
torbjoernk updated this revision to Diff 199326. torbjoernk edited the summary of this revision. torbjoernk added a comment. Herald added subscribers: jdoerfert, jfb. Fixed the issues pointed out by Don Hinton and added note on OpenMP to the check's docs as suggested by Roman Lebedev. Also

[PATCH] D61827: [clang-tidy] modernize-loop-convert: impl const cast iter

2019-05-13 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Sounds good, thank you! Comment at: clang-tools-extra/docs/clang-tidy/checks/modernize-loop-convert.rst:262 +not been used on code with a compatibility requirements of OpenMP prior to +version 5. I would add a cross-reference to

Re: r360559 - [c++20] P1064R0: Allow virtual function calls in constant expression

2019-05-13 Thread Richard Smith via cfe-commits
Thanks for the revert and the reduced test case. On Mon, 13 May 2019, 07:50 Hans Wennborg via cfe-commits, < cfe-commits@lists.llvm.org> wrote: > Here's a creduced repro: > > -- > class a {}; > class b : virtual a { > virtual bool c(const void *, int); > }; > class C : b { > public: > bool

[PATCH] D58920: [Modules][PR39287] Consolidate multiple std's

2019-05-13 Thread Brian Gesiak via Phabricator via cfe-commits
modocache added a comment. Thanks @rsmith for the guidance here! I appreciate it very much. One snag I ran into after following your suggestion, though, is that when I modify `ASTDeclReader::findExisting` to return Sema's existing implicit std namespace, I run into an assertion later on, when

[libunwind] r360610 - Add a new LIBUNWIND_WEAK_PTHREAD Cmake option to force

2019-05-13 Thread Sterling Augustine via cfe-commits
Author: saugustine Date: Mon May 13 11:45:03 2019 New Revision: 360610 URL: http://llvm.org/viewvc/llvm-project?rev=360610=rev Log: Add a new LIBUNWIND_WEAK_PTHREAD Cmake option to force calls into the pthread library use weak symbols. This option allows libpthread to be a weak dependency rather

[PATCH] D61438: [ASTImporter] Use llvm::Expected and Error in the importer API

2019-05-13 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added inline comments. Comment at: clang/include/clang/AST/ASTImporter.h:203 /// context, or the import error. -llvm::Expected Import_New(TypeSourceInfo *FromTSI); -// FIXME: Remove this version. -TypeSourceInfo *Import(TypeSourceInfo *FromTSI); +

[PATCH] D61700: [clang-tidy] readability-redundant-declaration: fix false positive with C "extern inline"

2019-05-13 Thread Matthias Gehre via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. mgehre marked 2 inline comments as done. Closed by commit rL360613: [clang-tidy] readability-redundant-declaration: fix false positive with C… (authored by mgehre, committed by ). Herald added a project: LLVM. Herald added

[clang-tools-extra] r360613 - [clang-tidy] readability-redundant-declaration: fix false positive with C "extern inline"

2019-05-13 Thread Matthias Gehre via cfe-commits
Author: mgehre Date: Mon May 13 12:21:57 2019 New Revision: 360613 URL: http://llvm.org/viewvc/llvm-project?rev=360613=rev Log: [clang-tidy] readability-redundant-declaration: fix false positive with C "extern inline" Summary: readability-redundant-declaration was diagnosing a redundant

[PATCH] D61370: Add a C2x mode and allow attributes in it

2019-05-13 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Ping x2. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61370/new/ https://reviews.llvm.org/D61370 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D61804: Support building shared and static libraries simultaneously

2019-05-13 Thread Wink Saville via Phabricator via cfe-commits
winksaville added a comment. In D61804#1500445 , @winksaville wrote: > In D61804#1500409 , @beanz wrote: > > > My change should not have decreased build time from trunk, nor should it > > have reduced the number

[PATCH] D59464: [analyzer] Add an example plugin for checker dependency handling

2019-05-13 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. This revision is now accepted and ready to land. I can't say "no" to more tests. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59464/new/ https://reviews.llvm.org/D59464 ___ cfe-commits

[PATCH] D61749: [clang-tidy] initial version of readability-static-const-method

2019-05-13 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre updated this revision to Diff 199329. mgehre marked an inline comment as done. mgehre added a comment. Remove ``const`` part from this PR. Address comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61749/new/

[PATCH] D61749: [clang-tidy] initial version of readability-static-const-method

2019-05-13 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre marked 17 inline comments as done. mgehre added inline comments. Comment at: clang-tools-extra/test/clang-tidy/readability-static-const-method.cpp:312 +return const_cast(this)->get(); + } + JonasToth wrote: > mgehre wrote: > > JonasToth wrote: > > >

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-13 Thread Artem Belevich via Phabricator via cfe-commits
tra accepted this revision. tra added a comment. This revision is now accepted and ready to land. In D61765#1500457 , @gtbercea wrote: > This won't affect CUDA in any way, all we have added is OpenMP specific. LGTM for CUDA. I'll leave the question of

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

2019-05-13 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp:314 insertOptionToCollection(StringRef FullName, T , - const CheckerRegistry::CmdLineOption &) { + const CheckerRegistry::CmdLineOption &, +

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-13 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. In D61765#1500351 , @gtbercea wrote: > - Exclude clock functions. Reverse inclusion order. LGTM from my side. I don't have strong feelings about testing libc++ now, though it is probably a good idea to have such a testbed. I

[PATCH] D60910: [WIP] Dumping the AST to JSON

2019-05-13 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman closed this revision. aaron.ballman added a comment. Commit in r360622. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60910/new/ https://reviews.llvm.org/D60910 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D61858: Make `__is_base_of` more friendly with unions

2019-05-13 Thread Louis Dionne via Phabricator via cfe-commits
ldionne added a comment. Shouldn't we also add unit tests for PR41843 in libc++? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61858/new/ https://reviews.llvm.org/D61858 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D61861: DeleteNullPointerCheck now deletes until the end brace of the condition

2019-05-13 Thread Mads Ravn via Phabricator via cfe-commits
madsravn added a comment. Besides my one comment this looks good to me. Comment at: clang-tools-extra/test/clang-tidy/readability-delete-null-pointer.cpp:9 // #1 - if (p) { // #2 + if (p /**/) { // #2 delete p; Would you mind creating a new test

[PATCH] D61858: Make `__is_base_of` more friendly with unions

2019-05-13 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists closed this revision. mclow.lists added a comment. Committed as revision 360614 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61858/new/ https://reviews.llvm.org/D61858 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D61851: [clang-tidy] New option for misc-throw-by-value-catch-by-reference

2019-05-13 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/misc/ThrowByValueCatchByReferenceCheck.cpp:25 + WarnOnLargeObject(Options.get("WarnOnLargeObject", false)), + // Cannot access `ASTContext` from here so set it to an extremal value +

[PATCH] D61619: Make language option `GNUAsm` discoverable with `__has_extension` macro.

2019-05-13 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. Ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61619/new/ https://reviews.llvm.org/D61619 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D61809: [BPF] Preserve original struct/union type name/access index and array subscripts

2019-05-13 Thread Yonghong Song via Phabricator via cfe-commits
yonghong-song added a comment. @rsmith @eli.friedman Thanks for your comments. I fully agree that it seems awkward that we have both GEP and intrinsic generation. I will try to do some experiments here to only have intrinsic generation. My only concern is possible performance degradation. I

[PATCH] D24892: [clang-tidy] Add option "LiteralInitializers" to cppcoreguidelines-pro-type-member-init

2019-05-13 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tools-extra/docs/ReleaseNotes.rst:66-69 +- Added `UseAssignment` option to `cppcoreguidelines-pro-type-member-init` + + If set to true, the check will provide fix-its with literal initializers + (``int i = 0;``) instead of

[PATCH] D61804: Support building shared and static libraries simultaneously

2019-05-13 Thread Chris Bieneman via Phabricator via cfe-commits
beanz added a comment. My change should not have decreased build time from trunk, nor should it have reduced the number of build steps. That patch should generate lib/libClang_shared.so, which will export the C++ API. libClang is unchanged since changing it would break existing clients of the

[PATCH] D58920: [Modules][PR39287] Consolidate multiple std's

2019-05-13 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. The problem may well be that you're recursively triggering deserialization of the `std` namespace from its own deserialization. In D58920#1500246 , @modocache wrote: > @@ -3401,6 +3402,22 @@ ASTDeclReader::FindExistingResult >

r360607 - [clang][ASTContext] Call setAttached for comments attached to a declaration

2019-05-13 Thread Jan Korous via cfe-commits
Author: jkorous Date: Mon May 13 10:52:09 2019 New Revision: 360607 URL: http://llvm.org/viewvc/llvm-project?rev=360607=rev Log: [clang][ASTContext] Call setAttached for comments attached to a declaration This is a bug affecting performance when compiling with -Wdocumentation. In

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-13 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. In D61765#1500233 , @tra wrote: > In D61765#1499957 , @jdoerfert wrote: > > > Two small changes and then it is fine with me. @tra ? > > > LGTM in general. I would still like to confirm

[PATCH] D61858: Make `__is_base_of` more friendly with unions

2019-05-13 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists added a comment. In D61858#1500270 , @ldionne wrote: > Shouldn't we also add unit tests for PR41843 in libc++? Yes. But I want to do that later. After this has landed (and probably wait a week for all the bots that are running trunk to

[PATCH] D61619: Make language option `GNUAsm` discoverable with `__has_extension` macro.

2019-05-13 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! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61619/new/ https://reviews.llvm.org/D61619 ___ cfe-commits mailing

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-13 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D61765#1500309 , @gtbercea wrote: > As soon as libc++ the limits header included in > > __clang_cuda_cmath.h:15 > ``` is not found: > > > > > __clang_cuda_cmath.h:15:10: fatal error: 'limits' file not found > #include > >

[PATCH] D61370: Add a C2x mode and allow attributes in it

2019-05-13 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: lib/Frontend/CompilerInvocation.cpp:2593-2596 + // Enable [[]] attributes in C++11 and C2x by default. + Opts.DoubleSquareBracketAttributes = Args.hasFlag(

[PATCH] D60543: [clang] Update isDerivedFrom to support Objective-C classes 

2019-05-13 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D60543#1497576 , @stephanemoore wrote: > I did some digging and I believe there are two approaches that we can take to > extend `isDerivedFrom` to support Objective-C classes. > > **Option 1: Match on Common Ancestor

[PATCH] D61858: Make `__is_base_of` more friendly with unions

2019-05-13 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists added a comment. Note: There are tabs in `clang/test/SemaCXX/type-traits.cpp` that I didn't remove because it would have cluttered up the diff. I can de-tabify the file when it is committed if people want. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61858/new/

[PATCH] D59798: [analyzer] Add analyzer option to limit the number of imported TUs

2019-05-13 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 199277. gamesh411 added a comment. Apply review suggestions by Xazax Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59798/new/ https://reviews.llvm.org/D59798 Files: include/clang/CrossTU/CrossTranslationUnit.h

[PATCH] D61861: DeleteNullPointerCheck now deletes until the end brace of the condition

2019-05-13 Thread Jonathan Camilleri via Phabricator via cfe-commits
J-Camilleri created this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Bug Fix for #35811 Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D61861 Files: clang-tools-extra/clang-tidy/readability/DeleteNullPointerCheck.cpp

  1   2   >