[PATCH] D36067: [analyzer] Create infrastructure for organizing and declaring analyzer configs.

2017-08-01 Thread Raphael Isemann via Phabricator via cfe-commits
teemperor added a comment. In https://reviews.llvm.org/D36067#825867, @xazax.hun wrote: > I like the directions of this patch. > In general, I am in favor of explicitly registering the options from user > defined checkers. > But changing a config option will now break the command line

[PATCH] D35012: [refactor] Add the AST source selection component

2017-08-01 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. Ping. Repository: rL LLVM https://reviews.llvm.org/D35012 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D33676: Place implictly declared functions at block scope

2017-08-01 Thread Momchil Velikov via Phabricator via cfe-commits
chill added a comment. Ping. https://reviews.llvm.org/D33676 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D36131: clang-format: [JS] handle object types in extends positions.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
mprobst created this revision. Herald added a subscriber: klimek. clang-format would previously drop the whitespace after `extends` in code such as: class Foo extends {} {} Where the first set of curly braces is an inline object literal type. https://reviews.llvm.org/D36131 Files:

[PATCH] D36132: clang-format: [JS] support default imports.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
mprobst created this revision. Herald added a subscriber: klimek. Formerly, `import {default as X} from y;` would not be recognized as an import. https://reviews.llvm.org/D36132 Files: lib/Format/SortJavaScriptImports.cpp unittests/Format/SortImportsTestJS.cpp Index:

[PATCH] D35012: [refactor] Add the AST source selection component

2017-08-01 Thread Eric Liu via Phabricator via cfe-commits
ioeric accepted this revision. ioeric added a comment. This revision is now accepted and ready to land. Yep. Lgtm! Repository: rL LLVM https://reviews.llvm.org/D35012 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D36133: [clangd] Rewrote AST and Preamble management.

2017-08-01 Thread Benjamin Kramer via Phabricator via cfe-commits
bkramer added inline comments. Comment at: clangd/ClangdServer.h:113 + /// queue. The request will be run on a separate thread. + template void addToFront(Func &, Args &&... As); + /// Add a new request to run function \p F with args \p As to the end of the

[PATCH] D36133: [clangd] Rewrote AST and Preamble management.

2017-08-01 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. The new implementation allows code completion that never waits for AST. https://reviews.llvm.org/D36133 Files: clangd/ClangdServer.cpp clangd/ClangdServer.h clangd/ClangdUnit.cpp clangd/ClangdUnit.h clangd/ClangdUnitStore.cpp

[PATCH] D35012: [refactor] Add the AST source selection component

2017-08-01 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. Apart from nits, looks OK to me - Eric, are all your concerns addressed? Comment at: include/clang/Tooling/Refactoring/ASTSelection.h:51-53 + ast_type_traits::DynTypedNode Node; + SourceSelectionKind SelectionKind; + std::vector Children;

[PATCH] D36202: [Driver] Disable static C++ library support on Fuchsia

2017-08-01 Thread Roland McGrath via Phabricator via cfe-commits
mcgrathr accepted this revision. mcgrathr added a comment. This revision is now accepted and ready to land. LGTM. The nit below is orthogonal to this change. Comment at: lib/Driver/ToolChains/Fuchsia.cpp:112 ToolChain.AddCXXStdlibLibArgs(Args, CmdArgs); -if

[PATCH] D36194: [CMake] Include llvm-objcopy tool in Fuchsia toolchain

2017-08-01 Thread Petr Hosek via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL309786: [CMake] Include llvm-objcopy tool in Fuchsia toolchain (authored by phosek). Changed prior to commit: https://reviews.llvm.org/D36194?vs=109233=109265#toc Repository: rL LLVM

[PATCH] D24461: CodeGen: Cast llvm.flt.rounds result to match __builtin_flt_rounds

2017-08-01 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Did this ever get committed? https://reviews.llvm.org/D24461 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r309786 - [CMake] Include llvm-objcopy tool in Fuchsia toolchain

2017-08-01 Thread Petr Hosek via cfe-commits
Author: phosek Date: Tue Aug 1 19:49:09 2017 New Revision: 309786 URL: http://llvm.org/viewvc/llvm-project?rev=309786=rev Log: [CMake] Include llvm-objcopy tool in Fuchsia toolchain Differential Revision: https://reviews.llvm.org/D36194 Modified: cfe/trunk/cmake/caches/Fuchsia-stage2.cmake

[PATCH] D36208: [mips] Enable target-specific attributes for MIPS64

2017-08-01 Thread Simon Atanasyan via Phabricator via cfe-commits
atanasyan created this revision. atanasyan added a project: clang. Herald added a subscriber: arichardson. This change enables `long_call/short_call/far/near`, `micromips`, and `interrupt` attributes on MIPS64 targets. In case of using the `mips16` attribute with any ABI except `O32` compiler

