[PATCH] D49051: [libclang] check that the cursor is declaration before trying to evaluate the cursor like a declaration

2018-07-09 Thread Alex Lorenz via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. arphaman marked an inline comment as done. Closed by commit rL336590: [libclang] evalute compound statement cursors before trying to evaluate (authored by arphaman, committed by ). Herald added a subscriber: llvm-commits. C

[PATCH] D48753: [libcxx] Use custom allocator's `construct` in C++03 when available.

2018-07-09 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added inline comments. Comment at: libcxx/include/memory:1470 +decltype(_VSTD::declval<_Alloc>().construct(_VSTD::declval<_Pointer>(), +_VSTD::declval<_Args>())), +void Quuxplusone wrote:

r336591 - [libclang] NFC, simplify clang_Cursor_Evaluate

2018-07-09 Thread Alex Lorenz via cfe-commits
Author: arphaman Date: Mon Jul 9 12:56:45 2018 New Revision: 336591 URL: http://llvm.org/viewvc/llvm-project?rev=336591&view=rev Log: [libclang] NFC, simplify clang_Cursor_Evaluate Take advantage of early returns as suggested by Duncan in https://reviews.llvm.org/D49051 Modified: cfe/trunk/

r336592 - [OPENMP] Do not mark local variables as declare target.

2018-07-09 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Mon Jul 9 12:58:08 2018 New Revision: 336592 URL: http://llvm.org/viewvc/llvm-project?rev=336592&view=rev Log: [OPENMP] Do not mark local variables as declare target. When the parsing of the functions happens inside of the declare target region, we may erroneously mark loca

[PATCH] D48482: [Power9] [CLANG] Add __float128 support for trunc to double round to odd

2018-07-09 Thread Stefan Pintilie via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC336596: [Power9] [CLANG] Add __float128 support for trunc to double round to odd (authored by stefanp, committed by ). Herald added a subscriber: cfe-commits. Changed prior to commit: https://reviews.ll

r336596 - [Power9] [CLANG] Add __float128 support for trunc to double round to odd

2018-07-09 Thread Stefan Pintilie via cfe-commits
Author: stefanp Date: Mon Jul 9 13:09:52 2018 New Revision: 336596 URL: http://llvm.org/viewvc/llvm-project?rev=336596&view=rev Log: [Power9] [CLANG] Add __float128 support for trunc to double round to odd Add support for this builtin: double builtin_truncf128_round_to_odd(float128) Differentia

Re: r336219 - Fix crash in clang.

2018-07-09 Thread David Blaikie via cfe-commits
Did this fail on an existing regression test, or is there a need for more test coverage? (guessing it failed on existing tests) Also, is the makeArrayRef necessary? Looks like if the original code compiled (implicitly converting from vector to ArrayRef) then the new code wouldn't need a makeArrayR

[PATCH] D48506: Fix for Crash in nested name specifier decltype

2018-07-09 Thread Balaji Iyer via Phabricator via cfe-commits
bviyer added a comment. Herald added a subscriber: dexonsmith. Ping! Repository: rC Clang https://reviews.llvm.org/D48506 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D49099: Remove qualtype qualifier in coroutine error to prevent assert in debug

2018-07-09 Thread Tanoy Sinha via Phabricator via cfe-commits
tks2103 created this revision. tks2103 added reviewers: modocache, GorNishanov. A forward-declared coroutine_traits should trip an error; we need a complete type. Unfortunately, in debug mode only, we trip an assert when attempting to provide the fully qualified type for the error message. If you

Re: r336219 - Fix crash in clang.

2018-07-09 Thread Zachary Turner via cfe-commits
makeArrayRef() isn't necessary, but when I was first looking at this I had to stare at the code for a bit to see that there was an implicit conversion happening. So I put the makeArrayRef() just for the benefit of the person reading the code. But no, it's not necessary. This did not fail on exis

Re: r336219 - Fix crash in clang.

