[PATCH] D31839: make -Winteger-overflow find overflows in function arguments

2017-04-11 Thread Nick Lewycky via Phabricator via cfe-commits
nlewycky added a comment. In https://reviews.llvm.org/D31839#724551, @ahatanak wrote: > OK, thanks for looking into it. Warnings for ObjCMessageExpr can probably be > implemented in a separate patch. > > It looks like clang still doesn't issue overflow warnings when the called > functions have

r300027 - [Modules] Remove darwin specific code to check for SystemVersion.plist

2017-04-11 Thread Bruno Cardoso Lopes via cfe-commits
Author: bruno Date: Tue Apr 11 23:49:00 2017 New Revision: 300027 URL: http://llvm.org/viewvc/llvm-project?rev=300027=rev Log: [Modules] Remove darwin specific code to check for SystemVersion.plist This isn't need anymore and modules options -fbuild-session-file and

[PATCH] D31839: make -Winteger-overflow find overflows in function arguments

2017-04-11 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. OK, thanks for looking into it. Warnings for ObjCMessageExpr can probably be implemented in a separate patch. It looks like clang still doesn't issue overflow warnings when the called functions have a void return. Should we try to fix it in this patch too? void

[PATCH] D30954: Modules: Simulate diagnostic settings for implicit modules

2017-04-11 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith closed this revision. dexonsmith marked an inline comment as done. dexonsmith added a comment. And committed in: r297770 c0c27f3 Modules: Optimize bitcode encoding of diagnostic state r300021 5e5be8e Serialization: Skip check in WritePragmaDiagnosticMappings, NFC r300024 91f051f

r300025 - Serialization: Simulate -Werror settings in implicit modules

2017-04-11 Thread Duncan P. N. Exon Smith via cfe-commits
Author: dexonsmith Date: Tue Apr 11 22:58:58 2017 New Revision: 300025 URL: http://llvm.org/viewvc/llvm-project?rev=300025=rev Log: Serialization: Simulate -Werror settings in implicit modules r293123 started serializing diagnostic pragma state for modules. This makes the serialization work

r300024 - Serialization: Emit the final diagnostic state last, almost NFC

2017-04-11 Thread Duncan P. N. Exon Smith via cfe-commits
Author: dexonsmith Date: Tue Apr 11 22:45:32 2017 New Revision: 300024 URL: http://llvm.org/viewvc/llvm-project?rev=300024=rev Log: Serialization: Emit the final diagnostic state last, almost NFC Emit the final diagnostic state last to match source order. This also prepares for a follow-up

r300021 - Serialization: Skip check in WritePragmaDiagnosticMappings, NFC

2017-04-11 Thread Duncan P. N. Exon Smith via cfe-commits
Author: dexonsmith Date: Tue Apr 11 21:31:17 2017 New Revision: 300021 URL: http://llvm.org/viewvc/llvm-project?rev=300021=rev Log: Serialization: Skip check in WritePragmaDiagnosticMappings, NFC The record is never empty, since we always serialize the initial state. Skip the check. Modified:

[libunwind] r300020 - Reland "[CMake][libunwind] Use -nodefaultlibs for CMake checks"

2017-04-11 Thread Petr Hosek via cfe-commits
Author: phosek Date: Tue Apr 11 21:28:07 2017 New Revision: 300020 URL: http://llvm.org/viewvc/llvm-project?rev=300020=rev Log: Reland "[CMake][libunwind] Use -nodefaultlibs for CMake checks" This is a reland of commit r299796. Turned out that we need gcc_s or compiler-rt on ARM when checking

Re: r300001 - Revert r298824 & r298816, recommit r298742 & r298754

2017-04-11 Thread Richard Smith via cfe-commits
Either this or your other ODR hash change seems to have broken the modules buildbot: http://lab.llvm.org:8011/builders/clang-x86_64-linux-selfhost-modules-2/builds/6274/steps/compile.llvm.stage2/logs/stdio On 11 April 2017 at 15:32, Richard Trieu via cfe-commits < cfe-commits@lists.llvm.org>

r300014 - [IR] Add AttributeSet to hide AttributeSetNode* again, NFC

2017-04-11 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Tue Apr 11 19:38:00 2017 New Revision: 300014 URL: http://llvm.org/viewvc/llvm-project?rev=300014=rev Log: [IR] Add AttributeSet to hide AttributeSetNode* again, NFC Summary: For now, it just wraps AttributeSetNode*. Eventually, it will hold AvailableAttrs as an inline bitset,

[PATCH] D31966: [libcxx] [test] Avoid Clang's -Wunused-const-variable in is_constructible.pass.cpp.