[PATCH] D36209: [Bash-autocompletion] Add comment to test so that it is easier to fix

2017-08-01 Thread Yuka Takahashi via Phabricator via cfe-commits
yamaguchi created this revision. clang/test/Driver/autocomplete.c is a test for --autocomplete, and this test might break if people add/modify flags or HelpText. So I've add comment for future developers so that they can fix this file according to the change they had made.

[PATCH] D36209: [Bash-autocompletion] Add comment to test so that it is easier to fix

2017-08-01 Thread Rui Ueyama via Phabricator via cfe-commits
ruiu added a comment. I wonder if this test is actually fragile. How can you break this test by adding a new flag? Comment at: clang/test/Driver/autocomplete.c:3 +// If this test had broke due to adding/modifying flags or changing HelpText, +// please modify this file

Re: r309752 - [Headers][Darwin] Allow #include_next to work on Darwin prior to 10.7

2017-08-01 Thread Hans Wennborg via cfe-commits
Merged in r309764. You cc'd me on the bug, so I noticed that :-) Just marking a bug a release blocker doesn't generally work though; it needs to be marked as blocking PR33849. (Though I will search for "release blocker" severity bugs now and then.) On Tue, Aug 1, 2017 at 3:15 PM, Bruno Cardoso

Re: r309722 - [Sema] Fix lax conversion between non ext vectors

2017-08-01 Thread Hans Wennborg via cfe-commits
On Tue, Aug 1, 2017 at 4:41 PM, Richard Smith wrote: > I assume there's an implied "merge to 5.0 branch?" question here :) Yes :-) I lost that part somehow. > > Yes, horrible as lax vector conversions are, we shouldn't accidentally > regress support for them. r309770.

[PATCH] D32199: [TySan] A Type Sanitizer (Clang)

2017-08-01 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Has this proposal run aground? I'm going back over some old patches that I've been CC'ed on and trying to make sure they're not blocking on my review. https://reviews.llvm.org/D32199 ___ cfe-commits mailing list

Re: r309722 - [Sema] Fix lax conversion between non ext vectors

2017-08-01 Thread Hans Wennborg via cfe-commits
Sounds good to me. Richard, what do you think? On Tue, Aug 1, 2017 at 12:05 PM, Bruno Cardoso Lopes via cfe-commits wrote: > Author: bruno > Date: Tue Aug 1 12:05:25 2017 > New Revision: 309722 > > URL: http://llvm.org/viewvc/llvm-project?rev=309722=rev > Log: >

Re: r309722 - [Sema] Fix lax conversion between non ext vectors

2017-08-01 Thread Richard Smith via cfe-commits
I assume there's an implied "merge to 5.0 branch?" question here :) Yes, horrible as lax vector conversions are, we shouldn't accidentally regress support for them. On 1 August 2017 at 16:28, Hans Wennborg via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Sounds good to me. Richard, what

Re: r309752 - [Headers][Darwin] Allow #include_next to work on Darwin prior to 10.7

2017-08-01 Thread Bruno Cardoso Lopes via cfe-commits
On Tue, Aug 1, 2017 at 4:34 PM, Hans Wennborg wrote: > Merged in r309764. > > You cc'd me on the bug, so I noticed that :-) > > Just marking a bug a release blocker doesn't generally work though; it > needs to be marked as blocking PR33849. (Though I will search for > "release

[PATCH] D35922: [Driver] Enable AddressSanitizer for Fuchsia targets

2017-08-01 Thread Petr Hosek via Phabricator via cfe-commits
phosek added inline comments. Comment at: cmake/caches/Fuchsia-stage2.cmake:50 set(RUNTIMES_${target}-fuchsia_LIBCXX_ABI_VERSION 2 CACHE STRING "") + set(RUNTIMES_${target}-fuchsia_SANITIZER_USE_COMPILER_RT ON CACHE BOOL "") endforeach() mcgrathr wrote: >

[PATCH] D35922: [Driver] Enable AddressSanitizer for Fuchsia targets

2017-08-01 Thread Petr Hosek via Phabricator via cfe-commits
phosek accepted this revision. phosek added a comment. This revision is now accepted and ready to land. LGTM Repository: rL LLVM https://reviews.llvm.org/D35922 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

r309778 - [Driver] Disable static C++ library support on Fuchsia

2017-08-01 Thread Petr Hosek via cfe-commits
Author: phosek Date: Tue Aug 1 18:18:02 2017 New Revision: 309778 URL: http://llvm.org/viewvc/llvm-project?rev=309778=rev Log: [Driver] Disable static C++ library support on Fuchsia Don't support or build static C++ libraries for Fuchsia. Differential Revision: https://reviews.llvm.org/D36202

[PATCH] D36202: [Driver] Disable static C++ library support on Fuchsia

2017-08-01 Thread Petr Hosek via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL309778: [Driver] Disable static C++ library support on Fuchsia (authored by phosek). Changed prior to commit: https://reviews.llvm.org/D36202?vs=109255=109258#toc Repository: rL LLVM

[PATCH] D36202: [Driver] Disable static C++ library support on Fuchsia

2017-08-01 Thread Petr Hosek via Phabricator via cfe-commits
phosek added inline comments. Comment at: lib/Driver/ToolChains/Fuchsia.cpp:112 ToolChain.AddCXXStdlibLibArgs(Args, CmdArgs); -if (OnlyLibstdcxxStatic) - CmdArgs.push_back("-Bdynamic"); - } CmdArgs.push_back("-lm"); }

