[PATCH] D135341: adds `__reference_constructs_from_temporary`

2023-09-13 Thread Christopher Di Bella via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG8f3b0b417143: [clang] adds `__reference_constructs_from_temporary` (authored by cjdb). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D135341: adds `__reference_constructs_from_temporary`

2023-09-13 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 556693. cjdb marked an inline comment as done. cjdb added a comment. partially reverts change and fixes typo Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135341/new/ https://reviews.llvm.org/D135341 Files:

[PATCH] D135341: adds `__reference_constructs_from_temporary`

2023-09-13 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/lib/Sema/SemaExprCXX.cpp:5515 + QualType UPtr = S.BuiltinAddPointer(S.BuiltinRemoveReference(U, UnaryTransformType::RemoveCVRef, {}), {}); + return EvaluateBinaryTypeTrait(S, TypeTrait::BTT_IsConvertibleTo, UPtr, TPtr,

[PATCH] D129538: [clang] adds prototype for being able to alternate diagnostic formats

2023-09-12 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb abandoned this revision. cjdb added a comment. Abandoning since this design is obsolete. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129538/new/ https://reviews.llvm.org/D129538 ___ cfe-commits

[PATCH] D135341: adds `__reference_constructs_from_temporary`

2023-09-12 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/lib/Sema/SemaExprCXX.cpp:33 #include "clang/Basic/TypeTraits.h" +#include "clang/Basic/TokenKinds.h" #include "clang/Lex/Preprocessor.h" cor3ntin wrote: > Superfluous change Nice catch! Repository: rG LLVM

[PATCH] D135341: adds `__reference_constructs_from_temporary`

2023-09-12 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 556609. cjdb marked 3 inline comments as done. cjdb added a comment. - responds to @cor3ntin's feedback - updates commit message to include `[clang]` tag and also indicate this is a revert Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D135341: adds `__reference_constructs_from_temporary`

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Sorry, I had read @erichkeane's LGTM and taken that as actually approved. Would you like me to revert? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135341/new/ https://reviews.llvm.org/D135341

[PATCH] D135341: adds `__reference_constructs_from_temporary`

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGe1bfeb6bcc62: adds `__reference_constructs_from_temporary`

[PATCH] D135238: [clang] adds copy-constructible type-trait builtins

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 556500. cjdb added a comment. runs 'arc diff `git merge-base HEAD origin` --update D135238 ' to try and get CI happy Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135238/new/

[PATCH] D135341: adds `__reference_constructs_from_temporary`

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 556499. cjdb added a comment. I somehow made cxx_status.html worse in the previous commit, not better Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135341/new/ https://reviews.llvm.org/D135341 Files:

[PATCH] D135341: adds `__reference_constructs_from_temporary`

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 556497. cjdb retitled this revision from "[clang] adds `__reference_constructs_from_temporary`" to "adds `__reference_constructs_from_temporary`". cjdb edited the summary of this revision. cjdb added a comment. Corrects cxx_status.html, which accidentally

[PATCH] D135341: [clang] adds `__reference_constructs_from_temporary`

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Oh, I shouldn't have so much green in the status, whoops! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135341/new/ https://reviews.llvm.org/D135341 ___ cfe-commits mailing list

[PATCH] D135341: [clang] adds `__reference_constructs_from_temporary`

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D135341#4643712 , @erichkeane wrote: > Is the changes to cxx_status.html still relevant/current? Yeah. > Also, did we ever figure out what GCC did for a builtin here? Do they have > one yet? If not, have we encouraged them

[PATCH] D135341: [clang] adds `__reference_constructs_from_temporary`

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 556488. cjdb added a comment. responds to feedback: - removes diagnostic - adds documentation Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135341/new/ https://reviews.llvm.org/D135341 Files:

[PATCH] D135341: [clang] adds `__reference_constructs_from_temporary`

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D135341#4126101 , @erichkeane wrote: > On the fence about the diagnostic at all, but definitely should not be doing > string magic to make it quoted. Otherwise this is a LGTM. Whoops, missed this comment. I'll be addressing

[PATCH] D157572: [clang] Add `[[clang::library_extension]]` attribute

2023-08-28 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Started a thread: https://discourse.llvm.org/t/exposing-the-diagnostic-engine-to-c/73092 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157572/new/ https://reviews.llvm.org/D157572

[PATCH] D157572: [clang] Add `[[clang::library_extension]]` attribute

2023-08-28 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D157572#4617504 , @aaron.ballman wrote: > In D157572#4614561 , @cjdb wrote: > >> In D157572#4613622 , >> @aaron.ballman wrote: >> >>> In

[PATCH] D157572: [clang] Add `[[clang::library_extension]]` attribute

2023-08-24 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D157572#4613622 , @aaron.ballman wrote: > In D157572#4612141 , @cjdb wrote: > >> I don't dislike it, but I am a bit concerned about misuse being noisy. > > So you're concerned that a

[PATCH] D157572: [clang] Add `[[clang::library_extension]]` attribute

2023-08-23 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D157572#4606513 , @aaron.ballman wrote: > In D157572#4604595 , @philnik wrote: > >> In D157572#4604482 , >> @aaron.ballman wrote: >> This

[PATCH] D151575: [clang][diagnostics] Always show include stacks on top-level diagnostics

2023-08-23 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D151575#4607047 , @aaron.ballman wrote: > I am wrestling with this one because I think the status quo is unfortunate > (we silently drop relevant information in ways the user may not immediately > understand) but I think

[PATCH] D158006: [Clang][WIP]Experimental implementation of data member packs in dependent context.

2023-08-15 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/lib/Sema/SemaTemplateInstantiate.cpp:3292 + std::string NewFieldName = + PackedField->getName().str() + "@" + std::to_string(Arg); + PackedField->setDeclName((NewFieldName)); Does LLVM

[PATCH] D155064: [clang][SemaCXX] Diagnose tautological uses of consteval if and is_constant_evaluated

2023-08-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/test/SemaCXX/warn-constant-evaluated-constexpr.cpp:38 constexpr int fn5() { - if constexpr (__builtin_is_constant_evaluated()) // expected-warning {{'__builtin_is_constant_evaluated' will always evaluate to 'true' in a manifestly

[PATCH] D157572: [clang] Add `[[clang::library_extension]]` attribute

2023-08-10 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:5690-5691 +def warn_unknown_ext : Warning<"Unknown extension kind: %0">; +def warn_cxx11_ext : Warning<"%0 is a C++11 extension">, +InGroup; +def warn_cxx14_ext : Warning<"%0 is a C++14

[PATCH] D156546: [Clang][WIP]Experimental implementation of data member packs declarations

2023-08-01 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/lib/Sema/SemaTemplateInstantiate.cpp:3270-3339 +// Instantiate packed data members. +if (FieldDecl *Field = dyn_cast(Member); +Field && isa(Field->getType().getTypePtr())) { + QualType PatternType =

[PATCH] D156546: [Clang][WIP]Experimental implementation of data member packs declarations

2023-07-31 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/lib/Sema/SemaType.cpp:5930-5931 break; +case DeclaratorContext::Member: + // Expand for packed data members. case DeclaratorContext::TemplateParam: dblaikie wrote: > Perhaps a few more words here

[PATCH] D155549: [clang] adds `conceptDecl` as an ASTMatcher

2023-07-20 Thread Christopher Di Bella via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG38e1c597033d: [clang] adds `conceptDecl` as an ASTMatcher (authored by cjdb). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D155549: [clang] adds `conceptDecl` as an ASTMatcher

2023-07-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 542706. cjdb edited the summary of this revision. cjdb added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. just trying to get CI close to green :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D155610: [Clang][ExprConstant] Print integer instead of character on static assertion failure

2023-07-19 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. I think Tom's suggestion about using escapes and UCNs is great. I have no real opinion on whether the numeric values is the one that's parenthesised. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D155610/new/

[PATCH] D154366: [clang][ExprConstant] Print template arguments when describing stack frame

2023-07-19 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb accepted this revision. cjdb added a comment. If there aren't any concerns from others, then LGTM! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154366/new/ https://reviews.llvm.org/D154366 ___ cfe-commits mailing list

[PATCH] D153623: [clang][Sema] Add fixit for scoped enum format error

2023-07-14 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Sorry, forgot to come back and LGTM, but it did indeed LGTM! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153623/new/ https://reviews.llvm.org/D153623 ___ cfe-commits mailing list

[PATCH] D153359: [clang][Diagnostics] Fix distant source ranges in bad-conversion notes

2023-07-07 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb accepted this revision. cjdb added a comment. This revision is now accepted and ready to land. Yep! Thanks for working on this :-) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153359/new/ https://reviews.llvm.org/D153359 ___

[PATCH] D154366: [clang][ExprConstant] Print template arguments when describing stack frame

2023-07-05 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a subscriber: dblaikie. cjdb added a comment. Generally in favour of this, but I wonder if we ought to have a way of suppressing it when the specialisation is known and ends up being a gargantuan name (this is a discussion, not an action item). cc @dblaikie Repository: rG LLVM

[PATCH] D154253: [clang] detect integer overflow through temporary values

2023-06-30 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. > Fixes GH63629. Would you mind changing this to `Fixes #63629` please? That'll get it connected in GitHub. The patch looks good, would you mind adding some release notes before I give LGTM please? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D153359: [clang][Diagnostics] Fix distant source ranges in bad-conversion notes

2023-06-30 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D153359#4463009 , @tbaeder wrote: > @cjdb I know this is kind of silly after @hazohelet has already added it to > the release notes... but it seems like showing the difference is useless > since the difference was only

[PATCH] D153849: [clang][Diagnostics] Fix diagnostic line numbers

2023-06-29 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. LGTM. Not sure if the `Fixes https://github.com/llvm/llvm-project/issues/63524` line autocloses the issue, but note that `Fixes #63524` does. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153849/new/

[PATCH] D153359: [clang][Diagnostics] Fix distant source ranges in bad-conversion notes

2023-06-28 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Per this Discourse post , I think it'd be best for the example I asked to be in your commit message to actually be in your release notes. Sorry for the churn! CHANGES SINCE LAST ACTION

[PATCH] D153690: [clang][Sema] Remove dead diagnostic for loss of __unaligned qualifier

2023-06-27 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb accepted this revision. cjdb added a comment. Excellent, thanks! LGTM, do you need assistance with merging? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153690/new/ https://reviews.llvm.org/D153690 ___ cfe-commits mailing list

[PATCH] D153536: [Clang] Implement P2169 A nice placeholder with no name

2023-06-27 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:6589 +def err_using_placeholder_variable : Error< + "referring to placeholder '_' is not allowed">; +def note_reference_placeholder : Note< aaron.ballman wrote: > I don't

[PATCH] D153690: [clang][Sema] Remove dead diagnostic for loss of __unaligned qualifier

2023-06-26 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Can we get a snippet of code to demonstrate what isn't being diagnosed anymore, please? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153690/new/ https://reviews.llvm.org/D153690

[PATCH] D152686: [clangd] Enforce strict unused includes by default

2023-06-26 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. This patch seems to have broken clangd for a project of mine. Most of my headers are now flagged as not being directly used even though they're the root header for the symbol. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D153267: [clang][Diagnostics] Provide parameter source range to arity-mismatch notes

2023-06-23 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb accepted this revision. cjdb added a comment. Thanks! This LGTM now. Do you need assistance with merging? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153267/new/ https://reviews.llvm.org/D153267 ___ cfe-commits mailing list

[PATCH] D153267: [clang][Diagnostics] Provide parameter source range to arity-mismatch notes

2023-06-21 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. I think this will be a good addition because it underscores the salient part of why the function isn't viable. Would it be possible for patches like this to have both examples of before and after this patch in their commit message please? That'll help expose why patches

[PATCH] D153359: [clang][Diagnostics] Fix distant source ranges in bad-conversion notes

2023-06-21 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. I like this patch, thanks for working on it  In D153359#4436873 , @hazohelet wrote: > Consider the following code. (I added another parameter to the original code > so that the covered range becomes clearer) > > void func(int

[PATCH] D151720: [clang][ExprConstant] Fix display of syntactically-invalid note for member function calls

2023-06-13 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb accepted this revision. cjdb added a comment. This revision is now accepted and ready to land. This patch seems like a win to me. Comment at: clang/docs/ReleaseNotes.rst:325 + invalid code. Furthermore, it also displays the object as written by the user. + (`#57081:

[PATCH] D152525: [clang][Diagnostics] Don't expand label fixit to the next line

2023-06-13 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb accepted this revision. cjdb added a comment. Thanks for fixing this, it'll hopefully cause less frustration for devs :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D152525/new/ https://reviews.llvm.org/D152525

[PATCH] D151833: Respect "-fdiagnostics-absolute-paths" on emit include location

2023-06-05 Thread Christopher Di Bella via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG91be60b34715: Respect -fdiagnostics-absolute-paths on emit include location (authored by charmitro, committed by cjdb). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D152034: [clang][NFC] refactors value type traits so we can have more than bools

2023-06-05 Thread Christopher Di Bella via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG798c5ba770d3: [clang][NFC] refactors value type traits so we can have more than bools (authored by cjdb). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D151833: Respect "-fdiagnostics-absolute-paths" on emit include location

2023-06-05 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. I already have another commit I plan to push, will do these together :) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151833/new/ https://reviews.llvm.org/D151833 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D151952: [clang] adds `__type_pack_index` so we can get a type's parameter pack index

2023-06-05 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D151952#4392329 , @rsmith wrote: > Taking a step back for a moment: what is the intended use case for this? My > concern is that most of the time you're going to want to make O(N) such > queries into a pack of N elements,

[PATCH] D147717: [C++20][NFC] Claim full support for consteval again

2023-06-05 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D147717#4395204 , @Fznamznon wrote: > In D147717#4393019 , @cor3ntin > wrote: > >> I think we should make sure to land this for clang 17. The rate of consteval >> bugs is no greater

[PATCH] D151833: Respect "-fdiagnostics-absolute-paths" on emit include location

2023-06-05 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D151833#4396399 , @charmitro wrote: > In D151833#4396244 , @cjdb wrote: > >> Can the commit message have a description please? It's unclear to me why >> this is necessary (although I'm

[PATCH] D151575: [clang][diagnostics] Always show include stacks on errors

2023-06-05 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added subscribers: shafik, erichkeane, aaron.ballman. cjdb added a comment. @aaron.ballman @erichkeane @shafik any reservations? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151575/new/ https://reviews.llvm.org/D151575

[PATCH] D151833: Respect "-fdiagnostics-absolute-paths" on emit include location

2023-06-05 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Can the commit message have a description please? It's unclear to me why this is necessary (although I'm sure there's a good reason). CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151833/new/ https://reviews.llvm.org/D151833

[PATCH] D151952: [clang] adds `__type_pack_index` so we can get a type's parameter pack index

2023-06-02 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/lib/Sema/SemaExprCXX.cpp:5620 + if (Kind == clang::TT_TypePackIndex) +return EvaluateIntegralTypeTrait(*this, Kind, KWLoc, Args, RParenLoc, erichkeane wrote: > I realize this is the 1st, but this seems like it

[PATCH] D152034: [clang][NFC] refactors value type traits so we can have more than bools

2023-06-02 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb created this revision. cjdb added reviewers: erichkeane, dblaikie. Herald added a project: All. cjdb requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Since all the type traits up until now have had Boolean vaules, we've always been

[PATCH] D151952: [clang] adds `__type_pack_index` so we can get a type's parameter pack index

2023-06-02 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/include/clang/AST/Stmt.h:796-802 +/// If this expression is not value-dependent, this stores the value. +unsigned Value : 8; /// The number of arguments to this type trait. According to [implimits] /// 8 bits

[PATCH] D151952: [clang] adds `__type_pack_index` so we can get a type's parameter pack index

2023-06-01 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/include/clang/AST/Stmt.h:796-802 +/// If this expression is not value-dependent, this stores the value. +unsigned Value : 8; /// The number of arguments to this type trait. According to [implimits] /// 8 bits

[PATCH] D151952: [clang] adds `__type_pack_index` so we can get a type's parameter pack index

2023-06-01 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 527681. cjdb added a comment. fixes some code I wrote when debugging Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151952/new/ https://reviews.llvm.org/D151952 Files: clang/docs/LanguageExtensions.rst

[PATCH] D151952: [clang] adds `__type_pack_index` so we can get a type's parameter pack index

2023-06-01 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb created this revision. cjdb added reviewers: aaron.ballman, erichkeane, shafik, dblaikie. Herald added subscribers: arphaman, martong. Herald added a project: All. cjdb requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Similarly to

[PATCH] D151575: [clang][diagnostics] Always show include stacks on errors

2023-05-30 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Thanks for working on this. Would you mind adding more context to the commit description please? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151575/new/ https://reviews.llvm.org/D151575

[PATCH] D151162: Add -Wpacked-non-pod to -Wall

2023-05-24 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb accepted this revision. cjdb added a comment. This revision is now accepted and ready to land. Thanks for working on this! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151162/new/ https://reviews.llvm.org/D151162

[PATCH] D147717: [C++20][NFC] Claim full support for consteval again

2023-05-03 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D147717#4312066 , @Fznamznon wrote: > In D147717#4275410 , @cjdb wrote: > >> I'm gonna get started on this today! > > @cjdb , how is this going? I've seen >

[PATCH] D149492: [clang] makes built-in traits match their stdlib counterparts' names

2023-05-01 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Looks like I need to special-case `__is_null_pointer` as a function for libstdc++. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149492/new/ https://reviews.llvm.org/D149492 ___

[PATCH] D149618: [clang][NFC] documents recent type trait primitives

2023-05-01 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb created this revision. cjdb added reviewers: aaron.ballman, erichkeane, shafik. Herald added a project: All. cjdb requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Depends on D149492 . Repository:

[PATCH] D129951: adds `__disable_adl` attribute

2023-05-01 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Ping (moving my pings from Thursday afternoon to Monday mornings) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129951/new/ https://reviews.llvm.org/D129951 ___ cfe-commits mailing

[PATCH] D149492: [clang] makes built-in traits match their stdlib counterparts' names

2023-04-28 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb created this revision. cjdb added reviewers: rsmith, aaron.ballman. Herald added a project: All. cjdb requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. The original names apparently broke convention by not making them the same as the

[PATCH] D146654: [clang] replaces numeric SARIF ids with heirarchical names

2023-04-28 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/lib/Frontend/SARIFDiagnostic.cpp:51-52 + Diag->getDiags()->getDiagnosticIDs()->getStableName(Diag->getID()).str(); + std::replace(StableName.begin(), StableName.end(), '_', '.'); + SarifRule Rule =

[PATCH] D129951: adds `__disable_adl` attribute

2023-04-27 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Gentle ping :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129951/new/ https://reviews.llvm.org/D129951 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D141451: [clang] report inlining decisions with -Wattribute-{warning|error}

2023-04-27 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/test/Frontend/backend-attribute-error-warning-optimize.c:12 foo(); // expected-error {{call to 'foo' declared with 'error' attribute: oh no foo}} + // expected-note@* {{In function 'baz'}} if (x())

[PATCH] D141451: [clang] report inlining decisions with -Wattribute-{warning|error}

2023-04-26 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/test/Frontend/backend-attribute-error-warning-optimize.c:12 foo(); // expected-error {{call to 'foo' declared with 'error' attribute: oh no foo}} + // expected-note@* {{In function 'baz'}} if (x())

[PATCH] D147844: [clang][Sema]Print diagnostic warning about precedence when integer expression is used without parentheses in an conditional operator expression

2023-04-26 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D147844#4293988 , @dblaikie wrote: > In D147844#4293743 , @cjdb wrote: > >> In D147844#4293693 , @dblaikie >> wrote: >> I think some of the

[PATCH] D147844: [clang][Sema]Print diagnostic warning about precedence when integer expression is used without parentheses in an conditional operator expression

2023-04-24 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D147844#4293693 , @dblaikie wrote: >> I think some of the cases are ambiguous while others are not. > > Data would be good to have - if this assessment is true, we'd expect this to > bear out in terms of bug finding, yeah? (that

[PATCH] D147844: [clang][Sema]Print diagnostic warning about precedence when integer expression is used without parentheses in an conditional operator expression

2023-04-24 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. I think this is a good diagnostic to add: it improves readability and eliminates ambiguities. My only request is that if there isn't already a FixIt hint, one be added, please. Comment at: clang/test/Sema/parentheses.c:94 (void)(x + y > 0 ? 1 : 2);

[PATCH] D148835: [clang] removes trailing whitespace

2023-04-21 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D148835#4288151 , @erichkeane wrote: > In D148835#4288148 , @cjdb wrote: > >> In D148835#4286924 , >> @aaron.ballman wrote: >> >>> In

[PATCH] D129835: [clang] adds a discardable attribute

2023-04-21 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Yeah, in retrospect, I agree (and may need to clean up a few iterator types now, grr). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129835/new/ https://reviews.llvm.org/D129835

[PATCH] D148835: [clang] removes trailing whitespace

2023-04-21 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D148835#4286924 , @aaron.ballman wrote: > In D148835#4286905 , @erichkeane > wrote: > >> In D148835#4284871 , @cjdb wrote: >> >>> I've had some

[PATCH] D129835: [clang] adds a discardable attribute

2023-04-21 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. >> With [[discardable]] one just needs to push/pop at the extremes of a file >> (and if a future version of module maps supports global pragmas for a >> module, there too, but that's a discussion that requires a design doc). > > I understood that, I just don't think that's

[PATCH] D141310: [clang] add -Wcompare-function-pointers

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. @aaron.ballman are you okay with this being merged now, provided that it's off by default? Apologies for letting this one fall through the cracks. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D141310/new/

[PATCH] D140125: [clang] splits diagnostic message into summary and reason

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb abandoned this revision. cjdb added a comment. Abandoning since we're going down a different design path now. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D140125/new/ https://reviews.llvm.org/D140125

[PATCH] D138939: [WIP][clang] adds a way to provide user-oriented reasons

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb abandoned this revision. cjdb added a comment. Herald added a subscriber: PiotrZSL. Herald added a project: clang-format. Herald added reviewers: rymiel, HazardyKnusperkeks, owenpan, MyDeveloperDay. Abandoning since we're heading down a different design path now. Repository: rG LLVM

[PATCH] D135338: [clang] adds move-assignable type-trait builtins

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb abandoned this revision. cjdb added a comment. Abandoning, since this doesn't have consensus. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135338/new/ https://reviews.llvm.org/D135338 ___

[PATCH] D135240: [clang] adds move-constructible type-trait builtins

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb abandoned this revision. cjdb added a comment. Abandoning, since this doesn't have consensus. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135240/new/ https://reviews.llvm.org/D135240 ___

[PATCH] D135239: [clang] adds copy-assignable type-trait builtins

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb abandoned this revision. cjdb added a comment. Abandoning, since this doesn't have consensus. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135239/new/ https://reviews.llvm.org/D135239 ___

[PATCH] D135238: [clang] adds copy-constructible type-trait builtins

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb abandoned this revision. cjdb added a comment. Abandoning, since this doesn't have consensus. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135238/new/ https://reviews.llvm.org/D135238 ___

[PATCH] D107292: [clang] adds warning to alert user when they use alternative tokens in declarations

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb abandoned this revision. cjdb added a comment. Herald added a project: All. I think there was a clang-tidy patch that handled this. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D107292/new/ https://reviews.llvm.org/D107292

[PATCH] D129951: adds `__disable_adl` attribute

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/lib/Sema/SemaDeclAttr.cpp:5756 + if (FunctionDecl *F = D->getAsFunction(); + F->isOverloadedOperator() || F->isCXXClassMember()) { +S.Diag(AL.getLoc(), diag::err_disable_adl_no_operators) cor3ntin wrote: >

[PATCH] D129951: adds `__disable_adl` attribute

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 515497. cjdb marked 6 inline comments as done. cjdb added a comment. Herald added subscribers: aheejin, dschuff. - undoes whitespace changes as requested - documents feature I think the only thing left is to address the global new/delete and static member

[PATCH] D148835: [clang] removes trailing whitespace

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb abandoned this revision. cjdb added a comment. I've had some very good input about why this probably shouldn't go ahead: git history erasure :') Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148835/new/ https://reviews.llvm.org/D148835

[PATCH] D148835: [clang] removes trailing whitespace

2023-04-20 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb created this revision. cjdb added reviewers: aaron.ballman, shafik, erichkeane, dblaikie. Herald added subscribers: luke, steakhal, bzcheeseman, kosarev, pmatos, asb, ormris, frasercrmck, jdoerfert, martong, luismarques, apazos, sameer.abuasal, pengfei, s.egerton, Jim, jocewei, PkmX,

[PATCH] D148677: [clang] makes `__is_trivially_equality_comparable` available as a struct

2023-04-19 Thread Christopher Di Bella via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG33e21610f9cd: [clang] makes `__is_trivially_equality_comparable` available as a struct (authored by cjdb). Repository: rG LLVM Github Monorepo

[PATCH] D147175: [clang] Add __is_trivially_equality_comparable

2023-04-18 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. This patch is causing breakages downstream because it didn't have do the struct dance, so I've added D148677 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147175/new/

[PATCH] D148677: [clang] makes `__is_trivially_equality_comparable` available as a struct

2023-04-18 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 514798. cjdb added a comment. uploads the right test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148677/new/ https://reviews.llvm.org/D148677 Files: clang/lib/Parse/ParseDeclCXX.cpp

[PATCH] D148677: [clang] makes `__is_trivially_equality_comparable` available as a struct

2023-04-18 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb created this revision. cjdb added reviewers: aaron.ballman, erichkeane, shafik, dblaikie. Herald added a project: All. cjdb requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Since this was originally a name in library, it needs an

[PATCH] D147717: [C++20][NFC] Claim full support for consteval again

2023-04-17 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. I'm gonna get started on this today! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147717/new/ https://reviews.llvm.org/D147717 ___ cfe-commits mailing list

[PATCH] D147888: Update declaration message of extern linkage

2023-04-17 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. I think we should fundamentally rethink this entire category of diagnostic. Rather than having a static diagnostic per offence stating //what// happened, we should instead have a single diagnostic that captures both what happened, why it's bad, and how to fix it.

[PATCH] D147904: [Clang] Fix cast to BigIntType in hasUniqueObjectRepresentations

2023-04-10 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb accepted this revision. cjdb added a comment. This revision is now accepted and ready to land. LGTM, thanks for such a quick fix on a weekend :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147904/new/ https://reviews.llvm.org/D147904

[PATCH] D147875: [clang][Diagnostics] WIP: Show line numbers when printing code snippets

2023-04-10 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. I have no opinion on this addition. If folks find it useful in GCC, happy to see it added. Comment at: clang/lib/Frontend/TextDiagnostic.cpp:1139 +return 7; + return 0; +} I'd prefer this to be an assert rather than returning a

[PATCH] D147717: [C++20][NFC] Claim full support for consteval again

2023-04-06 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D147717#4248989 , @erichkeane wrote: > @cjdb has been running some GDB test suites against our compiler: I am > wondering if we could ask him to try the consteval ones too before we set > this? A lot of that work is manual

[PATCH] D147288: [clang][NFC] updates cxx_status for P2113R0

2023-03-31 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb abandoned this revision. cjdb added a comment. In D147288#4237413 , @royjacobson wrote: > There was some discussion of this last year in this review: > https://reviews.llvm.org/D128750 > > It's such an edge case that I don't think we should lose

[PATCH] D144522: [clang-tidy] Add readability-operators-representation check

2023-03-31 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Thanks so much for seeing this through; I'm unusually looking forward to rebuilding LLVM this weekend! Comment at: clang-tools-extra/docs/clang-tidy/checks/readability/operators-representation.rst:82 + +.. option:: OverloadedOperators +

  1   2   3   4   5   >