* [PATCH] libiberty: d-demangle: use distinguishable tuple()
@ 2021-10-13 15:34 Luís Ferreira
2021-10-13 15:42 ` Luís Ferreira
0 siblings, 1 reply; 3+ messages in thread
From: Luís Ferreira @ 2021-10-13 15:34 UTC (permalink / raw)
To: gcc-patches; +Cc: Luís Ferreira
Since Tuple!() is templated type from standard library, this can make two
demangled names undistinguishable.
Signed-off-by: Luís Ferreira <contact@lsferreira.net>
libiberty/ChangeLog:
* d-demangle.c (dlang_parse_tuple): use tuple() instead of Tuple!()
---
libiberty/d-demangle.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libiberty/d-demangle.c b/libiberty/d-demangle.c
index 880f2ec85a4..5dbdc36adbe 100644
--- a/libiberty/d-demangle.c
+++ b/libiberty/d-demangle.c
@@ -1711,7 +1711,7 @@ dlang_parse_tuple (string *decl, const char *mangled, struct dlang_info *info)
if (mangled == NULL)
return NULL;
- string_append (decl, "Tuple!(");
+ string_append (decl, "tuple(");
while (elements--)
{
--
2.33.0
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] libiberty: d-demangle: use distinguishable tuple()
2021-10-13 15:34 [PATCH] libiberty: d-demangle: use distinguishable tuple() Luís Ferreira
@ 2021-10-13 15:42 ` Luís Ferreira
2021-10-13 16:05 ` Luís Ferreira
0 siblings, 1 reply; 3+ messages in thread
From: Luís Ferreira @ 2021-10-13 15:42 UTC (permalink / raw)
To: gcc-patches
[-- Attachment #1: Type: text/plain, Size: 999 bytes --]
On Wed, 2021-10-13 at 16:34 +0100, Luís Ferreira wrote:
> Since Tuple!() is templated type from standard library, this can make
> two
> demangled names undistinguishable.
>
> Signed-off-by: Luís Ferreira <contact@lsferreira.net>
>
> libiberty/ChangeLog:
>
> * d-demangle.c (dlang_parse_tuple): use tuple() instead of
> Tuple!()
> ---
> libiberty/d-demangle.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/libiberty/d-demangle.c b/libiberty/d-demangle.c
> index 880f2ec85a4..5dbdc36adbe 100644
> --- a/libiberty/d-demangle.c
> +++ b/libiberty/d-demangle.c
> @@ -1711,7 +1711,7 @@ dlang_parse_tuple (string *decl, const char
> *mangled, struct dlang_info *info)
> if (mangled == NULL)
> return NULL;
>
> - string_append (decl, "Tuple!(");
> + string_append (decl, "tuple(");
>
> while (elements--)
> {
I need to update tests
--
Sincerely,
Luís Ferreira @ lsferreira.net
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] libiberty: d-demangle: use distinguishable tuple()
2021-10-13 15:42 ` Luís Ferreira
@ 2021-10-13 16:05 ` Luís Ferreira
0 siblings, 0 replies; 3+ messages in thread
From: Luís Ferreira @ 2021-10-13 16:05 UTC (permalink / raw)
To: gcc-patches
[-- Attachment #1: Type: text/plain, Size: 1152 bytes --]
On Wed, 2021-10-13 at 16:42 +0100, Luís Ferreira wrote:
> On Wed, 2021-10-13 at 16:34 +0100, Luís Ferreira wrote:
> > Since Tuple!() is templated type from standard library, this can
> > make
> > two
> > demangled names undistinguishable.
> >
> > Signed-off-by: Luís Ferreira <contact@lsferreira.net>
> >
> > libiberty/ChangeLog:
> >
> > * d-demangle.c (dlang_parse_tuple): use tuple() instead of
> > Tuple!()
> > ---
> > libiberty/d-demangle.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/libiberty/d-demangle.c b/libiberty/d-demangle.c
> > index 880f2ec85a4..5dbdc36adbe 100644
> > --- a/libiberty/d-demangle.c
> > +++ b/libiberty/d-demangle.c
> > @@ -1711,7 +1711,7 @@ dlang_parse_tuple (string *decl, const char
> > *mangled, struct dlang_info *info)
> > if (mangled == NULL)
> > return NULL;
> >
> > - string_append (decl, "Tuple!(");
> > + string_append (decl, "tuple(");
> >
> > while (elements--)
> > {
>
> I need to update tests
>
Updated on PATCH v2.
--
Sincerely,
Luís Ferreira @ lsferreira.net
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-10-13 16:05 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-13 15:34 [PATCH] libiberty: d-demangle: use distinguishable tuple() Luís Ferreira
2021-10-13 15:42 ` Luís Ferreira
2021-10-13 16:05 ` Luís Ferreira
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).