[PATCH] D34801: [coverage] Make smaller regions for the first case of a switch.

2017-08-01 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. In https://reviews.llvm.org/D34801#828382, @efriedma wrote: > I'm going to look over the overall algorithm one more time to make sure this > direction makes sense. The current code for ending regions on > break/continue/return/noreturn doesn't really work well, Maybe

[PATCH] D34801: [coverage] Make smaller regions for the first case of a switch.

2017-08-01 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. I'm going to look over the overall algorithm one more time to make sure this direction makes sense. The current code for ending regions on break/continue/return/noreturn doesn't really work well, and the way we handle multiple consecutive case statments isn't really

[PATCH] D36200: [Sema] Improve some -Wunguarded-availability diagnostic messages

2017-08-01 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington created this revision. This patch improves the decl-level unguarded availability warnings to use the same messages as the function-level ones. This makes the diagnostic have different parameters than deprecated/unavailable, so I moved some things around in

[PATCH] D36202: [Driver] Disable static C++ library support on Fuchsia

2017-08-01 Thread Petr Hosek via Phabricator via cfe-commits
phosek created this revision. Herald added a subscriber: mgorny. Don't support or build static C++ libraries for Fuchsia. Repository: rL LLVM https://reviews.llvm.org/D36202 Files: cmake/caches/Fuchsia-stage2.cmake lib/Driver/ToolChains/Fuchsia.cpp test/Driver/fuchsia.cpp Index:

[PATCH] D36105: [AArch64] Ignore stdcall and similar on aarch64/windows

2017-08-01 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added inline comments. Comment at: lib/Basic/Targets/AArch64.cpp:466-467 + case CC_X86ThisCall: + case CC_X86FastCall: + case CC_X86VectorCall: +return CCCR_Ignore; mstorsjo wrote: > rnk wrote: > > Do they really ignore __fastcall and

Re: [PATCH] D36112: [ubsan] Have -fsanitize=vptr emit a null check if -fsanitize=null isn't available

2017-08-01 Thread Nico Weber via cfe-commits
It'd be good if this could go in today. ubsanvptr has been broken for us for a while now. On Mon, Jul 31, 2017 at 4:43 PM, Vedant Kumar via Phabricator via cfe-commits wrote: > vsk created this revision. > > In r309007, I made -fsanitize=null a hard prerequisite for

r309731 - Revert "Thread Safety Analysis: fix assert_capability."

2017-08-01 Thread Josh Gao via cfe-commits
Author: jmgao Date: Tue Aug 1 12:53:31 2017 New Revision: 309731 URL: http://llvm.org/viewvc/llvm-project?rev=309731=rev Log: Revert "Thread Safety Analysis: fix assert_capability." This reverts commit rL309725. Broke test/Sema/attr-capabilities.c. Modified:

[PATCH] D34748: [clang-diff] improve mapping accuracy

2017-08-01 Thread Johannes Altmanninger via Phabricator via cfe-commits
johannes abandoned this revision. johannes added a comment. split up in several commits starting from https://reviews.llvm.org/D36176 Comment at: lib/Tooling/ASTDiff/ASTDiff.cpp:170 + // Ignore everything from other files. + if (!SrcMgr.isInMainFile(SLoc)) +return true;

[PATCH] D36122: Thread Safety Analysis: fix assert_capability.

2017-08-01 Thread Josh Gao via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL309725: Thread Safety Analysis: fix assert_capability. (authored by jmgao). Repository: rL LLVM https://reviews.llvm.org/D36122 Files: cfe/trunk/include/clang/Basic/Attr.td

[PATCH] D36022: [analyzer] Add handle misuse analysis to MagentaHandleChecker

2017-08-01 Thread Haowei Wu via Phabricator via cfe-commits
haowei updated this revision to Diff 109237. haowei added a comment. Add 1 line fix for the constraint on allocated handle in function allocateSingleHandle at line 647 https://reviews.llvm.org/D36022 Files: lib/StaticAnalyzer/Checkers/MagentaHandleChecker.cpp test/Analysis/mxhandle.c

r309738 - [clang-diff] Renames, NFC