2017-04-11 Thread Stephan T. Lavavej via Phabricator via cfe-commits
STL_MSFT created this revision. [libcxx] [test] Avoid Clang's -Wunused-const-variable in is_constructible.pass.cpp. This happens when using Clang with MSVC's STL, so there are no actual uses of this variable. https://reviews.llvm.org/D31966 Files:

[PATCH] D31839: make -Winteger-overflow find overflows in function arguments

2017-04-11 Thread Nick Lewycky via Phabricator via cfe-commits
nlewycky added a comment. In https://reviews.llvm.org/D31839#722763, @ahatanak wrote: > Is it possible to fix ObjCMessageExpr too while you are in here? I looked into this, but it turns out to be different enough to belong in a separate patch. An ObjCMessageExpr has void type which means that

[libcxx] r300009 - Add some FAIL constexpr tests for optional's copy/move ctors.

2017-04-11 Thread Marshall Clow via cfe-commits
Author: marshall Date: Tue Apr 11 19:07:29 2017 New Revision: 39 URL: http://llvm.org/viewvc/llvm-project?rev=39=rev Log: Add some FAIL constexpr tests for optional's copy/move ctors. Added: libcxx/trunk/test/std/utilities/optional/optional.object/optional.object.ctor/copy.fail.cpp

r300006 - Silence unused variable warning in release builds.

2017-04-11 Thread Benjamin Kramer via cfe-commits
Author: d0k Date: Tue Apr 11 18:06:49 2017 New Revision: 36 URL: http://llvm.org/viewvc/llvm-project?rev=36=rev Log: Silence unused variable warning in release builds. Modified: cfe/trunk/lib/AST/ExternalASTMerger.cpp Modified: cfe/trunk/lib/AST/ExternalASTMerger.cpp URL:

Re: r298824 - Revert r298742 "[ODRHash] Add error messages for mismatched parameters in methods."

2017-04-11 Thread Richard Trieu via cfe-commits
r299989 should prevent the build breakages. I have recommited my changes in r31. On Sun, Mar 26, 2017 at 2:39 PM, Vassil Vassilev via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: vvassilev > Date: Sun Mar 26 16:39:16 2017 > New Revision: 298824 > > URL:

Re: r298816 - Revert 298754 and 298742.

2017-04-11 Thread Richard Trieu via cfe-commits
r299989 should prevent the build breakages. I have recommited my changes in r31. On Sun, Mar 26, 2017 at 11:32 AM, Vassil Vassilev via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: vvassilev > Date: Sun Mar 26 13:32:53 2017 > New Revision: 298816 > > URL:

r300001 - Revert r298824 & r298816, recommit r298742 & r298754

2017-04-11 Thread Richard Trieu via cfe-commits
Author: rtrieu Date: Tue Apr 11 17:32:03 2017 New Revision: 31 URL: http://llvm.org/viewvc/llvm-project?rev=31=rev Log: Revert r298824 & r298816, recommit r298742 & r298754 r299989 fixes the underlying issue by waiting long enough to late parsed arguments to be processed before doing an

[PATCH] D7573: [libc++] Fix PR20084 - std::is_function<void() const> failed.

2017-04-11 Thread Eric Niebler via Phabricator via cfe-commits
eric_niebler added a comment. I just ran into this problem while trying to get range-v3 working on clang-3.6. This `is_function` implementation //probably// instantiates fewer templates than the version currently shipping with libc++. Disclaimer: I haven't tested it exhaustively yet.

[PATCH] D31673: Allow casting C pointers declared using extern "C" to ObjC pointer types

2017-04-11 Thread Akira Hatanaka via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL22: [Sema][ObjC] Check whether a variable has a definition, rather than (authored by ahatanak). Changed prior to commit: https://reviews.llvm.org/D31673?vs=94686=94899#toc Repository: rL LLVM

r299992 - [Sema][ObjC] Check whether a variable has a definition, rather than

2017-04-11 Thread Akira Hatanaka via cfe-commits
Author: ahatanak Date: Tue Apr 11 17:01:33 2017 New Revision: 22 URL: http://llvm.org/viewvc/llvm-project?rev=22=rev Log: [Sema][ObjC] Check whether a variable has a definition, rather than checking its storage class, when determining whether casting a C pointer to an ObjC pointer is

r299989 - [ODRHash] Improve handling of hash values

2017-04-11 Thread Richard Trieu via cfe-commits
Author: rtrieu Date: Tue Apr 11 16:31:00 2017 New Revision: 299989 URL: http://llvm.org/viewvc/llvm-project?rev=299989=rev Log: [ODRHash] Improve handling of hash values Calculating the hash in Sema::ActOnTagFinishDefinition could happen before all sub-Decls were parsed or processed, which would