2018-07-09 Thread David Blaikie via cfe-commits
On Mon, Jul 9, 2018 at 1:52 PM Zachary Turner wrote: > makeArrayRef() isn't necessary, but when I was first looking at this I had > to stare at the code for a bit to see that there was an implicit conversion > happening. So I put the makeArrayRef() just for the benefit of the person > reading th

[PATCH] D49100: Inline DeclarationNameInfo::getLocEnd into callers

2018-07-09 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: rsmith. Herald added a subscriber: cfe-commits. Note that CXXDependentScopeMemberExpr uses getEndLoc, not getLocEnd, unlike UnresolvedMemberExpr and UnresolvedLookupExpr (which are changed by this commit). Repository: rC Clang https:/

[PATCH] D48506: Fix for Crash in nested name specifier decltype

2018-07-09 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington added a comment. Hi Balaji, thanks for working on this! Comment at: lib/Sema/SemaCXXScopeSpec.cpp:849-850 QualType T = BuildDecltypeType(DS.getRepAsExpr(), DS.getTypeSpecTypeLoc()); + if (T.getTypePtrOrNull() == nullptr) + return true; if (!T->isDepe

[PATCH] D49054: [MinGW] Treat any -lucrt* as replacing -lmsvcrt

2018-07-09 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai accepted this revision. smeenai added a comment. This revision is now accepted and ready to land. LGTM Repository: rC Clang https://reviews.llvm.org/D49054 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-

r336604 - Added -fcrash-diagnostics-dir flag

2018-07-09 Thread Bob Haarman via cfe-commits
Author: inglorion Date: Mon Jul 9 14:07:20 2018 New Revision: 336604 URL: http://llvm.org/viewvc/llvm-project?rev=336604&view=rev Log: Added -fcrash-diagnostics-dir flag Summary: New flag causes crash reports to be written in the specified directory rather than the temp directory. Patch by Chij

[PATCH] D48601: Added -fcrash-diagnostics-dir flag

2018-07-09 Thread Bob Haarman via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL336604: Added -fcrash-diagnostics-dir flag (authored by inglorion, committed by ). Changed prior to commit: https://reviews.llvm.org/D48601?vs=153773&id=154695#toc Repository: rL LLVM https://review

[PATCH] D49059: [MinGW] Skip adding default win32 api libraries if -lwindowsapp is specified

2018-07-09 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai accepted this revision. smeenai added a comment. This revision is now accepted and ready to land. LGTM, particularly given r314138. There are other umbrella libraries as well, e.g. OneCore and OneCoreUAP. Do you care about those as well or just WindowsApp? Comment at:

[PATCH] D49059: [MinGW] Skip adding default win32 api libraries if -lwindowsapp is specified

2018-07-09 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added inline comments. Comment at: test/Driver/mingw-windowsapp.c:5-6 +// CHECK_DEFAULT: "-lmsvcrt" "-ladvapi32" "-lshell32" "-luser32" "-lkernel32" "-lmingw32" +// CHECK_WINDOWSAPP: "-lwindowsapp" "-lmingw32" +// CHECK_WINDOWSAPP-SAME: "-lmsvcrt" "-lmingw32" ---

[PATCH] D48266: [Driver] Add -fno-digraphs

2018-07-09 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: include/clang/Driver/Options.td:1337-1340 +def fdigraphs : Flag<["-"], "fdigraphs">, Group, Flags<[CC1Option]>, + HelpText<"Enable alternative token representations '<:', ':>', '<%', '%>', '%:' (default)">; +def fno_digraphs : Flag<["-"

[PATCH] D41458: [libc++][C++17] Elementary string conversions for integral types

2018-07-09 Thread Zhihao Yuan via Phabricator via cfe-commits
lichray added inline comments. Comment at: test/support/charconv_test_helpers.h:24 + +template +constexpr auto mclow.lists wrote: > If this is supposed to be a C++17 or later header (and I'm pretty sure it > is), you should add a `static_assert(TEST_STD_VER > 1

[PATCH] D48892: [libc++] Replace uses of _LIBCPP_ALWAYS_INLINE by _LIBCPP_INLINE_VISIBILITY

2018-07-09 Thread Louis Dionne via Phabricator via cfe-commits
ldionne added a comment. I've now managed to run the `check-cxx-abilist` test on my machine and it passes. I'd like to commit this again, @EricWF am I good to go? Repository: rL LLVM https://reviews.llvm.org/D48892 ___ cfe-commits mailing list c

[PATCH] D48894: [AST] Rename some Redeclarable functions to reduce confusion

2018-07-09 Thread Fangrui Song via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC336605: [AST] Rename some Redeclarable functions to reduce confusion (authored by MaskRay, committed by ). Changed prior to commit: https://reviews.llvm.org/D48894?vs=154044&id=154698#toc Repository:

r336605 - [AST] Rename some Redeclarable functions to reduce confusion

2018-07-09 Thread Fangrui Song via cfe-commits
Author: maskray Date: Mon Jul 9 14:31:20 2018 New Revision: 336605 URL: http://llvm.org/viewvc/llvm-project?rev=336605&view=rev Log: [AST] Rename some Redeclarable functions to reduce confusion Reviewers: rsmith, akyrtzi Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/

[PATCH] D49059: [MinGW] Skip adding default win32 api libraries if -lwindowsapp is specified

2018-07-09 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added a comment. In https://reviews.llvm.org/D49059#1156453, @smeenai wrote: > LGTM, particularly given r314138. > > There are other umbrella libraries as well, e.g. OneCore and OneCoreUAP. Do > you care about those as well or just WindowsApp? I guess we would care, but there's nothin

[PATCH] D49059: [MinGW] Skip adding default win32 api libraries if -lwindowsapp is specified

2018-07-09 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added inline comments. Comment at: test/Driver/mingw-windowsapp.c:5-6 +// CHECK_DEFAULT: "-lmsvcrt" "-ladvapi32" "-lshell32" "-luser32" "-lkernel32" "-lmingw32" +// CHECK_WINDOWSAPP: "-lwindowsapp" "-lmingw32" +// CHECK_WINDOWSAPP-SAME: "-lmsvcrt" "-lmingw32" ---

Re: r336475 - Check returned type is valid before using it.

2018-07-09 Thread David Blaikie via cfe-commits
Thanks for the fix! Though maybe this isn't the best diagnostic experience - given that 'bar' isn't technically an overloaded function, but is a function template - worth doing something more precise here? (maybe not) Wonder if there's similar handling for other diagnostic cases that could be use

[PATCH] D45712: Diagnose invalid cv-qualifiers for friend decls.

2018-07-09 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. I thought the template case wasn't using the same codepath, but apparently I was just confusing myself. The exact form "template friend class Y;" triggers an early out in Sema::ActOnFriendTypeDecl, so my code wasn't getting hit. I'll revise accordingly. Repository:

[PATCH] D48506: Fix for Crash in nested name specifier decltype

2018-07-09 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington added a subscriber: rtrieu. erik.pilkington added a comment. Looks like @rtrieu beat you to the punch in r336475! Presumably thats why the test case wasn't failing on TOT. Since this is already fixed, you should mark this revision as abandoned. Repository: rC Clang https://r

r336606 - [Index] Add index::IndexingOptions::IndexImplicitInstantiation

2018-07-09 Thread Fangrui Song via cfe-commits
Author: maskray Date: Mon Jul 9 14:49:06 2018 New Revision: 336606 URL: http://llvm.org/viewvc/llvm-project?rev=336606&view=rev Log: [Index] Add index::IndexingOptions::IndexImplicitInstantiation Summary: With IndexImplicitInstantiation=true, the following case records an occurrence of B::bar i

[PATCH] D49002: [Index] Add index::IndexingOptions::IndexImplicitInstantiation

2018-07-09 Thread Fangrui Song via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL336606: [Index] Add index::IndexingOptions::IndexImplicitInstantiation (authored by MaskRay, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D

[PATCH] D45712: Diagnose invalid cv-qualifiers for friend decls.

2018-07-09 Thread Eli Friedman via Phabricator via cfe-commits
efriedma updated this revision to Diff 154707. efriedma edited the summary of this revision. efriedma added a comment. Move declspec checks before call to GetTypeForDeclarator, since it can fail for class templates. Repository: rC Clang https://reviews.llvm.org/D45712 Files: lib/Sema/Sema

r336610 - Rename function calls missed in r336605

2018-07-09 Thread Richard Trieu via cfe-commits
Author: rtrieu Date: Mon Jul 9 15:09:33 2018 New Revision: 336610 URL: http://llvm.org/viewvc/llvm-project?rev=336610&view=rev Log: Rename function calls missed in r336605 NextIsLatest -> isFirst Modified: cfe/trunk/include/clang/AST/Decl.h Modified: cfe/trunk/include/clang/AST/Decl.h URL:

[PATCH] D49074: [Analyzer] [WIP] Basic support for multiplication and division in the constraint manager

2018-07-09 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: test/Analysis/constraint_manager_scale.c:78 + assert(x * 2 < 8); + clang_analyzer_eval(x < 4); // expected-warning{{TRUE}} + clang_analyzer_eval(x < 2); // expected-warning{{UNKNOWN}} If `int` is 32-bit and `x` equal to 2

[PATCH] D49074: [Analyzer] [WIP] Basic support for multiplication and division in the constraint manager

2018-07-09 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. The overall point is that writing this kind of code is *extremely* error-prone. We are actually considering going in a different direction and doing a rollback for the previous rearrangement patches due to some issues. Could you see whether Z3 visitor would meet

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

2018-07-09 Thread Momchil Velikov via Phabricator via cfe-commits
chill added a comment. Ping? https://reviews.llvm.org/D46013 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D45179: [libc++] Add _LIBCPP_ENABLE_NODISCARD and _LIBCPP_NODISCARD_EXT to allow pre-C++2a [[nodiscard]]

2018-07-09 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF updated this revision to Diff 154724. EricWF retitled this revision from "[libc++] Add _LIBCPP_FORCE_NODISCARD define to force-enable nodiscard in pre-C++17" to "[libc++] Add _LIBCPP_ENABLE_NODISCARD and _LIBCPP_NODISCARD_EXT to allow pre-C++2a [[nodiscard]]". EricWF edited the summary of

[PATCH] D45179: [libc++] Add _LIBCPP_ENABLE_NODISCARD and _LIBCPP_NODISCARD_EXT to allow pre-C++2a [[nodiscard]]

2018-07-09 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. A couple other notes: - Add an application of `_LIBCPP_NODISCARD_EXT` to `get_temporary_buffer` to demonstrate usage. https://reviews.llvm.org/D45179 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm

[PATCH] D48506: Fix for Crash in nested name specifier decltype

2018-07-09 Thread Balaji Iyer via Phabricator via cfe-commits
bviyer abandoned this revision. bviyer added a comment. Thank you Eric. I abandoned the revision as you suggested. Repository: rC Clang https://reviews.llvm.org/D48506 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/

[libcxx] r336618 - [test] two small cleanups:

2018-07-09 Thread Casey Carter via cfe-commits
Author: caseycarter Date: Mon Jul 9 16:45:09 2018 New Revision: 336618 URL: http://llvm.org/viewvc/llvm-project?rev=336618&view=rev Log: [test] two small cleanups: * Remove unused type from is_assignable.pass.cpp * Don't specialize `common_type<::X>` in common_type.pass.cpp, which violates the

[PATCH] D49112: [Sema] Implement -Wmemset-transposed-args

2018-07-09 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington created this revision. erik.pilkington added reviewers: rsmith, aaron.ballman, arphaman. Herald added a subscriber: dexonsmith. This warning tries to catch programs that incorrectly call memset with the second and third arguments transposed, ie `memset(ary, sizeof(ary), 0)` instea

r336622 - [X86] Add __builtin_ia32_selectss_128 and __builtin_ia32_selectsd_128 that is suitable for use in scalar mask intrinsics.

2018-07-09 Thread Craig Topper via cfe-commits
Author: ctopper Date: Mon Jul 9 17:37:25 2018 New Revision: 336622 URL: http://llvm.org/viewvc/llvm-project?rev=336622&view=rev Log: [X86] Add __builtin_ia32_selectss_128 and __builtin_ia32_selectsd_128 that is suitable for use in scalar mask intrinsics. This will convert the i8 mask argument t

[PATCH] D49114: Add a clang-tidy check for "magic numbers"

2018-07-09 Thread Florin Iucha via Phabricator via cfe-commits
0x8000- created this revision. 0x8000- added reviewers: Wizard, aaron.ballman, alexfh, hokein. Herald added subscribers: cfe-commits, mgorny. Add a clang-tidy check for "magic numbers", integers and floating point values embedded in the code instead of using symbols or constants. Bad exa

[PATCH] D49112: [Sema] Implement -Wmemset-transposed-args

2018-07-09 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone added inline comments. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:662 +def note_suspicious_sizeof_memset_silence : Note< + "%select{parenthesize the third argument|cast the second argument to 'int'}0 to silence">; + If it were my c

r336628 - [X86] Remove custom handling for __builtin_ia32_divss_round_mask and __builtin_ia32_divsd_round_mask.

2018-07-09 Thread Craig Topper via cfe-commits
Author: ctopper Date: Mon Jul 9 17:50:03 2018 New Revision: 336628 URL: http://llvm.org/viewvc/llvm-project?rev=336628&view=rev Log: [X86] Remove custom handling for __builtin_ia32_divss_round_mask and __builtin_ia32_divsd_round_mask. Modified: cfe/trunk/lib/CodeGen/CGBuiltin.cpp Modified:

r336629 - Fix parsing of privacy annotations in os_log format strings.

2018-07-09 Thread Akira Hatanaka via cfe-commits
Author: ahatanak Date: Mon Jul 9 17:50:25 2018 New Revision: 336629 URL: http://llvm.org/viewvc/llvm-project?rev=336629&view=rev Log: Fix parsing of privacy annotations in os_log format strings. Privacy annotations shouldn't have to appear in the first comma-delimited string in order to be recog

r336630 - Update crash diagnostics test to avoid attempting to write into various

2018-07-09 Thread Eric Christopher via cfe-commits
Author: echristo Date: Mon Jul 9 18:01:38 2018 New Revision: 336630 URL: http://llvm.org/viewvc/llvm-project?rev=336630&view=rev Log: Update crash diagnostics test to avoid attempting to write into various directories if possible and to not require %t to have "Output" in the name. Modified:

[PATCH] D49114: Add a clang-tidy check for "magic numbers"

2018-07-09 Thread Florin Iucha via Phabricator via cfe-commits
0x8000- added a comment. Perhaps M_PI wasn't the best example, as its value won't change soon, but other numbers should be defined in relation to constants. Also I have seen coding guidelines suggesting "100" is grandfathered due to 100% calculations. 2 and 10 due to logarithms, etc. Not su

r336632 - [ODRHash] Merge the two function hashes into one.

2018-07-09 Thread Richard Trieu via cfe-commits
Author: rtrieu Date: Mon Jul 9 18:40:50 2018 New Revision: 336632 URL: http://llvm.org/viewvc/llvm-project?rev=336632&view=rev Log: [ODRHash] Merge the two function hashes into one. Functions that are a sub-Decl of a record were hashed differently than other functions. This change keeps the Add

[PATCH] D49114: Add a clang-tidy check for "magic numbers"

2018-07-09 Thread Hal Finkel via Phabricator via cfe-commits
hfinkel added a comment. > This version detects and report integers only. If there is interest of > merging the tool I can add the functionality for floats as well. FWIW: I think that the FP check would be interesting. > Also I have seen coding guidelines suggesting "100" is grandfathered due t

[PATCH] D49114: Add a clang-tidy check for "magic numbers"

2018-07-09 Thread Florin Iucha via Phabricator via cfe-commits
0x8000- added a comment. In https://reviews.llvm.org/D49114#1156835, @hfinkel wrote: > I suspect that the check will be very noisy for powers of 2 and 10 that are > used as multiplicands. You might wish to exclude those. Good point. > Also, what happens for enums? Especially when initiali

[PATCH] D49118: [libc++] P0898R3 1 of 12: changes to common_type; implement common_reference

2018-07-09 Thread Casey Carter via Phabricator via cfe-commits
CaseyCarter created this revision. CaseyCarter added reviewers: mclow.lists, EricWF. I'm breaking this up into independent bite-sized ~500 line reviews instead of a single 5200 line monster in hopes that we can turnaround changes quickly. This first piece implements the new bullet for `common_ty

[PATCH] D49119: [Sema][ObjC] Issue a warning when a method declared in a protocol is non-escaping but the corresponding method in the implementation is escaping.

2018-07-09 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak created this revision. ahatanak added reviewers: arphaman, vsapsai, dcoughlin. ahatanak added a project: clang. Herald added a subscriber: dexonsmith. This patch makes Sema issue a warning when there is an extension that conforms to a protocol that declares a non-escaping method and the

[PATCH] D49120: [libc++] P0898R3 2 of 12: Implement header

2018-07-09 Thread Casey Carter via Phabricator via cfe-commits
CaseyCarter created this revision. CaseyCarter added reviewers: mclow.lists, EricWF. Herald added subscribers: christof, modocache, mgorny. Piece number two contains the header, a bunch of "add a new header" changes, and LIT config to grok tests that need concepts (Thanks to @EricWF's similar ha

[PATCH] D49114: Add a clang-tidy check for "magic numbers"

2018-07-09 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone added a comment. The cult of "no magic numbers" is horrible and we should be trying to //deprogram// its adherents, not create a whole new generation of them. I would be happy if this clang-tidy patch were quickly abandoned. //But//, it's just a clang-tidy check — it's easy for peop

[PATCH] D49122: [libc++] P0898R3 3 of 12: Tests for Same, DerivedFrom, ConvertibleTo, and CommonReference

2018-07-09 Thread Casey Carter via Phabricator via cfe-commits
CaseyCarter created this revision. CaseyCarter added reviewers: mclow.lists, EricWF. Like the title says, the first batch of tests. I'll stop at three chunks for now - that should be enough to get some reviewer feedback and keep me busy making changes. https://reviews.llvm.org/D49122 Files:

r336634 - [Sema] Fix a structured binding typo correction bug

2018-07-09 Thread Erik Pilkington via cfe-commits
Author: epilk Date: Mon Jul 9 19:15:07 2018 New Revision: 336634 URL: http://llvm.org/viewvc/llvm-project?rev=336634&view=rev Log: [Sema] Fix a structured binding typo correction bug BindingDecls have null type until their initializer is processed, so we can't assume that a correction candidate

[PATCH] D49120: [libc++] P0898R3 2 of 12: Implement header

2018-07-09 Thread Casey Carter via Phabricator via cfe-commits
CaseyCarter added inline comments. Comment at: include/concepts:193 +#endif +#if 0 // FIXME: File LWG issue +requires(_From (&_Fn)()) { static_cast<_To>(_Fn()); }; I suppose it would have been a good idea to fix this before submitting the patch for review -

[PATCH] D49120: [libc++] P0898R3 2 of 12: Implement header

2018-07-09 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone added inline comments. Comment at: include/concepts:175 +template +_LIBCPP_CONCEPT_DECL Same = __same_impl<_Tp, _Up> && __same_impl<_Up, _Tp>; + Peanut gallery asks: From lines 166-171 it looks awfully like `__same_impl<_Tp, _Up>` is true if and onl

[PATCH] D49114: Add a clang-tidy check for "magic numbers"

2018-07-09 Thread Florin Iucha via Phabricator via cfe-commits
0x8000- added a comment. In https://reviews.llvm.org/D49114#1156878, @Quuxplusone wrote: > The cult of "no magic numbers" is horrible and we should be trying to > //deprogram// its adherents, not create a whole new generation of them. I > would be happy if this clang-tidy patch were quickly

[PATCH] D49114: Add a clang-tidy check for "magic numbers"

2018-07-09 Thread Florin Iucha via Phabricator via cfe-commits
0x8000- added inline comments. Comment at: test/clang-tidy/readability-magic-numbers.cpp:38 +public: + TwoIntContainer(int val) : anotherMember(val * val), yetAnotherMember(2), anotherConstant(val + val) {} + // CHECK-MESSAGES: :[[@LINE-1]]:73: warning: magic number intege

[PATCH] D49120: [libc++] P0898R3 2 of 12: Implement header

2018-07-09 Thread Casey Carter via Phabricator via cfe-commits
CaseyCarter added inline comments. Comment at: include/concepts:175 +template +_LIBCPP_CONCEPT_DECL Same = __same_impl<_Tp, _Up> && __same_impl<_Up, _Tp>; + Quuxplusone wrote: > Peanut gallery asks: From lines 166-171 it looks awfully like > `__same_impl<_Tp, _

Re: r336590 - [libclang] evalute compound statement cursors before trying to evaluate

2018-07-09 Thread Vlad Tsyrklevich via cfe-commits
The ASan bot is failing with a LeakSanitizer failure that appears related to one of your libclang changes: http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-bootstrap/builds/6282/steps/check-clang%20asan/logs/stdio Direct leak of 24 byte(s) in 1 object(s) allocated from: #0 0x52c638 in

[PATCH] D41458: [libc++][C++17] Elementary string conversions for integral types

2018-07-09 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists added inline comments. Comment at: .gitignore:7 *.so +*.core + I'm pretty sure this file doesn't belong in this diff. Comment at: include/charconv:89 +_LIBCPP_BEGIN_NAMESPACE_STD + +enum class _LIBCPP_ENUM_VIS chars_format

[PATCH] D47757: [Sema] Produce diagnostics when unavailable aligned allocation/deallocation functions are called

2018-07-09 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. Herald added a subscriber: dexonsmith. ping Repository: rC Clang https://reviews.llvm.org/D47757 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D22391: [Sema] Add warning for implicitly casting a null constant to a non null pointer type

2018-07-09 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. Herald added a subscriber: dexonsmith. ping Repository: rC Clang https://reviews.llvm.org/D22391 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libcxx] r336636 - Add new string benchmarks

2018-07-09 Thread Eric Fiselier via cfe-commits
Author: ericwf Date: Mon Jul 9 21:11:22 2018 New Revision: 336636 URL: http://llvm.org/viewvc/llvm-project?rev=336636&view=rev Log: Add new string benchmarks Modified: libcxx/trunk/benchmarks/string.bench.cpp Modified: libcxx/trunk/benchmarks/string.bench.cpp URL: http://llvm.org/viewvc/ll

r336637 - [X86] Use masked the masked scalar fma builtins to implement the default rounding version of the fma intrinsics.

2018-07-09 Thread Craig Topper via cfe-commits
Author: ctopper Date: Mon Jul 9 21:38:29 2018 New Revision: 336637 URL: http://llvm.org/viewvc/llvm-project?rev=336637&view=rev Log: [X86] Use masked the masked scalar fma builtins to implement the default rounding version of the fma intrinsics. The rounding mode is checked in CGBuiltin.cpp to

[PATCH] D49058: [analyzer] Move DanglingInternalBufferChecker out of alpha

2018-07-09 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. Don't you need to edit the tests as well? Repository: rC Clang https://reviews.llvm.org/D49058 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D49120: [libc++] P0898R3 2 of 12: Implement header

2018-07-09 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone added inline comments. Comment at: include/concepts:175 +template +_LIBCPP_CONCEPT_DECL Same = __same_impl<_Tp, _Up> && __same_impl<_Up, _Tp>; + CaseyCarter wrote: > Quuxplusone wrote: > > Peanut gallery asks: From lines 166-171 it looks awfully like

<    1   2