2017-08-01 Thread Johannes Altmanninger via cfe-commits
Author: krobelus Date: Tue Aug 1 13:17:46 2017 New Revision: 309738 URL: http://llvm.org/viewvc/llvm-project?rev=309738=rev Log: [clang-diff] Renames, NFC Modified: cfe/trunk/include/clang/Tooling/ASTDiff/ASTDiff.h cfe/trunk/lib/Tooling/ASTDiff/ASTDiff.cpp Modified:

[PATCH] D36118: Fix creating bitcasts with wrong address space

2017-08-01 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm closed this revision. arsenm added a comment. r309741 https://reviews.llvm.org/D36118 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D36168: added support for build with dataflow sanitizer

2017-08-01 Thread Farah Hariri via Phabricator via cfe-commits
farahhariri created this revision. Herald added a subscriber: mgorny. [libc++] added support for build with dataflow sanitizer https://reviews.llvm.org/D36168 Files: CMakeLists.txt Index: CMakeLists.txt === --- CMakeLists.txt

[PATCH] D36194: [CMake] Include llvm-objcopy tool in Fuchsia toolchain

2017-08-01 Thread Petr Hosek via Phabricator via cfe-commits
phosek created this revision. Herald added a subscriber: mgorny. Repository: rL LLVM https://reviews.llvm.org/D36194 Files: cmake/caches/Fuchsia-stage2.cmake Index: cmake/caches/Fuchsia-stage2.cmake === ---

r309752 - [Headers][Darwin] Allow #include_next to work on Darwin prior to 10.7

2017-08-01 Thread Bruno Cardoso Lopes via cfe-commits
Author: bruno Date: Tue Aug 1 15:10:36 2017 New Revision: 309752 URL: http://llvm.org/viewvc/llvm-project?rev=309752=rev Log: [Headers][Darwin] Allow #include_next to work on Darwin prior to 10.7 This fixes PR31504 and it's a follow up from adding #include_next for Darwin in r289018.

[PATCH] D36171: AMDGPU: Use direct struct returns

2017-08-01 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm created this revision. Herald added subscribers: t-tye, tpr, dstuttard, nhaehnle, wdng, kzhuravl. This is an improvement over always using byval for structs. This will use registers until ~16 are used, and then switch back to byval. This needs more work, since I'm not sure it ever

Re: [PATCH] D36112: [ubsan] Have -fsanitize=vptr emit a null check if -fsanitize=null isn't available

2017-08-01 Thread Vedant Kumar via cfe-commits
Alex is in a different time zone, so he may not get to this today. Do you have the time to give a review? > On Aug 1, 2017, at 12:38 PM, Nico Weber wrote: > > It'd be good if this could go in today. ubsanvptr has been broken for us for > a while now. > > On Mon, Jul 31,

[PATCH] D35921: [clang-diff] HTML side-by-side diff

2017-08-01 Thread Johannes Altmanninger via Phabricator via cfe-commits
johannes abandoned this revision. johannes added a comment. moved to https://reviews.llvm.org/D36182, sorry for the noise https://reviews.llvm.org/D35921 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D36191: [CodeGen] Don't make availability attributes imply default visibility on macos

2017-08-01 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington created this revision. Previously, the presence of `__attribute__((availability(macos, ...)))` on a declaration caused clang to make the vis of that decl implicitly default. This is a hack that is incomparable with how we're treating availability attributes now, and should be

r309750 - [clang] Change the condition of unnecessary packed warning

2017-08-01 Thread Yan Wang via cfe-commits
Author: yawanng Date: Tue Aug 1 14:41:39 2017 New Revision: 309750 URL: http://llvm.org/viewvc/llvm-project?rev=309750=rev Log: [clang] Change the condition of unnecessary packed warning Summary: Change the condition of this unnecessary packed warning. The packed is unnecessary when 1. the

[PATCH] D35922: [Driver] Enable AddressSanitizer for Fuchsia targets

2017-08-01 Thread Roland McGrath via Phabricator via cfe-commits
mcgrathr added inline comments. Comment at: cmake/caches/Fuchsia-stage2.cmake:50 set(RUNTIMES_${target}-fuchsia_LIBCXX_ABI_VERSION 2 CACHE STRING "") + set(RUNTIMES_${target}-fuchsia_SANITIZER_USE_COMPILER_RT ON CACHE BOOL "") endforeach() phosek wrote: > I

r309737 - [clang-diff] Move data declarations to the public header

2017-08-01 Thread Johannes Altmanninger via cfe-commits
Author: krobelus Date: Tue Aug 1 13:17:40 2017 New Revision: 309737 URL: http://llvm.org/viewvc/llvm-project?rev=309737=rev Log: [clang-diff] Move data declarations to the public header Modified: cfe/trunk/include/clang/Tooling/ASTDiff/ASTDiff.h