r299987 - Modular Codegen: Support homing debug info for types in modular objects

2017-04-11 Thread David Blaikie via cfe-commits
Author: dblaikie Date: Tue Apr 11 16:13:37 2017 New Revision: 299987 URL: http://llvm.org/viewvc/llvm-project?rev=299987=rev Log: Modular Codegen: Support homing debug info for types in modular objects Matching the function-homing support for modular codegen. Any type implicitly (implicit

r299983 - [ExternalASTMerger] Removed a move constructor to address MSVC build failure

2017-04-11 Thread Sean Callanan via cfe-commits
Author: spyffe Date: Tue Apr 11 15:51:21 2017 New Revision: 299983 URL: http://llvm.org/viewvc/llvm-project?rev=299983=rev Log: [ExternalASTMerger] Removed a move constructor to address MSVC build failure Modified: cfe/trunk/lib/AST/ExternalASTMerger.cpp Modified:

[PATCH] D31757: [clang-tidy] Add a clang-tidy check for possible inefficient vector operations

2017-04-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/performance/InefficientVectorOperationCheck.cpp:53-54 +PushBackCall)), + hasParent(compoundStmt(unless(has(ReserveCall)), + has(VectorVarDefStmt +

[PATCH] D29901: Modular Codegen: Add/use a bit in serialized function definitions to track whether they are the subject of modular codegen

2017-04-11 Thread David Blaikie via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL299982: Modular Codegen: Add/use a bit in serialized function definitions to track… (authored by dblaikie). Changed prior to commit: https://reviews.llvm.org/D29901?vs=91193=94886#toc Repository: rL

r299982 - Modular Codegen: Add/use a bit in serialized function definitions to track whether they are the subject of modular codegen

2017-04-11 Thread David Blaikie via cfe-commits
Author: dblaikie Date: Tue Apr 11 15:46:34 2017 New Revision: 299982 URL: http://llvm.org/viewvc/llvm-project?rev=299982=rev Log: Modular Codegen: Add/use a bit in serialized function definitions to track whether they are the subject of modular codegen Some decls are created not where they are

[PATCH] D31440: PR32382: Adapt to LLVM changes in DIExpression.

2017-04-11 Thread Eric Christopher via Phabricator via cfe-commits
echristo requested changes to this revision. echristo added a comment. This revision now requires changes to proceed. Sounds like Dave is asking for changes so I'll put it down as Request Changes to get it out of my queue. :) https://reviews.llvm.org/D31440

[PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-04-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman closed this revision. aaron.ballman added a comment. Commit in r299981. https://reviews.llvm.org/D31153 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r299981 - Add const children() accessors to match the existing non-const children() accessors.

2017-04-11 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Tue Apr 11 15:21:30 2017 New Revision: 299981 URL: http://llvm.org/viewvc/llvm-project?rev=299981=rev Log: Add const children() accessors to match the existing non-const children() accessors. Modified: cfe/trunk/include/clang/AST/Expr.h

[PATCH] D30837: [libcxx] Support for shared_ptr<T()>

2017-04-11 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington added a comment. Ping! https://reviews.llvm.org/D30837 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread Richard Smith via cfe-commits
On 11 April 2017 at 08:35, Marshall Clow via Phabricator via cfe-commits < cfe-commits@lists.llvm.org> wrote: > mclow.lists added a comment. > > Complete reproducer: > > // Tested with with: clang++ -std=c++14 -Wunused-function > UnusedFVassily.cpp > // > // UnusedFVassily.cpp:8:39: warning:

[PATCH] D31692: [coroutines] Wrap the body of the coroutine in try-catch

2017-04-11 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov added inline comments. Comment at: lib/Sema/SemaCoroutine.cpp:977 + // Since the body of the coroutine will be wrapped in try-catch, it will + // be incompativle with SEH __try if present in a function. + if (!S.getLangOpts().Borland &&

r299977 - [ExternalASTMerger] Fix the MSVC build

2017-04-11 Thread Sean Callanan via cfe-commits
Author: spyffe Date: Tue Apr 11 14:50:37 2017 New Revision: 299977 URL: http://llvm.org/viewvc/llvm-project?rev=299977=rev Log: [ExternalASTMerger] Fix the MSVC build Modified: cfe/trunk/lib/AST/ExternalASTMerger.cpp Modified: cfe/trunk/lib/AST/ExternalASTMerger.cpp URL:

[PATCH] D31956: Implement (part of) LWG2857: `{variant, optional, any}::emplace` should return the constructed value

2017-04-11 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists created this revision. Implement the `optional` and `any` part of this issue. This changes the return type of these functions. https://reviews.llvm.org/D31956 Files: include/any include/optional test/std/utilities/any/any.class/any.modifiers/emplace.pass.cpp

[PATCH] D30435: [clang-import-test] Lookup inside entities

2017-04-11 Thread Sean Callanan via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL299976: [clang-import-test] Lookup inside contexts (authored by spyffe). Changed prior to commit: https://reviews.llvm.org/D30435?vs=93929=94875#toc Repository: rL LLVM

r299976 - [clang-import-test] Lookup inside contexts

2017-04-11 Thread Sean Callanan via cfe-commits
Author: spyffe Date: Tue Apr 11 14:33:35 2017 New Revision: 299976 URL: http://llvm.org/viewvc/llvm-project?rev=299976=rev Log: [clang-import-test] Lookup inside contexts clang-import-test has until now been only able to report top-level Decls. This is clearly insufficient; we should be able to

[PATCH] D29905: [OpenMP] Pass argument to device kernel by reference when map is used.

2017-04-11 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 94867. gtbercea added a comment. Refactor code. Repository: rL LLVM https://reviews.llvm.org/D29905 Files: lib/Sema/SemaOpenMP.cpp test/OpenMP/target_map_codegen.cpp Index: test/OpenMP/target_map_codegen.cpp

[PATCH] D27604: [Driver] Add compiler option to generate a reproducer

2017-04-11 Thread Richard Smith via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. LGTM with one change. Comment at: include/clang/Basic/DiagnosticDriverKinds.td:95 def err_drv_force_crash : Error< - "failing because environment variable '%0' is set">; + "failing because %select{environment

[PATCH] D31757: [clang-tidy] Add a clang-tidy check for possible inefficient vector operations

2017-04-11 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tidy/performance/InefficientVectorOperationCheck.cpp:53-54 +PushBackCall)), + hasParent(compoundStmt(unless(has(ReserveCall)), + has(VectorVarDefStmt +

[PATCH] D31781: [Modules] Allow local submodule visibility without c++

2017-04-11 Thread Richard Smith via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. This revision is now accepted and ready to land. Can you also add a basic test that this works in C? Thanks! https://reviews.llvm.org/D31781 ___ cfe-commits mailing list

[PATCH] D29660: [OpenMP] Add flag for overwriting default PTX version for OpenMP targets

2017-04-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rL LLVM https://reviews.llvm.org/D29660 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

Re: [PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-04-11 Thread David Blaikie via cfe-commits
Ah - perhaps it'd be worth having a standalone forward declaration for clarity? I don't think I've seen this construct anywhere else in LLVM? But I could be wrong. On Tue, Apr 11, 2017 at 10:51 AM Aaron Ballman via Phabricator < revi...@reviews.llvm.org> wrote: > aaron.ballman added inline

[PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-04-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: include/clang/AST/StmtIterator.h:137 + inline friend StmtIterator + cast_away_const(const struct ConstStmtIterator ); }; dblaikie wrote: > the "struct" here is a bit atypical/should be removed The forward

Re: [PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-04-11 Thread David Blaikie via cfe-commits
On Tue, Apr 11, 2017 at 10:27 AM Aaron Ballman via Phabricator < revi...@reviews.llvm.org> wrote: > aaron.ballman added inline comments. > > > > Comment at: include/clang/AST/Expr.h:4025 >child_range children() { > +const_child_range CCR = const_cast *>(this)->children();

[PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-04-11 Thread David Blaikie via Phabricator via cfe-commits
dblaikie accepted this revision. dblaikie added a comment. This revision is now accepted and ready to land. Looks good to me - thanks! Comment at: include/clang/AST/StmtIterator.h:137 + inline friend StmtIterator + cast_away_const(const struct ConstStmtIterator ); };

[PATCH] D31646: [coroutines] Build GRO declaration and return GRO statement

2017-04-11 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov added a comment. Gentle ping. When all outstanding CRs are committed we will get 90% of working corouitnes in Clang https://reviews.llvm.org/D31646 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D31404: [OpenCL] Allow alloca return non-zero private pointer

2017-04-11 Thread Yaxun Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL299965: [OpenCL] Map default address space to alloca address space (authored by yaxunl). Changed prior to commit: https://reviews.llvm.org/D31404?vs=94399=94855#toc Repository: rL LLVM

r299965 - [OpenCL] Map default address space to alloca address space

2017-04-11 Thread Yaxun Liu via cfe-commits
Author: yaxunl Date: Tue Apr 11 12:24:23 2017 New Revision: 299965 URL: http://llvm.org/viewvc/llvm-project?rev=299965=rev Log: [OpenCL] Map default address space to alloca address space For OpenCL, the private address space qualifier is 0 in AST. Before this change, 0 address space qualifier

[PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-04-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman updated this revision to Diff 94852. aaron.ballman added a comment. Addressing review comments. https://reviews.llvm.org/D31153 Files: include/clang/AST/Expr.h include/clang/AST/StmtIterator.h lib/AST/Expr.cpp Index: lib/AST/Expr.cpp

[PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-04-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: include/clang/AST/Expr.h:4025 child_range children() { +const_child_range CCR = const_cast(this)->children(); +return child_range(cast_away_const(CCR.begin()), dblaikie wrote: > If this is adding const,

[libcxx] r299963 - Implement LWG#2873: 'Add noexcept to several shared_ptr related functions' This issue missed a couple, so I added those as well (see LWG#2942)

2017-04-11 Thread Marshall Clow via cfe-commits
Author: marshall Date: Tue Apr 11 12:08:53 2017 New Revision: 299963 URL: http://llvm.org/viewvc/llvm-project?rev=299963=rev Log: Implement LWG#2873: 'Add noexcept to several shared_ptr related functions' This issue missed a couple, so I added those as well (see LWG#2942) Modified:

[PATCH] D31167: Use FPContractModeKind universally

2017-04-11 Thread Adam Nemet via Phabricator via cfe-commits
anemet added inline comments. Comment at: cfe/trunk/include/clang/Basic/LangOptions.def:220 +/// \brief FP_CONTRACT mode (on/off/fast). +ENUM_LANGOPT(DefaultFPContractMode, FPContractModeKind, 2, FPC_Off, "FP contraction type") LANGOPT(NoBitFieldTypeAlign , 1, 0, "bit-field

[PATCH] D31167: Use FPContractModeKind universally

2017-04-11 Thread Hal Finkel via Phabricator via cfe-commits
hfinkel added inline comments. Comment at: cfe/trunk/include/clang/Basic/LangOptions.def:220 +/// \brief FP_CONTRACT mode (on/off/fast). +ENUM_LANGOPT(DefaultFPContractMode, FPContractModeKind, 2, FPC_Off, "FP contraction type") LANGOPT(NoBitFieldTypeAlign , 1, 0, "bit-field

r299962 - [ASTPrinter] Print nested name specifiers for out-of-line functions

2017-04-11 Thread Alex Lorenz via cfe-commits
Author: arphaman Date: Tue Apr 11 11:46:03 2017 New Revision: 299962 URL: http://llvm.org/viewvc/llvm-project?rev=299962=rev Log: [ASTPrinter] Print nested name specifiers for out-of-line functions rdar://31501863 Added: cfe/trunk/test/Misc/ast-print-out-of-line-func.cpp Modified:

[PATCH] D31167: Use FPContractModeKind universally

2017-04-11 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added inline comments. Comment at: cfe/trunk/include/clang/Basic/LangOptions.def:220 +/// \brief FP_CONTRACT mode (on/off/fast). +ENUM_LANGOPT(DefaultFPContractMode, FPContractModeKind, 2, FPC_Off, "FP contraction type") LANGOPT(NoBitFieldTypeAlign , 1, 0, "bit-field

[PATCH] D31167: Use FPContractModeKind universally

2017-04-11 Thread Hal Finkel via Phabricator via cfe-commits
hfinkel added inline comments. Comment at: cfe/trunk/include/clang/Basic/LangOptions.def:220 +/// \brief FP_CONTRACT mode (on/off/fast). +ENUM_LANGOPT(DefaultFPContractMode, FPContractModeKind, 2, FPC_Off, "FP contraction type") LANGOPT(NoBitFieldTypeAlign , 1, 0, "bit-field

[PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-04-11 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added inline comments. Comment at: include/clang/AST/Expr.h:4025 child_range children() { +const_child_range CCR = const_cast(this)->children(); +return child_range(cast_away_const(CCR.begin()), If this is adding const, can you use a weaker

[PATCH] D31860: Add more examples to clang tidy checkers

2017-04-11 Thread Sylvestre Ledru via Phabricator via cfe-commits
sylvestre.ledru added inline comments. Comment at: docs/clang-tidy/checks/misc-unused-parameters.rst:15 + + void a(int /*i*/) {} + alexfh wrote: > nit: two spaces before the comment. I believe it is the case ? I stole this from the unit test

[clang-tools-extra] r299961 - Add the definition of P in the clang tidy example

2017-04-11 Thread Sylvestre Ledru via cfe-commits
Author: sylvestre Date: Tue Apr 11 11:28:15 2017 New Revision: 299961 URL: http://llvm.org/viewvc/llvm-project?rev=299961=rev Log: Add the definition of P in the clang tidy example Modified: clang-tools-extra/trunk/docs/clang-tidy/checks/readability-uniqueptr-delete-release.rst Modified:

[PATCH] D31167: Use FPContractModeKind universally

2017-04-11 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added inline comments. Comment at: cfe/trunk/include/clang/Basic/LangOptions.def:220 +/// \brief FP_CONTRACT mode (on/off/fast). +ENUM_LANGOPT(DefaultFPContractMode, FPContractModeKind, 2, FPC_Off, "FP contraction type") LANGOPT(NoBitFieldTypeAlign , 1, 0, "bit-field

[PATCH] D29660: [OpenMP] Add flag for overwriting default PTX version for OpenMP targets

2017-04-11 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 94842. gtbercea added a comment. Run clang format. Repository: rL LLVM https://reviews.llvm.org/D29660 Files: include/clang/Driver/Options.td lib/Driver/ToolChains/Cuda.cpp test/Driver/openmp-offload.c Index: test/Driver/openmp-offload.c

[PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev added a comment. Reverted in r299956, due to failures like: template static int __test(...); template auto v = __test<_Tp>(0); https://reviews.llvm.org/D29877 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D29660: [OpenMP] Add flag for overwriting default PTX version for OpenMP targets

2017-04-11 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 94841. gtbercea added a comment. Refactor. Repository: rL LLVM https://reviews.llvm.org/D29660 Files: include/clang/Driver/Options.td lib/Driver/ToolChains/Cuda.cpp test/Driver/openmp-offload.c Index: test/Driver/openmp-offload.c

[PATCH] D30863: [clang-format] make docs/tools/{dump_format_style.py, dump_ast_matchers.py} flake8 compliant

2017-04-11 Thread Sylvestre Ledru via Phabricator via cfe-commits
sylvestre.ledru added a comment. Manuel, is that ok with you? https://reviews.llvm.org/D30863 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r299956 - Revert temporarily D29877 "Warn about unused static file scope function template declarations."

2017-04-11 Thread Vassil Vassilev via cfe-commits
Author: vvassilev Date: Tue Apr 11 11:05:23 2017 New Revision: 299956 URL: http://llvm.org/viewvc/llvm-project?rev=299956=rev Log: Revert temporarily D29877 "Warn about unused static file scope function template declarations." We need to address cases (breaking libc++) such as template static

[PATCH] D31404: [OpenCL] Allow alloca return non-zero private pointer

2017-04-11 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia accepted this revision. Anastasia added a comment. LGTM! Thanks! https://reviews.llvm.org/D31404 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D31652: [clang-format] Recognize Java logical shift assignment operator

2017-04-11 Thread Nico Weber via Phabricator via cfe-commits
thakis closed this revision. thakis added a comment. Landed in r299952: http://lists.llvm.org/pipermail/cfe-commits/Week-of-Mon-20170410/189882.html Repository: rL LLVM https://reviews.llvm.org/D31652 ___ cfe-commits mailing list

r299952 - [clang-format] Recognize Java logical shift assignment operator

2017-04-11 Thread Nico Weber via cfe-commits
Author: nico Date: Tue Apr 11 10:50:04 2017 New Revision: 299952 URL: http://llvm.org/viewvc/llvm-project?rev=299952=rev Log: [clang-format] Recognize Java logical shift assignment operator At present, clang-format mangles Java containing logical right shift operators ('>>>=' or '>>>'),

[PATCH] D25321: Fix PR13910: Don't warn that __builtin_unreachable() is unreachable

2017-04-11 Thread Alex Lorenz via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL299951: Fix PR13910: Don't warn that __builtin_unreachable() is unreachable (authored by arphaman). Changed prior to commit: https://reviews.llvm.org/D25321?vs=73898=94834#toc Repository: rL LLVM

r299951 - Fix PR13910: Don't warn that __builtin_unreachable() is unreachable

2017-04-11 Thread Alex Lorenz via cfe-commits
Author: arphaman Date: Tue Apr 11 10:36:06 2017 New Revision: 299951 URL: http://llvm.org/viewvc/llvm-project?rev=299951=rev Log: Fix PR13910: Don't warn that __builtin_unreachable() is unreachable Differential Revision: https://reviews.llvm.org/D25321 Modified:

[PATCH] D31417: [OpenMP] Add support for omp simd pragmas without runtime

2017-04-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: lib/Parse/ParseOpenMP.cpp:174 + case OMPD_target_teams_distribute_simd: +DKind = OMPD_simd; +break; huntergr wrote: > ABataev wrote: > > huntergr wrote: > > > rengolin wrote: > > > > I'd like

[PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists added a comment. Complete reproducer: // Tested with with: clang++ -std=c++14 -Wunused-function UnusedFVassily.cpp // // UnusedFVassily.cpp:8:39: warning: unused function '__test' [-Wunused-function] // template static __two __test(...); //

[PATCH] D29660: [OpenMP] Add flag for overwriting default PTX version for OpenMP targets

2017-04-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: lib/Driver/ToolChains/Cuda.cpp:499 +options::OPT_fopenmp_ptx_EQ); +CC1Args.back() = (!PtxVersion.empty()) ? PtxVersion.data() : "+ptx42"; + } else No, use `CC1Args.push_back()` here, or

[PATCH] D29905: [OpenMP] Pass argument to device kernel by reference when map is used.

2017-04-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: lib/Sema/SemaOpenMP.cpp:358-360 + /// Do the check specified in \a Check to all component lists at a given level + /// and return true if any issue is found. + bool checkMappableExprComponentListsForDeclAtLevel(

[PATCH] D31652: [clang-format] Recognize Java logical shift assignment operator

2017-04-11 Thread Richard Bradfield via Phabricator via cfe-commits
bradfier added a comment. In https://reviews.llvm.org/D31652#723664, @thakis wrote: > Looks good. Do you have commit access? Thanks! And no I don't have commit access. Repository: rL LLVM https://reviews.llvm.org/D31652 ___ cfe-commits

[PATCH] D31757: [clang-tidy] Add a clang-tidy check for possible inefficient vector operations

2017-04-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/performance/InefficientVectorOperationCheck.cpp:53-54 +PushBackCall)), + hasParent(compoundStmt(unless(has(ReserveCall)), + has(VectorVarDefStmt +

[PATCH] D31652: [clang-format] Recognize Java logical shift assignment operator

2017-04-11 Thread Nico Weber via Phabricator via cfe-commits
thakis accepted this revision. thakis added a comment. This revision is now accepted and ready to land. Looks good. Do you have commit access? Repository: rL LLVM https://reviews.llvm.org/D31652 ___ cfe-commits mailing list

[PATCH] D29660: [OpenMP] Add flag for overwriting default PTX version for OpenMP targets

2017-04-11 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 94824. gtbercea added a comment. Integrate review. Repository: rL LLVM https://reviews.llvm.org/D29660 Files: include/clang/Driver/Options.td lib/Driver/ToolChains/Cuda.cpp test/Driver/openmp-offload.c Index: test/Driver/openmp-offload.c

[PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev added a comment. @mclow.lists, hm... it seems that I cannot reproduce it. It'd really help if you could paste a standalone reproducer. https://reviews.llvm.org/D29877 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D26503: [Parser][ObjC] Improve diagnostics and recovery when C++ keywords are used as identifiers in Objective-C++

2017-04-11 Thread Alex Lorenz via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL299950: [Parser][ObjC++] Improve diagnostics and recovery when C++ keywords are used (authored by arphaman). Changed prior to commit: https://reviews.llvm.org/D26503?vs=78218=94823#toc Repository:

r299950 - [Parser][ObjC++] Improve diagnostics and recovery when C++ keywords are used

2017-04-11 Thread Alex Lorenz via cfe-commits
Author: arphaman Date: Tue Apr 11 10:01:53 2017 New Revision: 299950 URL: http://llvm.org/viewvc/llvm-project?rev=299950=rev Log: [Parser][ObjC++] Improve diagnostics and recovery when C++ keywords are used as identifiers in Objective-C++ This commit improves the 'expected identifier' errors

[PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev added a comment. @chapuni, the LLVM warnings should be fixed in r299947. @mclow.lists, sorry for not giving heads up :( I am working on the false positive that you reported. https://reviews.llvm.org/D29877 ___ cfe-commits mailing

[PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists added a comment. The following idiom for detecting member typedefs now throws an warning: struct __two {char __lx; char __lxx;}; namespace __has_pointer_type_imp { template __two __test(...); template char __test(typename _Up::pointer* = 0); } template

[PATCH] D31757: [clang-tidy] Add a clang-tidy check for possible inefficient vector operations

2017-04-11 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tidy/performance/InefficientVectorOperationCheck.cpp:53-54 +PushBackCall)), + hasParent(compoundStmt(unless(has(ReserveCall)), + has(VectorVarDefStmt +

[PATCH] D31652: [clang-format] Recognize Java logical shift assignment operator

2017-04-11 Thread Richard Bradfield via Phabricator via cfe-commits
bradfier added a comment. Friendly ping. Repository: rL LLVM https://reviews.llvm.org/D31652 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread Marshall Clow via cfe-commits
On Tue, Apr 11, 2017 at 6:59 AM, Alex Lorenz via Phabricator via cfe-commits wrote: > arphaman added a comment. > > Ah, I see. I guess if `static` is removed the warning will go away. Thanks! > > https://reviews.llvm.org/D29877 > > I would have appreciated a heads-up

[PATCH] D29905: [OpenMP] Pass argument to device kernel by reference when map is used.

2017-04-11 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea marked an inline comment as done. gtbercea added inline comments. Comment at: lib/Sema/SemaOpenMP.cpp:358-360 + /// Do the check specified in \a Check to all component lists at a given level + /// and return true if any issue is found. + bool

[PATCH] D31887: [clangd] Add documentation page

2017-04-11 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle-ericsson added a comment. Sorry about all the typos. I have now installed a spell checked in VS Code :) https://reviews.llvm.org/D31887 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D31887: [clangd] Add documentation page

2017-04-11 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle-ericsson updated this revision to Diff 94815. malaperle-ericsson marked 6 inline comments as done. malaperle-ericsson added a comment. Fixed typos and other comments. https://reviews.llvm.org/D31887 Files: docs/clangd.rst docs/index.rst Index: docs/index.rst

[PATCH] D31404: [OpenCL] Allow alloca return non-zero private pointer

2017-04-11 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked 2 inline comments as done. yaxunl added a comment. Any further comments? Thanks. https://reviews.llvm.org/D31404 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libcxx] r299942 - [libc++] Fix unknown pragma warning on MSVC

2017-04-11 Thread Ben Craig via cfe-commits
Author: bcraig Date: Tue Apr 11 09:06:39 2017 New Revision: 299942 URL: http://llvm.org/viewvc/llvm-project?rev=299942=rev Log: [libc++] Fix unknown pragma warning on MSVC Modified: libcxx/trunk/include/limits Modified: libcxx/trunk/include/limits URL:

[libcxx] r299941 - Mark P0599 as complete. It was implemented in r298573

2017-04-11 Thread Marshall Clow via cfe-commits
Author: marshall Date: Tue Apr 11 09:04:03 2017 New Revision: 299941 URL: http://llvm.org/viewvc/llvm-project?rev=299941=rev Log: Mark P0599 as complete. It was implemented in r298573 Modified: libcxx/trunk/www/cxx1z_status.html Modified: libcxx/trunk/www/cxx1z_status.html URL:

[PATCH] D30691: [analyzer] Support for naive cross translational unit analysis

2017-04-11 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun updated this revision to Diff 94814. xazax.hun edited the summary of this revision. xazax.hun added a comment. - Removed a clang tool, replaced with python tool functionality. https://reviews.llvm.org/D30691 Files: include/clang/AST/ASTContext.h include/clang/AST/Decl.h

[PATCH] D31757: [clang-tidy] Add a clang-tidy check for possible inefficient vector operations

2017-04-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/performance/InefficientVectorOperationCheck.cpp:53-54 +PushBackCall)), + hasParent(compoundStmt(unless(has(ReserveCall)), + has(VectorVarDefStmt +

[PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. Ah, I see. I guess if `static` is removed the warning will go away. Thanks! https://reviews.llvm.org/D29877 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev added a comment. @arphaman, it seems they are marked as static and this seemed like a bug to @rsmith. https://reviews.llvm.org/D29877 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. The operators in PointerUnion seem useful. I don't think they should be removed even if they're not used in tree, since they might be used by some out-of-tree code. https://reviews.llvm.org/D29877 ___ cfe-commits mailing

[PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread NAKAMURA Takumi via Phabricator via cfe-commits
chapuni added a comment. I think yes, you may do. Warnings fix may be trivial as far as they are NFC. It'd be fine that clang tree should be free from warnings with just-built clang. https://reviews.llvm.org/D29877 ___ cfe-commits mailing list

[PATCH] D29877: Warn about unused static file scope function template declarations.

2017-04-11 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev added a comment. Thanks for pinging us. Yeah, I knew them but I was hesitant whether I should fix them or they should be fixed by the code owners. Shall I commit the fixes? https://reviews.llvm.org/D29877 ___ cfe-commits mailing list

[PATCH] D31853: [clangd] Implement item kind for completion results

2017-04-11 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL299935: [clangd] Implement item kind for completion results (authored by krasimir). Changed prior to commit: https://reviews.llvm.org/D31853?vs=94720=94811#toc Repository: rL LLVM

  1   2   >