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

2023-07-14 Thread Takuya Shimizu 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 rG176981ac58d3: [clang][Diagnostics] Fix distant source ranges in bad-conversion notes (authored by hazohelet). Changed prior to commit: https://rev

[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 ___ cfe-commits

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

2023-07-06 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. @cjdb LGTY? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153359/new/ https://reviews.llvm.org/D153359 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

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

2023-07-03 Thread Takuya Shimizu via Phabricator via cfe-commits
hazohelet updated this revision to Diff 536743. hazohelet edited the summary of this revision. hazohelet added a comment. Edited release note so that it only mentions the clang 16 -> 17 changes, and not development internal ones CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153359/new/

[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 introduce

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

2023-06-30 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. @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 introduced during the clang 17 development.(?) For a 16 -> 17 transition, it probably caus

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

2023-06-29 Thread Takuya Shimizu via Phabricator via cfe-commits
hazohelet updated this revision to Diff 535801. hazohelet edited the summary of this revision. hazohelet added a comment. Address comment from cjdb - Added example code & before/after diagnostic display to release note Thanks for reminding! CHANGES SINCE LAST ACTION https://reviews.llvm.org/

[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] D153359: [clang][Diagnostics] Fix distant source ranges in bad-conversion notes

2023-06-28 Thread Takuya Shimizu via Phabricator via cfe-commits
hazohelet updated this revision to Diff 535433. hazohelet marked an inline comment as done. hazohelet edited the summary of this revision. hazohelet added a comment. Removed FIXME comment that is already addressed in D153690 CHANGES SINCE LAST ACTION https:/

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

2023-06-24 Thread Takuya Shimizu via Phabricator via cfe-commits
hazohelet marked an inline comment as done. hazohelet added inline comments. Comment at: clang/lib/Sema/SemaOverload.cpp:10821 +// FIXME: No test case for this. Can we remove this block? if (FromQs.hasUnaligned() != ToQs.hasUnaligned()) { cjdb wrote: >

[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 aa

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

2023-06-20 Thread Takuya Shimizu via Phabricator via cfe-commits
hazohelet marked 2 inline comments as done. hazohelet added a comment. Consider the following code. (I added another parameter to the original code so that the covered range becomes clearer) void func(int aa, int bb); void test() { func(1, "two"); } BEFORE this patch: source:4:15:

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

2023-06-20 Thread Takuya Shimizu via Phabricator via cfe-commits
hazohelet updated this revision to Diff 533142. hazohelet added a comment. Address comments from @tbaeder - Bind parameter source range rather than its declaration to variable. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153359/new/ https://reviews.llvm.org/D153359 Files: clang/li

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

2023-06-20 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. Can you post a before/after comparison of the exact output for that example? Comment at: clang/lib/Sema/SemaOverload.cpp:10752 QualType ToTy = Conv.Bad.getToType(); + ParmVarDecl *ToPVD = !isObjectArgument ? Fn->getParamDecl(I) : nullptr;

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

2023-06-20 Thread Takuya Shimizu via Phabricator via cfe-commits
hazohelet created this revision. hazohelet added reviewers: aaron.ballman, tbaeder, cjdb, shafik. Herald added a project: All. hazohelet requested review of this revision. Herald added a project: clang. Now that clang supports printing of multiple lines of code snippet in diagnostics, source rang