[PATCH] D35743: [clang-format] Handle Structured binding declaration in C++17

2017-08-01 Thread Yan Wang via Phabricator via cfe-commits
yawanng updated this revision to Diff 109222. yawanng added a comment. Move tests to unitest and fix a bug. https://reviews.llvm.org/D35743 Files: lib/Format/TokenAnnotator.cpp lib/Format/UnwrappedLineParser.cpp lib/Format/UnwrappedLineParser.h unittests/Format/FormatTest.cpp Index:

[PATCH] D36194: [CMake] Include llvm-objcopy tool in Fuchsia toolchain

2017-08-01 Thread Jake Ehrlich via Phabricator via cfe-commits
jakehehrlich accepted this revision. jakehehrlich added a comment. This revision is now accepted and ready to land. LGTM Repository: rL LLVM https://reviews.llvm.org/D36194 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

r309741 - Fix creating bitcasts with wrong address space

2017-08-01 Thread Matt Arsenault via cfe-commits
Author: arsenm Date: Tue Aug 1 13:36:57 2017 New Revision: 309741 URL: http://llvm.org/viewvc/llvm-project?rev=309741=rev Log: Fix creating bitcasts with wrong address space In a future commit AMDGPU will start passing aggregates directly to more functions, triggering asserts in

[PATCH] D36067: [analyzer] Create infrastructure for organizing and declaring analyzer configs.

2017-08-01 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna added a comment. >> I tried to keep this as a minimal starting example because this currently >> blocks @yamaguchi 's GSoC project for bash completion. There we want to >> complete the values for -analyzer-config and we currently don't have a good >> way to get a complete list of

[PATCH] D35937: [clang-tidy] Add new readability non-idiomatic static access

