[PATCH] D40671: [clang-tidy] Support specific categories for NOLINT directive

2017-12-01 Thread Anton via Phabricator via cfe-commits
xgsa added a comment. In https://reviews.llvm.org/D40671#941676, @JonasToth wrote: > Could you please explain what category means? Could i disable all of > `cppcoreguidelines` with something like `// NOLINT (cppcoreguidelines-*)`? No, only individual checks can be disabled. You are right, by "

[PATCH] D15075: No error for conflict between inputs\outputs and clobber list

2017-12-01 Thread Marina Yatsina via Phabricator via cfe-commits
myatsina added a comment. In https://reviews.llvm.org/D15075#940711, @dolson wrote: > Hello, > > In the process of upgrading from clang 3.6.1 to a newer version, I ran into > this new error and thus imported the new intrinsics from intrin.h for rep > movsb and friends. I see several discussion

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-01 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: test/clang-tidy/nolintnextline.cpp:14 + +// NOLINTNEXTLINE(not-closed-bracket-is-treated-as-skip-all +class C2 { C2(int i); }; xgsa wrote: > JonasToth wrote: > > missing `)` > No, it's intentionally: it's a test for ca

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-01 Thread Anton via Phabricator via cfe-commits
xgsa added inline comments. Comment at: test/clang-tidy/nolintnextline.cpp:14 + +// NOLINTNEXTLINE(not-closed-bracket-is-treated-as-skip-all +class C2 { C2(int i); }; JonasToth wrote: > xgsa wrote: > > JonasToth wrote: > > > missing `)` > > No, it's intentionally

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-01 Thread Anton via Phabricator via cfe-commits
xgsa updated this revision to Diff 125084. xgsa added a comment. Herald added a subscriber: xazax.hun. Add comments to code as it was recommended. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D40671 Files: clang-tidy/ClangTidyDiagnosticConsumer.cpp test/clang-tidy/nolint.c

[PATCH] D40562: [Sema] Ignore decls in namespaces when global decls are not wanted.

2017-12-01 Thread Eric Liu via Phabricator via cfe-commits
ioeric added a comment. In https://reviews.llvm.org/D40562#941570, @arphaman wrote: > In https://reviews.llvm.org/D40562#940201, @ilya-biryukov wrote: > > > In https://reviews.llvm.org/D40562#939950, @arphaman wrote: > > > > > This change breaks cached completions for declarations in namespaces i

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-01 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: test/clang-tidy/nolintnextline.cpp:14 + +// NOLINTNEXTLINE(not-closed-bracket-is-treated-as-skip-all +class C2 { C2(int i); }; xgsa wrote: > JonasToth wrote: > > xgsa wrote: > > > JonasToth wrote: > > > > missing `)` >

[PATCH] D40705: [Parser] Diagnose storage classes in template parameter declarations

2017-12-01 Thread Mikhail Maltsev via Phabricator via cfe-commits
miyuki created this revision. [Parser] Diagnose storage classes in template parameter declarations According to the C++ Standard [temp.param]p2: A storage class shall not be specified in a template-parameter declaration. This patch implements a diagnostic for this restriction. https://rev

[PATCH] D40562: [Sema] Ignore decls in namespaces when global decls are not wanted.

2017-12-01 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In https://reviews.llvm.org/D40562#941570, @arphaman wrote: > I'm not actually 100% sure, but I would imagine that this one of the reasons, > yes. It would be nice to improve the cache to have things like > namespace-level `Decl`, although how will lookup work in

[PATCH] D40707: [libcxx] Fix basic_stringbuf constructor

2017-12-01 Thread Mikhail Maltsev via Phabricator via cfe-commits
miyuki created this revision. [libcxx] Fix basic_stringbuf constructor The C++ Standard [stringbuf.cons]p1 defines the effects of the basic_stringbuf constructor that takes ios_base::openmode as follows: Effects: Constructs an object of class basic_stringbuf, initializing the base class with

[PATCH] D40605: Better trade-off for excess characters vs. staying within the column limits.

2017-12-01 Thread Manuel Klimek via Phabricator via cfe-commits
klimek updated this revision to Diff 125094. klimek marked an inline comment as done. klimek added a comment. Add test. Repository: rC Clang https://reviews.llvm.org/D40605 Files: lib/Format/ContinuationIndenter.cpp lib/Format/ContinuationIndenter.h unittests/Format/FormatTest.cpp Ind

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-01 Thread Anton via Phabricator via cfe-commits
xgsa updated this revision to Diff 125096. xgsa added a comment. A few additional test cases were added. https://reviews.llvm.org/D40671 Files: clang-tidy/ClangTidyDiagnosticConsumer.cpp test/clang-tidy/nolint.cpp test/clang-tidy/nolintnextline.cpp Index: test/clang-tidy/nolint.cpp =

