[PATCH] D134453: Disambiguate type names when printing NTTP types

2022-10-19 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT updated this revision to Diff 468881. DoDoENT retitled this revision from "Introduce the `AlwaysIncludeTypeForNonTypeTemplateArgument` into printing policy" to "Disambiguate type names when printing NTTP types". DoDoENT edited the summary of this revision. DoDoENT added a comment. Implem

[PATCH] D134453: Disambiguate type names when printing NTTP types

2022-10-19 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT updated this revision to Diff 468883. DoDoENT added a comment. Update comment/documentation of the new policy to correctly reflect the change in previous diff. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134453/new/ https://reviews.llvm.

[PATCH] D134453: Disambiguate type names when printing NTTP types

2022-10-19 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT added a comment. In D134453#3868789 , @dblaikie wrote: > I still don't think "keep full NTTP type printing behind a policy, for those > that want/need that" is a policy we should add. String printed names aren't > meant to be a tool for type ref

[PATCH] D134453: Disambiguate type names when printing NTTP types

2022-10-20 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT added a comment. > (rabbit hole/tangent: Arguably what might be more useful to the user might be > a name that's not even usable in C++ - using the member variable names, as > well as the type names, though that'd be even more verbose... like > `t1` - which, I guess, if you had user def

[PATCH] D134453: Disambiguate type names when printing NTTP types

2022-10-26 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT added a comment. > My thinking is that it's always more frustrating to have not enough > information in a diagnostic than too much information (both are problems in > their own ways though). > ... > I can understand it being less readable for deep nesting situations, but I do > not see

[PATCH] D134453: Disambiguate type names when printing NTTP types

2022-10-27 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT updated this revision to Diff 471081. DoDoENT edited the summary of this revision. DoDoENT added a comment. Removed the policy and full explicit type printing behind it and keep only printing of first type name, as suggested by the review. This is essentially (2) from here: https://revie

[PATCH] D134453: Disambiguate type names when printing NTTP types

2022-10-27 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT updated this revision to Diff 471083. DoDoENT added a comment. Restored trailing whitespace on untouched line that was automatically deleted by editor's save action. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134453/new/ https://reviews

[PATCH] D134453: Disambiguate type names when printing NTTP types

2022-10-27 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT updated this revision to Diff 471145. DoDoENT added a comment. Updated clang release notes about improvement to diagnostics as requested by reviewers and added more vim-specific temp files to .gitignore. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.

[PATCH] D134453: Disambiguate type names when printing NTTP types

2022-10-27 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT added a comment. > Do you need someone to land these changes on your behalf? If so, please let > me know what name and email address you'd like used for patch attribution. Yes. My name is Nenad Mikša, e-mail address: dodoentertainm...@gmail.com Comment at: .gitignore:

[PATCH] D134453: Disambiguate type names when printing NTTP types

2022-10-27 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT updated this revision to Diff 471174. DoDoENT added a comment. updated new tests that appeared after rebasing to main and removed vim-specific files from .gitignore (I'll keep that downstream). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D

[PATCH] D134453: Disambiguate type names when printing NTTP types

2022-10-27 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT updated this revision to Diff 471204. DoDoENT added a comment. apply git-clang-format to changed files Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134453/new/ https://reviews.llvm.org/D134453 Files: clang/docs/ReleaseNotes.rst clang/

[PATCH] D134453: Introduce the `AlwaysIncludeTypeForNonTypeTemplateArgument` into printing policy

2022-09-22 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT created this revision. Herald added a project: All. DoDoENT requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. If enabled, it will ensure that full type name is always printed. This should fix issue reported here: https://github.com/l

[PATCH] D134453: Introduce the `AlwaysIncludeTypeForNonTypeTemplateArgument` into printing policy

2022-09-22 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT added inline comments. Comment at: clang/include/clang/AST/PrettyPrinter.h:307 + /// decltype(s) will be printed as "S" if enabled and as "S<{1,2}>" if disabled, + /// regardless if PrintCanonicalTypes is enabled. + unsigned AlwaysIncludeTypeForNonTypeTemplateArgument

[PATCH] D134453: Introduce the `AlwaysIncludeTypeForNonTypeTemplateArgument` into printing policy

2022-09-23 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT added inline comments. Comment at: clang/include/clang/AST/PrettyPrinter.h:307 + /// decltype(s) will be printed as "S" if enabled and as "S<{1,2}>" if disabled, + /// regardless if PrintCanonicalTypes is enabled. + unsigned AlwaysIncludeTypeForNonTypeTemplateArgument

[PATCH] D134453: Introduce the `AlwaysIncludeTypeForNonTypeTemplateArgument` into printing policy

2022-09-24 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT added inline comments. Comment at: clang/include/clang/AST/PrettyPrinter.h:307 + /// decltype(s) will be printed as "S" if enabled and as "S<{1,2}>" if disabled, + /// regardless if PrintCanonicalTypes is enabled. + unsigned AlwaysIncludeTypeForNonTypeTemplateArgument

[PATCH] D134453: Introduce the `AlwaysIncludeTypeForNonTypeTemplateArgument` into printing policy

2022-09-25 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT added inline comments. Comment at: clang/include/clang/AST/PrettyPrinter.h:307 + /// decltype(s) will be printed as "S" if enabled and as "S<{1,2}>" if disabled, + /// regardless if PrintCanonicalTypes is enabled. + unsigned AlwaysIncludeTypeForNonTypeTemplateArgument

[PATCH] D134453: Introduce the `AlwaysIncludeTypeForNonTypeTemplateArgument` into printing policy

2022-09-28 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT added inline comments. Comment at: clang/include/clang/AST/PrettyPrinter.h:307 + /// decltype(s) will be printed as "S" if enabled and as "S<{1,2}>" if disabled, + /// regardless if PrintCanonicalTypes is enabled. + unsigned AlwaysIncludeTypeForNonTypeTemplateArgument

[PATCH] D134453: Introduce the `AlwaysIncludeTypeForNonTypeTemplateArgument` into printing policy

2022-09-29 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT added a comment. > Generally the way to do it, if you want to introspect into the type, its > template parameters, etc, then yes, keeping pointers to the AST or reparsing > the name with Clang as-needed, would be the way to go - or walking the AST > up-front and generating your own data

[PATCH] D134453: Introduce the `AlwaysIncludeTypeForNonTypeTemplateArgument` into printing policy

2022-09-30 Thread Nenad Mikša via Phabricator via cfe-commits
DoDoENT added a comment. > Right - I'm trying to understand what your overall goals are and what clang > needs to facilitate them, if it's suitable to do so. And it seems to me that > the right way to support them, is for your approach to change - not to rely > on the type printing to communica