2017-08-01 Thread Barancsuk Lilla via Phabricator via cfe-commits
barancsuk added inline comments. Comment at: clang-tidy/readability/StaticAccessedThroughInstanceCheck.cpp:23 + memberExpr(hasDeclaration(anyOf(cxxMethodDecl(isStaticStorageClass()), + varDecl(hasStaticStorageDuration(, +

[PATCH] D36133: [clangd] Rewrote AST and Preamble management.

2017-08-01 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 109124. ilya-biryukov added a comment. Addressed review comments. - Moved implementations of template function to header. - Fixed a typo. https://reviews.llvm.org/D36133 Files: clangd/ClangdServer.cpp clangd/ClangdServer.h

[PATCH] D33537: [clang-tidy] Exception Escape Checker

2017-08-01 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In https://reviews.llvm.org/D33537#827509, @baloghadamsoftware wrote: > Test changed. I made some bad throws reachable, but the frontend check still > does detects them. If block contains two or more throws, that mean compiler can not statically know throw is really

[PATCH] D36133: [clangd] Rewrote AST and Preamble management.

2017-08-01 Thread Benjamin Kramer via Phabricator via cfe-commits
bkramer accepted this revision. bkramer added a comment. This revision is now accepted and ready to land. ship it! https://reviews.llvm.org/D36133 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D35109: [Analyzer] SValBuilder Comparison Rearrangement

2017-08-01 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 109117. baloghadamsoftware added a comment. Overflow scenarios skipped. https://reviews.llvm.org/D35109 Files: lib/StaticAnalyzer/Core/SimpleSValBuilder.cpp test/Analysis/svalbuilder-rearrange-comparisons.c Index:

[PATCH] D36150: [clangd] LSP extension to switch between source/header file

2017-08-01 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle requested changes to this revision. malaperle added inline comments. This revision now requires changes to proceed. Comment at: clangd/ClangdServer.cpp:292 + + if (path.compare(path.length() - 4, 4, ".cpp") == 0) { +path = path.substr(0, (path.length() - 4));

[PATCH] D36150: [clangd] LSP extension to switch between source/header file

2017-08-01 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added inline comments. Comment at: clangd/ClangdServer.cpp:292 + + if (path.compare(path.length() - 4, 4, ".cpp") == 0) { +path = path.substr(0, (path.length() - 4)); malaperle wrote: > this won't work for other extensions, we need to make this

[PATCH] D35937: [clang-tidy] Add new readability non-idiomatic static access

2017-08-01 Thread Barancsuk Lilla via Phabricator via cfe-commits
barancsuk updated this revision to Diff 109120. barancsuk marked 7 inline comments as done. barancsuk added a comment. Address review comments https://reviews.llvm.org/D35937 Files: clang-tidy/readability/CMakeLists.txt clang-tidy/readability/ReadabilityTidyModule.cpp

[PATCH] D36149: [Tooling] Add LLVM_NODISCARD to Replacements::merge

2017-08-01 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL309689: [Tooling] Add LLVM_NODISCARD to Replacements::merge (authored by krasimir). Repository: rL LLVM https://reviews.llvm.org/D36149 Files: cfe/trunk/include/clang/Tooling/Core/Replacement.h

[PATCH] D36133: [clangd] Rewrote AST and Preamble management.

2017-08-01 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov marked 3 inline comments as done. ilya-biryukov added inline comments. Comment at: clangd/ClangdServer.h:113 + /// queue. The request will be run on a separate thread. + template void addToFront(Func &, Args &&... As); + /// Add a new request to run function

[PATCH] D33537: [clang-tidy] Exception Escape Checker

2017-08-01 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 109126. baloghadamsoftware added a comment. Herald added a subscriber: JDevlieghere. Test changed. I made some bad throws reachable, but the frontend check still does detects them. https://reviews.llvm.org/D33537 Files:

[PATCH] D36154: Adapt clang-tidy checks to changing semantics of hasDeclaration.

2017-08-01 Thread Manuel Klimek via Phabricator via cfe-commits
klimek created this revision. Herald added a subscriber: JDevlieghere. https://reviews.llvm.org/D36154 Files: clang-tidy/google/StringReferenceMemberCheck.cpp clang-tidy/misc/DanglingHandleCheck.cpp clang-tidy/misc/InaccurateEraseCheck.cpp clang-tidy/misc/UseAfterMoveCheck.cpp

[PATCH] D33365: [clang-tidy] misc-assertion-count: A New Check

2017-08-01 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In https://reviews.llvm.org/D33365#802884, @lebedev.ri wrote: > In https://reviews.llvm.org/D33365#775916, @alexfh wrote: > > > I think, this kind of a check needs some prior research (not necessarily in > > the sense of a printed paper, but at least a thoughtful

[PATCH] D36150: [clangd] LSP extension to switch between source/header file

2017-08-01 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added a comment. In the commit message, you could add that we will use and index of symbols later to be able to switch from header to source file when the file names don't match. This is more or less the justification of why we want this in Clangd and not on the client.

r309689 - [Tooling] Add LLVM_NODISCARD to Replacements::merge

2017-08-01 Thread Krasimir Georgiev via cfe-commits
Author: krasimir Date: Tue Aug 1 07:58:14 2017 New Revision: 309689 URL: http://llvm.org/viewvc/llvm-project?rev=309689=rev Log: [Tooling] Add LLVM_NODISCARD to Replacements::merge Summary: This patch adds LLVM_NODISCARD to Replacements::merge. I've hit this several times already. Reviewers:

[PATCH] D33672: [analyzer] INT50-CPP. Do not cast to an out-of-range enumeration checker

2017-08-01 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. Even though it is not undefined behavior in C, it can still cause surprising behavior for the users. I think maybe putting it into the optin package instead of cplusplus is better. What do you think? https://reviews.llvm.org/D33672

[PATCH] D33672: [analyzer] INT50-CPP. Do not cast to an out-of-range enumeration checker

2017-08-01 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. Even though it is not undefined behavior in C, it can still cause surprising behavior for the users. I think maybe putting it into the optin package instead of cplusplus is better. What do you think? https://reviews.llvm.org/D33672

r309678 - [OpenCL] Add missing subgroup builtins

2017-08-01 Thread Joey Gouly via cfe-commits
Author: joey Date: Tue Aug 1 06:27:09 2017 New Revision: 309678 URL: http://llvm.org/viewvc/llvm-project?rev=309678=rev Log: [OpenCL] Add missing subgroup builtins This adds get_kernel_max_sub_group_size_for_ndrange and get_kernel_sub_group_count_for_ndrange. Modified:

[PATCH] D30295: [analyzer] clarify undef shift result when shift count is negative or exceeds the bit width

2017-08-01 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: lib/StaticAnalyzer/Checkers/UndefResultChecker.cpp:126 + << BinaryOperator::getOpcodeStr(B->getOpcode()) + << "' expression is undefined due to shift count >= width of type"; + } else {

[PATCH] D36150: [clangd] LSP extension to switch between source/header file

2017-08-01 Thread William Enright via Phabricator via cfe-commits
Nebiroth created this revision. Small extension to LSP to allow clients to use clangd to switch between C header files and source files. Final version will use the completed clangd indexer. https://reviews.llvm.org/D36150 Files: clangd/ClangdLSPServer.cpp clangd/ClangdServer.cpp

Re: r305903 - Function with unparsed body is a definition

2017-08-01 Thread Alexander Kornienko via cfe-commits
This change causes an assertion failure on valid code. Could you take a look at fixing this? A reduced test case: $ cat /tmp/SemaTemplateInstantiateDecl-crash2.cpp template constexpr void f(T) { f(0); } $ clang -fsyntax-only -std=c++11 /tmp/SemaTemplateInstantiateDecl-crash2.cpp assert.h

[PATCH] D36141: [StaticAnalyzer] Fix FP in UnreachableCodeChecker

2017-08-01 Thread Daniel Marjamäki via Phabricator via cfe-commits
danielmarjamaki created this revision. Herald added a subscriber: whisperity. This fixes a FP. Without the fix, the checker says that "static int x;" is unreachable. Repository: rL LLVM https://reviews.llvm.org/D36141 Files: lib/StaticAnalyzer/Checkers/UnreachableCodeChecker.cpp

[PATCH] D36133: [clangd] Rewrote AST and Preamble management.

2017-08-01 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 109091. ilya-biryukov added a comment. - Fixed a bug that caused CppFiles to be deleted while used. https://reviews.llvm.org/D36133 Files: clangd/ClangdServer.cpp clangd/ClangdServer.h clangd/ClangdUnit.cpp clangd/ClangdUnit.h

[PATCH] D36147: clang-format: [JS] handle union types in arrow functions.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
mprobst created this revision. Herald added a subscriber: klimek. clang-format would previously fail to detect that an arrow functions parameter block is not an expression, and thus insert whitespace around the `|` and `&` type operators in it. https://reviews.llvm.org/D36147 Files:

[PATCH] D36148: clang-format: [JS] support fields with case/switch/default labels.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
mprobst created this revision. Herald added a subscriber: klimek. `case:` and `default:` would normally parse as labels for a `switch` block. However in TypeScript, they can be used in field declarations, e.g.: interface I { case: string; } This change special cases parsing them in

[PATCH] D36149: [Tooling] Add LLVM_NODISCARD to Replacements::merge

2017-08-01 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added a subscriber: klimek. This patch adds LLVM_NODISCARD to Replacements::merge. I've hit this several times already. https://reviews.llvm.org/D36149 Files: include/clang/Tooling/Core/Replacement.h Index: include/clang/Tooling/Core/Replacement.h

[PATCH] D36149: [Tooling] Add LLVM_NODISCARD to Replacements::merge

2017-08-01 Thread Eric Liu via Phabricator via cfe-commits
ioeric accepted this revision. ioeric added a comment. This revision is now accepted and ready to land. Thanks!!! https://reviews.llvm.org/D36149 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D36143: [clang-format] Fix indent of 'key <...>' in text protos

2017-08-01 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added a subscriber: klimek. This patch fixes the indentation of the code pattern `key <...>` in text protos. Previously, such line would be alinged depending on the column of the previous colon, which usually indents too much.

RE: [PATCH] D34158: For standards compatibility, preinclude if the file is available

2017-08-01 Thread Blower, Melanie via cfe-commits
joerg added a comment. I had a long discussion with James about this on IRC without reaching a clear consensus. I consider forcing this behavior on all targets to be a major bug. It should be opt-in and opt-in only: (1) The header name is not mandated by any standard. It is not in any

[PATCH] D36141: [StaticAnalyzer] Fix FP in UnreachableCodeChecker

2017-08-01 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun accepted this revision. xazax.hun added reviewers: NoQ, dcoughlin. xazax.hun added a comment. This revision is now accepted and ready to land. LGTM! Repository: rL LLVM https://reviews.llvm.org/D36141 ___ cfe-commits mailing list

[PATCH] D36131: clang-format: [JS] handle object types in extends positions.

2017-08-01 Thread Daniel Jasper via Phabricator via cfe-commits
djasper accepted this revision. djasper added a comment. This revision is now accepted and ready to land. Looks good. https://reviews.llvm.org/D36131 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D36144: clang-format: [JS] consistenly format enums.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
mprobst created this revision. Herald added a subscriber: klimek. Previously, const enums would get formatted differently because the modifier was not recognized. https://reviews.llvm.org/D36144 Files: lib/Format/TokenAnnotator.cpp unittests/Format/FormatTestJS.cpp Index:

[PATCH] D36146: clang-format: [JS] whitespace between keywords and parenthesized expressions.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
mprobst created this revision. Herald added a subscriber: klimek. `throw (...)` should have a whitespace following it, as do await and void. https://reviews.llvm.org/D36146 Files: lib/Format/TokenAnnotator.cpp unittests/Format/FormatTestJS.cpp Index: unittests/Format/FormatTestJS.cpp

[PATCH] D36131: clang-format: [JS] handle object types in extends positions.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
mprobst updated this revision to Diff 109078. mprobst added a comment. - revert bogus change https://reviews.llvm.org/D36131 Files: lib/Format/TokenAnnotator.cpp lib/Format/UnwrappedLineParser.cpp unittests/Format/FormatTestJS.cpp Index: unittests/Format/FormatTestJS.cpp

[PATCH] D34158: For standards compatibility, preinclude if the file is available

2017-08-01 Thread Joerg Sonnenberger via Phabricator via cfe-commits
joerg added a comment. I had a long discussion with James about this on IRC without reaching a clear consensus. I consider forcing this behavior on all targets to be a major bug. It should be opt-in and opt-in only: (1) The header name is not mandated by any standard. It is not in any

[PATCH] D36142: clang-format: [JS] do not insert whitespace in call positions.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
mprobst updated this revision to Diff 109089. mprobst added a comment. - support switch, case, delete. https://reviews.llvm.org/D36142 Files: lib/Format/TokenAnnotator.cpp unittests/Format/FormatTestJS.cpp Index: unittests/Format/FormatTestJS.cpp

[PATCH] D34878: [ARM] Option for reading thread pointer from coprocessor register

2017-08-01 Thread Strahinja Petrovic via Phabricator via cfe-commits
spetrovic added a comment. Comments addressed. https://reviews.llvm.org/D34878 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r309672 - [x86][inline-asm]Allow a pack of Control Debug to be properly picked

2017-08-01 Thread Coby Tayree via cfe-commits
Author: coby Date: Tue Aug 1 03:51:09 2017 New Revision: 309672 URL: http://llvm.org/viewvc/llvm-project?rev=309672=rev Log: [x86][inline-asm]Allow a pack of Control Debug to be properly picked Allows the incorporation of legit (x86) Debug Regs within inline asm stataements Differential

[PATCH] D36074: [x86][inline-asm]Allow a pack of Control Debug to be properly picked

2017-08-01 Thread coby via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL309672: [x86][inline-asm]Allow a pack of Control Debug to be properly picked (authored by coby). Changed prior to commit: https://reviews.llvm.org/D36074?vs=108872=109073#toc Repository: rL LLVM

[PATCH] D36139: clang-format: [JS] prefer wrapping chains over empty literals.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
mprobst created this revision. Herald added a subscriber: klimek. E.g. don't wrap like this: (foo.bar.baz).and.bam(Blah.of({ })) But rather: (foo.bar.baz) .and.bam(Blah.of({})) https://reviews.llvm.org/D36139 Files: lib/Format/TokenAnnotator.cpp

[PATCH] D34878: [ARM] Option for reading thread pointer from coprocessor register

2017-08-01 Thread Strahinja Petrovic via Phabricator via cfe-commits
spetrovic updated this revision to Diff 109088. https://reviews.llvm.org/D34878 Files: include/clang/Basic/DiagnosticDriverKinds.td include/clang/Driver/CC1Options.td include/clang/Driver/Options.td lib/Driver/ToolChains/Arch/ARM.cpp lib/Driver/ToolChains/Arch/ARM.h

[PATCH] D36159: clang-format: [JS] handle single lines comments ending in `\\`.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
mprobst created this revision. Herald added a subscriber: klimek. Previously, clang-format would consider the following code line to be part of the comment and incorrectly format the rest of the file. https://reviews.llvm.org/D36159 Files: lib/Format/FormatTokenLexer.cpp

[PATCH] D35817: Ban implicit _Complex to scalar conversions in C++

2017-08-01 Thread Tim Northover via Phabricator via cfe-commits
t.p.northover updated this revision to Diff 109149. t.p.northover added a comment. Sounds like an improvement, I've updated the diff. https://reviews.llvm.org/D35817 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/lib/Sema/SemaChecking.cpp clang/lib/Sema/SemaExpr.cpp

r309707 - clang-format: [JS] handle union types in arrow functions.

2017-08-01 Thread Martin Probst via cfe-commits
Author: mprobst Date: Tue Aug 1 10:19:32 2017 New Revision: 309707 URL: http://llvm.org/viewvc/llvm-project?rev=309707=rev Log: clang-format: [JS] handle union types in arrow functions. Summary: clang-format would previously fail to detect that an arrow functions parameter block is not an

r309710 - clang-format: [JS] whitespace between keywords and parenthesized expressions.

2017-08-01 Thread Martin Probst via cfe-commits
Author: mprobst Date: Tue Aug 1 10:22:15 2017 New Revision: 309710 URL: http://llvm.org/viewvc/llvm-project?rev=309710=rev Log: clang-format: [JS] whitespace between keywords and parenthesized expressions. Summary: `throw (...)` should have a whitespace following it, as do await and void.

[PATCH] D36147: clang-format: [JS] handle union types in arrow functions.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL309707: clang-format: [JS] handle union types in arrow functions. (authored by mprobst). Repository: rL LLVM https://reviews.llvm.org/D36147 Files: cfe/trunk/lib/Format/TokenAnnotator.cpp

[PATCH] D36146: clang-format: [JS] whitespace between keywords and parenthesized expressions.

2017-08-01 Thread Martin Probst via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL309710: clang-format: [JS] whitespace between keywords and parenthesized expressions. (authored by mprobst). Repository: rL LLVM https://reviews.llvm.org/D36146 Files:

  1   2   >