[PATCH] D40705: [Parser] Diagnose storage classes in template parameter declarations

2017-12-01 Thread Faisal Vali via Phabricator via cfe-commits
faisalv added inline comments. Comment at: lib/Parse/ParseTemplate.cpp:692 + // declaration. + auto ReportStorageClass = [&](SourceLocation Loc) { +if (ParamDecl.getIdentifier()) I tend to prefer explicit captures (unless you have a good reason?) - favori

[PATCH] D40712: Add cc1 flag enabling the function stack size section that was added in r319430

2017-12-01 Thread Sean Eveson via Phabricator via cfe-commits
seaneveson created this revision. Adds the -fstack-size-section flag to enable the .stack_sizes section. The flag defaults to on for the PS4 triple. Follow up change from: https://reviews.llvm.org/D39788 Original RFC: http://lists.llvm.org/pipermail/llvm-dev/2017-August/117028.html https://re

[PATCH] D40715: [analyser] different.LabelInsideSwitch checker implementation

2017-12-01 Thread Alexey Knyshev via Phabricator via cfe-commits
alexey.knyshev created this revision. alexey.knyshev added a project: clang. Herald added subscribers: cfe-commits, mgorny. Implementation of checker "different.LabelInsideSwitch" from potential checkers list (https://clang-analyzer.llvm.org/potential_checkers.html#different) Repository: rC C

[PATCH] D38921: [analyzer] LoopUnrolling: update the matched assignment operators

2017-12-01 Thread Peter Szecsi via Phabricator via cfe-commits
szepet added reviewers: alexfh, aaron.ballman. szepet added a comment. Added Alexander and Aaron as reviewers for the matcher parts. https://reviews.llvm.org/D38921 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bi

r319541 - Better trade-off for excess characters vs. staying within the column limits.

2017-12-01 Thread Manuel Klimek via cfe-commits
Author: klimek Date: Fri Dec 1 05:28:08 2017 New Revision: 319541 URL: http://llvm.org/viewvc/llvm-project?rev=319541&view=rev Log: Better trade-off for excess characters vs. staying within the column limits. When we break a long line like: Column limit: 21 | // foo foo f

[PATCH] D40605: Better trade-off for excess characters vs. staying within the column limits.

2017-12-01 Thread Manuel Klimek via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL319541: Better trade-off for excess characters vs. staying within the column limits. (authored by klimek). Repository: rL LLVM https://reviews.llvm.org/D40605 Files: cfe/trunk/lib/Format/Continuatio

[PATCH] D38921: [analyzer] LoopUnrolling: update the matched assignment operators

2017-12-01 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Aside from a request for another test, the matcher parts LGTM. Comment at: unittests/ASTMatchers/ASTMatchersNarrowingTest.cpp:1992 + EXPECT_TRUE(matches("void x() { int a; a &= 3; }", AsOperator)); + EXPECT_TRUE(notMatches("void x() { int a; if(

[PATCH] D33589: clang-format: consider not splitting tokens in optimization

2017-12-01 Thread Francois Ferrand via Phabricator via cfe-commits
Typz added a comment. I think the difference between code and comments is that code "words" are easily 10 characters or more, whereas actual words (in comments) are very often less than 10 characters: so code overflowing by 10 characters is not very frequent. whereas small words in comment will

[PATCH] D33589: clang-format: consider not splitting tokens in optimization

2017-12-01 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. In https://reviews.llvm.org/D33589#941979, @Typz wrote: > I think the difference between code and comments is that code "words" are > easily 10 characters or more, whereas actual words (in comments) are very > often less than 10 characters: so code overflowing by 10 char

[PATCH] D40705: [Parser] Diagnose storage classes in template parameter declarations

2017-12-01 Thread Mikhail Maltsev via Phabricator via cfe-commits
miyuki updated this revision to Diff 125119. miyuki added a comment. Use explicit lambda capture list. https://reviews.llvm.org/D40705 Files: include/clang/Basic/DiagnosticParseKinds.td lib/Parse/ParseTemplate.cpp test/CXX/temp/temp.param/p2.cpp Index: test/CXX/temp/temp.param/p2.cpp ==

[PATCH] D37813: clang-format: better handle namespace macros

2017-12-01 Thread Francois Ferrand via Phabricator via cfe-commits
Typz added a comment. Definitely that would be much more expressive. But this approach is also incomplete: in case of namespace (and possibly others?), we also need to perform the reverse operation, e.g. to "generate" a macro call for rewriting the closing comment. On top of this, I think that

[PATCH] D40719: [clangd] Split CodeComplete into a separate file. NFC

2017-12-01 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. Herald added subscribers: cfe-commits, mgorny, klimek. Shared details of ClangdUnit and CodeComplete moved to a new Compiler file. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D40719 Files: clangd/CMakeLists.txt clangd/ClangdServer.h clan

[PATCH] D40720: No -fsanitize=function warning when calling noexcept function through non-noexcept pointer in C++17

2017-12-01 Thread Stephan Bergmann via Phabricator via cfe-commits
sberg created this revision. Herald added a subscriber: kubamracek. As discussed in the mail thread https://groups.google.com/a/isocpp.org/forum/#!topic/std-discussion/T64_dW3WKUk "Calling noexcept function throug non-noexcept pointer is undefined behavior?", such a call should not be UB. Howe

[PATCH] D37813: clang-format: better handle namespace macros

2017-12-01 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. In https://reviews.llvm.org/D37813#941987, @Typz wrote: > Definitely that would be much more expressive. But this approach is also > incomplete: in case of namespace (and possibly others?), we also need to > perform the reverse operation, e.g. to "generate" a macro call

[clang-tools-extra] r319546 - [clangd] Remove no-op -fsyntax-only from fallback command. NFC

2017-12-01 Thread Sam McCall via cfe-commits
Author: sammccall Date: Fri Dec 1 06:35:17 2017 New Revision: 319546 URL: http://llvm.org/viewvc/llvm-project?rev=319546&view=rev Log: [clangd] Remove no-op -fsyntax-only from fallback command. NFC This has no effect because we explicitly choose our actions. (If it had an effect, we'd want to ad

[PATCH] D39903: [libclang] Allow pretty printing declarations

2017-12-01 Thread Nikolai Kosjar via Phabricator via cfe-commits
nik updated this revision to Diff 125129. nik added a comment. Rebased only. Repository: rC Clang https://reviews.llvm.org/D39903 Files: include/clang-c/Index.h test/Index/print-display-names.cpp tools/c-index-test/c-index-test.c tools/libclang/CIndex.cpp tools/libclang/libclang.ex

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-01 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/ClangTidyDiagnosticConsumer.cpp:295 + unsigned DiagID, const ClangTidyContext &Context) { + const auto NolintIndex = Line.find(NolintMacro); + if (NolintIndex != StringRef::npos) {

[PATCH] D40572: [OpenMP] Make test robust against quotation, NFC.

2017-12-01 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld abandoned this revision. Hahnfeld added a comment. Not needed anymore for the accepted patch which gets rid of the separator completely. https://reviews.llvm.org/D40572 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.l

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-01 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tidy/ClangTidyDiagnosticConsumer.cpp:293 } - -static bool LineIsMarkedWithNOLINT(SourceManager &SM, SourceLocation Loc) { +static bool IsNOLINTFound(StringRef NolintMacro, StringRef Line, + unsigned

[PATCH] D33589: clang-format: consider not splitting tokens in optimization

2017-12-01 Thread Francois Ferrand via Phabricator via cfe-commits
Typz added a comment. Indeed, looks good, thanks! Though that exacerbates the alignment issue, I now get things like this: enum { SomeLongerEnum, // comment SomeThing, // comment Foo, // something } ^ (column limit) The comment on 'Foo' would

[PATCH] D37813: clang-format: better handle namespace macros

2017-12-01 Thread Francois Ferrand via Phabricator via cfe-commits
Typz added a comment. As far as "parsing" and formatting inside the block is concerned, this is indeed unrelated (and would totally work if all macros where specified with some preprocessor definitions). But identifying the 'opening' token and generating the matching 'closing' comment are tota

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-01 Thread Anton via Phabricator via cfe-commits
xgsa updated this revision to Diff 125140. https://reviews.llvm.org/D40671 Files: clang-tidy/ClangTidyDiagnosticConsumer.cpp test/clang-tidy/nolint.cpp test/clang-tidy/nolintnextline.cpp Index: test/clang-tidy/nolint.cpp === -

[PATCH] D33589: clang-format: consider not splitting tokens in optimization

2017-12-01 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. In https://reviews.llvm.org/D33589#942128, @Typz wrote: > Indeed, looks good, thanks! > > Though that exacerbates the alignment issue, I now get things like this: > > enum { > SomeLongerEnum, // comment > SomeThing, // comment > Foo, // something > }

r319549 - Remove duplicate, nonsense information from an attribute diagnostic. The NonParmVar subject does not need to mention functions, and the resulting diagnostic definitely does not need to menti

2017-12-01 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Fri Dec 1 07:54:29 2017 New Revision: 319549 URL: http://llvm.org/viewvc/llvm-project?rev=319549&view=rev Log: Remove duplicate, nonsense information from an attribute diagnostic. The NonParmVar subject does not need to mention functions, and the resulting diagnostic

[PATCH] D37813: clang-format: better handle namespace macros

2017-12-01 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. In https://reviews.llvm.org/D37813#942137, @Typz wrote: > As far as "parsing" and formatting inside the block is concerned, this is > indeed unrelated (and would totally work if all macros where specified with > some preprocessor definitions). > > But identifying the 'op

[PATCH] D40060: [clangd] Fuzzy match scorer

2017-12-01 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov accepted this revision. ilya-biryukov added a comment. This revision is now accepted and ready to land. LGTM. Comment at: clangd/FuzzyMatch.h:53 + + int PatN, WordN; // Length of pattern and word. + char Pat[MaxPat], Word[MaxWord];

[clang-tools-extra] r319459 - add new check to find NSError init invocation

2017-12-01 Thread Yan Zhang via cfe-commits
Author: wizard Date: Thu Nov 30 11:05:08 2017 New Revision: 319459 URL: http://llvm.org/viewvc/llvm-project?rev=319459&view=rev Log: add new check to find NSError init invocation Summary: This check will find out improper initialization of NSError objects. According to Apple developer document,

[clang-tools-extra] r319460 - add new check to find NSError init invocation

2017-12-01 Thread Yan Zhang via cfe-commits
Author: wizard Date: Thu Nov 30 11:05:09 2017 New Revision: 319460 URL: http://llvm.org/viewvc/llvm-project?rev=319460&view=rev Log: add new check to find NSError init invocation Subscribers: klimek, mgorny, cfe-commits Differential Revision: https://reviews.llvm.org/D40528 Added: clang-too

[PATCH] D40731: Integrate CHash into CLang

2017-12-01 Thread Christian Dietrich via Phabricator via cfe-commits
stettberger created this revision. Herald added subscribers: cfe-commits, aprantl, mgorny. The CHashVisitor can be used to determine a unique hash for a translation unit. The hash is stable across compiler invocations and if two translation units have the same hash, the resulting object file is

[PATCH] D40625: Harmonizing attribute GNU/C++ spellings

2017-12-01 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin added a subscriber: alexfh. dcoughlin added inline comments. Comment at: include/clang/Basic/Attr.td:602 def AnalyzerNoReturn : InheritableAttr { - let Spellings = [GNU<"analyzer_noreturn">]; + let Spellings = [Clang<"analyzer_noreturn">]; let Documentation = [Und

[PATCH] D39882: [clangd] Filter completion results by fuzzy-matching identifiers.

2017-12-01 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov accepted this revision. ilya-biryukov added a comment. This revision is now accepted and ready to land. LGTM Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D39882 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D40733: [clangd] GlobalCompilationDatabase interface changes

2017-12-01 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. Herald added subscribers: cfe-commits, klimek. - GlobalCompilationDatabase now returns a single command (that's all we use) - fallback flags are now part of the GlobalCompilationDatabase. There's a default implementation that they can optionally customize. - this

[PATCH] D40660: Enable auto-linking on Windows

2017-12-01 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. I think it would make sense for this change to also have the conditional for the static C++ library selection. Basically something like #if defined(_LIBCPP_ABI_MICROSOFT) && !defined(_LIBC

[PATCH] D39882: [clangd] Filter completion results by fuzzy-matching identifiers.

2017-12-01 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL319552: [clangd] Filter completion results by fuzzy-matching identifiers. (authored by sammccall). Changed prior to commit: https://reviews.llvm.org/D39882?vs=125009&id=125155#toc Repository: rL LLVM

[PATCH] D39882: [clangd] Filter completion results by fuzzy-matching identifiers.

2017-12-01 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE319552: [clangd] Filter completion results by fuzzy-matching identifiers. (authored by sammccall). Changed prior to commit: https://reviews.llvm.org/D39882?vs=125009&id=125154#toc Repository: rL LL

[clang-tools-extra] r319552 - [clangd] Filter completion results by fuzzy-matching identifiers.

2017-12-01 Thread Sam McCall via cfe-commits
Author: sammccall Date: Fri Dec 1 08:35:50 2017 New Revision: 319552 URL: http://llvm.org/viewvc/llvm-project?rev=319552&view=rev Log: [clangd] Filter completion results by fuzzy-matching identifiers. Summary: This allows us to limit the number of results we return and still allow them to be sur

[PATCH] D40720: No -fsanitize=function warning when calling noexcept function through non-noexcept pointer in C++17

2017-12-01 Thread Stephan Bergmann via Phabricator via cfe-commits
sberg updated this revision to Diff 125152. sberg added a comment. (Diff 125121 had accidentally contained a spurious "}". Fixed that now.) https://reviews.llvm.org/D40720 Files: clang/lib/CodeGen/CGExpr.cpp compiler-rt/lib/ubsan/ubsan_handlers.cc compiler-rt/lib/ubsan/ubsan_handlers.h

[PATCH] D39279: Stringizing raw string literals containing newline

2017-12-01 Thread Jan Korous via Phabricator via cfe-commits
jkorous-apple added a comment. Thank you for your patience @twoh and sorry for the delay. I have few suggestions about doxygen annotations but otherwise LGTM. Comment at: include/clang/Lex/Lexer.h:247 + /// add surrounding ""'s to the string. If Charify is true, this escapes t

r319555 - Disallow a cleanup attribute from appertaining to a parameter (the attribute only appertains to local variables and is silently a noop on parameters). This repurposes the unused (and syntact

2017-12-01 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Fri Dec 1 08:53:49 2017 New Revision: 319555 URL: http://llvm.org/viewvc/llvm-project?rev=319555&view=rev Log: Disallow a cleanup attribute from appertaining to a parameter (the attribute only appertains to local variables and is silently a noop on parameters). This r

[PATCH] D15406: Add warning for attribute-cleanup on function parameter.

2017-12-01 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman closed this revision. aaron.ballman added a comment. I committed a different fix for this in r319555. https://reviews.llvm.org/D15406 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinf

[PATCH] D40625: Harmonizing attribute GNU/C++ spellings

2017-12-01 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: include/clang/Basic/Attr.td:602 def AnalyzerNoReturn : InheritableAttr { - let Spellings = [GNU<"analyzer_noreturn">]; + let Spellings = [Clang<"analyzer_noreturn">]; let Documentation = [Undocumented]; dcoug

[PATCH] D40060: [clangd] Fuzzy match scorer

2017-12-01 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. sammccall marked an inline comment as done. Closed by commit rL319557: [clangd] Fuzzy match scorer (authored by sammccall). Changed prior to commit: https://reviews.llvm.org/D40060?vs=124968&id=125159#toc Repository: rL

[clang-tools-extra] r319557 - [clangd] Fuzzy match scorer

2017-12-01 Thread Sam McCall via cfe-commits
Author: sammccall Date: Fri Dec 1 09:08:02 2017 New Revision: 319557 URL: http://llvm.org/viewvc/llvm-project?rev=319557&view=rev Log: [clangd] Fuzzy match scorer Summary: This will be used for rescoring code completion results based on partial identifiers. Short-term use: - we want to limit t

[PATCH] D40060: [clangd] Fuzzy match scorer

2017-12-01 Thread Sam McCall via Phabricator via cfe-commits
sammccall marked an inline comment as done. sammccall added a comment. I'd broken the scoring scale with the last few tweaks: - The harsh pattern-split penalty was driving too many decent matches to 0 score - The case-insensitive change resulted in some perfect prefix matches not getting perfect

[PATCH] D38845: [ASTImporter] Support importing UnresolvedMemberExpr, DependentNameType, DependentScopeDeclRefExpr

2017-12-01 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin added a comment. Hello Peter. Please set the dependencies for the patch - it cannot be applied clearly and even if I add ImportTemplateArgumentListInfo, tests still fail - looks like FunctionTemplateDecl patch should be applied first. https://reviews.llvm.org/D38845 __

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-01 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. This feature should probably be mentioned in the release notes. https://reviews.llvm.org/D40671 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r319560 - [OPENMP] Do not allow variables to be first|last-privates in

2017-12-01 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Fri Dec 1 09:40:15 2017 New Revision: 319560 URL: http://llvm.org/viewvc/llvm-project?rev=319560&view=rev Log: [OPENMP] Do not allow variables to be first|last-privates in distribute directives. OpenMP standard does not allow to mark the variables as firstprivate and lastp

[PATCH] D40687: [compiler-rt] Switch to add_llvm_install_targets

2017-12-01 Thread Chris Bieneman via Phabricator via cfe-commits
beanz added a comment. This change isn't safe. Compiler-RT is buildable without LLVM's modules as long as you disable the tests, so you can't use an AddLLVM function inside AddCompilerRT unless it is only used when tests are disabled. https://reviews.llvm.org/D40687

[PATCH] D40580: [clang-tidy] Adding Fuchsia checker for multiple inheritance

2017-12-01 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/fuchsia/MultipleInheritanceCheck.cpp:35 + StringRef Name = Node->getIdentifier()->getName(); + auto Pair = InterfaceMap.find(Name); + if (Pair == InterfaceMap.end()) Don't use `auto` as the type is no

[PATCH] D40673: Add _Float128 as alias to __float128 to enable compilations on Fedora27/glibc2-26

2017-12-01 Thread Melanie Blower via Phabricator via cfe-commits
mibintc abandoned this revision. mibintc added a comment. Thanks for all your reviews https://reviews.llvm.org/D40673 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D40737: [clang-tidy] Resubmit hicpp-multiway-paths-covered without breaking test

2017-12-01 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth created this revision. Herald added subscribers: cfe-commits, xazax.hun, mgorny. The original check did break the green buildbot in the sanitizer build. It took a while to redroduce and understand the issue. There occured a stackoverflow while parsing the AST. The testcase with 256 case

[PATCH] D40580: [clang-tidy] Adding Fuchsia checker for multiple inheritance

2017-12-01 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tidy/fuchsia/MultipleInheritanceCheck.cpp:35 + StringRef Name = Node->getIdentifier()->getName(); + auto Pair = InterfaceMap.find(Name); + if (Pair == InterfaceMap.end()) aaron.ballman wrote: > Don't use

[PATCH] D34082: [Frontend] 'Show hotness' can be used with a sampling profile

2017-12-01 Thread Adam Nemet via Phabricator via cfe-commits
anemet added a subscriber: davide. anemet added a comment. @modocache, @davide, are you guys sure this feature is working? The test does not actually check whether hotness is included in the remarks and when I run it manually they are missing. In https://reviews.llvm.org/D40678, I am filtering

[PATCH] D40580: [clang-tidy] Adding Fuchsia checker for multiple inheritance

2017-12-01 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/fuchsia/MultipleInheritanceCheck.cpp:35 + StringRef Name = Node->getIdentifier()->getName(); + auto Pair = InterfaceMap.find(Name); + if (Pair == InterfaceMap.end()) Eugene.Zelenko wrote: > aaron.ball

[PATCH] D40738: Don't use Wasm function sections for more than one function

2017-12-01 Thread Nicholas Wilson via Phabricator via cfe-commits
ncw created this revision. Herald added subscribers: cfe-commits, aheejin, sbc100, dschuff, jfb. Fixes Bugzilla https://bugs.llvm.org/show_bug.cgi?id=35467 If a Wasm function section is created with more than one symbol, WasmObjectWriter fails with the following message: "function sections must

[PATCH] D34082: [Frontend] 'Show hotness' can be used with a sampling profile

2017-12-01 Thread Davide Italiano via Phabricator via cfe-commits
davide added a comment. In https://reviews.llvm.org/D34082#942420, @anemet wrote: > @modocache, @davide, are you guys sure this feature is working? The test > does not actually check whether hotness is included in the remarks and when I > run it manually they are missing. In https://reviews.l

[PATCH] D40739: Pass through --undefined to Wasm LLD

2017-12-01 Thread Nicholas Wilson via Phabricator via cfe-commits
ncw created this revision. Herald added subscribers: cfe-commits, sunfish, aheejin, jgravelle-google, dschuff, jfb, klimek. This is a follow-on to https://reviews.llvm.org/D40724 (Wasm entrypoint changes #1, add `--undefined` argument to LLD). Repository: rC Clang https://reviews.llvm.org/D

[PATCH] D40739: Pass through --undefined to Wasm LLD

2017-12-01 Thread Nicholas Wilson via Phabricator via cfe-commits
ncw updated this revision to Diff 125176. ncw added a comment. (D'oh, more trouble with arcane commands getting diffs into phabricator... sorry for the spam.) Repository: rC Clang https://reviews.llvm.org/D40739 Files: lib/Driver/ToolChains/WebAssembly.cpp Index: lib/Driver/ToolChains/W

[PATCH] D40687: [compiler-rt] Switch to add_llvm_install_targets

2017-12-01 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added a comment. Ah, that's a bummer. compiler-rt's CMakeLists has this big shiny comment up top: # This build assumes that CompilerRT is checked out into the # 'projects/compiler-rt' or 'runtimes/compiler-rt' inside of an LLVM tree. # Standalone build system for CompilerRT is not

[PATCH] D40687: [compiler-rt] Switch to add_llvm_install_targets

2017-12-01 Thread Chris Bieneman via Phabricator via cfe-commits
beanz added a comment. Yes, that comment is very out of date. The compiler-rt standalone build is essential to many of the users. It is quite common to build and use compiler-rt without LLVM (like sanitizer support in gcc). https://reviews.llvm.org/D40687 ___

[PATCH] D40738: Don't use Wasm function sections for more than one function

2017-12-01 Thread Dan Gohman via Phabricator via cfe-commits
sunfish accepted this revision. sunfish added a comment. This revision is now accepted and ready to land. I think that was copied from LinuxTargetInfo before we figured out our current object file strategy. On native platforms, it's an icache optimization, because startup functions are all calle

[PATCH] D36836: [clang-tidy] Implement sonarsource-function-cognitive-complexity check

2017-12-01 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri updated this revision to Diff 125178. lebedev.ri changed the repository for this revision from rL LLVM to rCTE Clang Tools Extra. lebedev.ri added a comment. Rebased. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D36836 Files: LICENSE.TXT clang-tidy/CMakeLists.t

[PATCH] D40687: [compiler-rt] Add install-*-stripped targets

2017-12-01 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai updated this revision to Diff 125180. smeenai retitled this revision from "[compiler-rt] Switch to add_llvm_install_targets" to "[compiler-rt] Add install-*-stripped targets". smeenai edited the summary of this revision. smeenai added a comment. Add targets manually https://reviews.llvm

[PATCH] D40740: [compiler-rt] Remove out of date comment

2017-12-01 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai created this revision. Herald added subscribers: mgorny, dberris. Per beanz, building compiler-rt standalone is a pretty important use case, so the comment is very out of date. https://reviews.llvm.org/D40740 Files: CMakeLists.txt Index: CMakeLists.txt ==

[PATCH] D40739: Pass through --undefined to Wasm LLD

2017-12-01 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 added a comment. I'm a little confused by this. I was assuming you would do "-Wl,-u,foo" or "-Xlinker".I wasn't aware -u was a valid compiler flag itself. It doesn't show up in --help. Repository: rC Clang https://reviews.llvm.org/D40739 _

[PATCH] D40687: [compiler-rt] Add install-*-stripped targets

2017-12-01 Thread Chris Bieneman via Phabricator via cfe-commits
beanz accepted this revision. beanz added a comment. This revision is now accepted and ready to land. LGTM. https://reviews.llvm.org/D40687 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-co

[PATCH] D40740: [compiler-rt] Remove out of date comment

2017-12-01 Thread Chris Bieneman via Phabricator via cfe-commits
beanz accepted this revision. beanz added a comment. This revision is now accepted and ready to land. LGTM https://reviews.llvm.org/D40740 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com

[PATCH] D40687: [compiler-rt] Add install-*-stripped targets

2017-12-01 Thread Shoaib Meenai via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL319569: [compiler-rt] Add install-*-stripped targets (authored by smeenai). Repository: rL LLVM https://reviews.llvm.org/D40687 Files: compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake compiler-

[PATCH] D40740: [compiler-rt] Remove out of date comment

2017-12-01 Thread Shoaib Meenai via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL319570: [compiler-rt] Remove out of date comment (authored by smeenai). Repository: rL LLVM https://reviews.llvm.org/D40740 Files: compiler-rt/trunk/CMakeLists.txt Index: compiler-rt/trunk/CMakeLi

[PATCH] D34082: [Frontend] 'Show hotness' can be used with a sampling profile

2017-12-01 Thread Adam Nemet via Phabricator via cfe-commits
anemet added a comment. Looks like it's a test problem. When I tweak the sample profile file according to https://clang.llvm.org/docs/UsersManual.html#sample-profile-text-format, I do get hotness on the remarks. https://reviews.llvm.org/D34082 __

[PATCH] D40739: Pass through --undefined to Wasm LLD

2017-12-01 Thread Nicholas Wilson via Phabricator via cfe-commits
ncw added a comment. I didn't know it existed either, and you're right it's odd that it doesn't appear in the help text... However it duly exists and is implemented in clang/lib/Driver/ToolChains/Gnu.cpp, without any note that it's deprecated. `man gcc` documents it. Repository: rC Clang h

[PATCH] D40562: [Sema] Ignore decls in namespaces when global decls are not wanted.

2017-12-01 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. In https://reviews.llvm.org/D40562#941753, @ilya-biryukov wrote: > In https://reviews.llvm.org/D40562#941570, @arphaman wrote: > > > I'm not actually 100% sure, but I would imagine that this one of the > > reasons, yes. It would be nice to improve the cache to have thin

[PATCH] D40731: Integrate CHash into CLang

2017-12-01 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Please run Clang-format and Clang-tidy modernize over newly added code. Comment at: include/clang/AST/CHashVisitor.h:1 +#ifndef __CHASH_VISITOR +#define __CHASH_VISITOR Please loon onto other headers for inclusion guards style.

[PATCH] D40739: Pass through --undefined to Wasm LLD

2017-12-01 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 added a comment. Oh I see. lgtm. Do we need to update any tests? I see we won't have a wasm-ld.c test yet? We should add one? Repository: rC Clang https://reviews.llvm.org/D40739 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[PATCH] D40739: Pass through --undefined to Wasm LLD

2017-12-01 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 added a comment. By the way, thank you for all these wasm patches! Repository: rC Clang https://reviews.llvm.org/D40739 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D40731: Integrate CHash into CLang

2017-12-01 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. We already have mechanisms to hash the AST. I'm strongly opposed to adding another one (and requiring AST modifications to update yet more such mechanisms). Please look at the work that Richard Trieu has been doing recently to create stable-across-TUs hashes of statemen

[PATCH] D36357: Added a better diagnostic when using the delete operator with lambdas

2017-12-01 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 125189. Rakete added a comment. Updated error message, added a FixItHint + a rebase and friendly ping :) https://reviews.llvm.org/D36357 Files: include/clang/Basic/DiagnosticParseKinds.td lib/Parse/ParseExprCXX.cpp test/Parser/cxx0x-lambda-expr

r319576 - Partially fix comment in test broken in r306079 and r306948

2017-12-01 Thread Adam Nemet via cfe-commits
Author: anemet Date: Fri Dec 1 11:59:37 2017 New Revision: 319576 URL: http://llvm.org/viewvc/llvm-project?rev=319576&view=rev Log: Partially fix comment in test broken in r306079 and r306948 A RUN line was referring to the previous RUN line but a new test was added in between them. Just reorde

r319577 - Fix opt-remark with hotness testcase for sample-based PGO

2017-12-01 Thread Adam Nemet via cfe-commits
Author: anemet Date: Fri Dec 1 11:59:42 2017 New Revision: 319577 URL: http://llvm.org/viewvc/llvm-project?rev=319577&view=rev Log: Fix opt-remark with hotness testcase for sample-based PGO 1. Require hotness on all remark lines with -verify. 3. Fix the samplePGO file to actually produce hotnes

r319578 - Fix the second part of the broken comment from r306079

2017-12-01 Thread Adam Nemet via cfe-commits
Author: anemet Date: Fri Dec 1 11:59:45 2017 New Revision: 319578 URL: http://llvm.org/viewvc/llvm-project?rev=319578&view=rev Log: Fix the second part of the broken comment from r306079 The driver-based test is still not identical to the front-end line, remove the hotness threshold from there a

[clang-tools-extra] r319579 - [clangd] Define constants in the right namespace. NFC

2017-12-01 Thread Sam McCall via cfe-commits
Author: sammccall Date: Fri Dec 1 12:03:19 2017 New Revision: 319579 URL: http://llvm.org/viewvc/llvm-project?rev=319579&view=rev Log: [clangd] Define constants in the right namespace. NFC Modified: clang-tools-extra/trunk/clangd/FuzzyMatch.cpp Modified: clang-tools-extra/trunk/clangd/Fuzzy

[PATCH] D34082: [Frontend] 'Show hotness' can be used with a sampling profile

2017-12-01 Thread Adam Nemet via Phabricator via cfe-commits
anemet added a comment. Sorted these out in https://reviews.llvm.org/rL319576, https://reviews.llvm.org/rL319577 and https://reviews.llvm.org/rL319578. https://reviews.llvm.org/D34082 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://l

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-01 Thread Anton via Phabricator via cfe-commits
xgsa updated this revision to Diff 125190. xgsa added a comment. An item to release notes was added. Also I have added a paragraph about NOLINT to the main documentation page, because I suppose it's useful information and it's related to the feature. Please, let me know if it should be added wi

[PATCH] D40743: Make rehash(0) work with ubsan's unsigned-integer-overflow.

2017-12-01 Thread Dan Albert via Phabricator via cfe-commits
danalbert created this revision. Repository: rCXX libc++ https://reviews.llvm.org/D40743 Files: include/__hash_table Index: include/__hash_table === --- include/__hash_table +++ include/__hash_table @@ -2136,7 +2136,7 @@ void

[PATCH] D40044: [CodeGen] convert math libcalls/builtins to equivalent LLVM intrinsics

2017-12-01 Thread Eli Friedman via Phabricator via cfe-commits
efriedma accepted this revision. efriedma added a comment. This revision is now accepted and ready to land. LGTM. https://reviews.llvm.org/D40044 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/

[PATCH] D40746: Correctly handle line directives without filenames that come first in the file

2017-12-01 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. The comment in LineTableInfo::AddLineNote says "An unspecified FilenameID means use the last filename if available, or the main source file otherwise.", but the second part of that sentence was never actually implemented. This lead to asserts when writing the line table

[PATCH] D40748: [ThinLTO] Enable importing of aliases as copy of aliasee

2017-12-01 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson created this revision. Herald added a subscriber: inglorion. Clang side changes to go with LLVM change to import aliases as a copy of their aliasee. Simply refactor out some handling that is moved to LLVM for use elsewhere. Depends on https://reviews.llvm.org/D40747. Repository: rC

[PATCH] D35894: [clangd] Code hover for Clangd

2017-12-01 Thread William Enright via Phabricator via cfe-commits
Nebiroth marked 9 inline comments as done. Nebiroth added inline comments. Comment at: clangd/Protocol.h:26 #include "llvm/ADT/Optional.h" -#include +#include "llvm/Support/YAMLParser.h" #include malaperle wrote: > revert this change? #include is not needed.

  1   2   >