public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* Re: c++/5786: array template argument deduction from temporary
@ 2002-09-14 15:43 nathan
  0 siblings, 0 replies; 2+ messages in thread
From: nathan @ 2002-09-14 15:43 UTC (permalink / raw)
  To: david.abrahams, gcc-bugs, gcc-prs, nobody

Old Synopsis: [parser] array template argument deduction from temporary
New Synopsis: array template argument deduction from temporary

State-Changed-From-To: open->analyzed
State-Changed-By: nathan
State-Changed-When: Sat Sep 14 15:43:31 2002
State-Changed-Why:
    confirmed, I don't think this is parser related.

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=5786


^ permalink raw reply	[flat|nested] 2+ messages in thread

* c++/5786: array template argument deduction from temporary
@ 2002-02-26  9:44 david.abrahams
  0 siblings, 0 replies; 2+ messages in thread
From: david.abrahams @ 2002-02-26  9:44 UTC (permalink / raw)
  To: gcc-gnats


>Number:         5786
>Category:       c++
>Synopsis:       array template argument deduction from temporary
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Feb 26 09:06:01 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     David Abrahams
>Release:        3.0.3
>Organization:
>Environment:
Cygwin
>Description:
Various kinds of array argument deduction from temporaries fails. Some fraction of this may be correct behavior; EDG rejects most of these, too.

-Dave
>How-To-Repeat:
Compile the following:
template <class T, unsigned N>
void print1(T const (&x)[N])
{
}

template <class T, unsigned N, unsigned M>
void print2(T const (&x)[N][M])
{
}

template <class T, unsigned N>
void print3(T const(*x)[N])
{
}

template <class T, unsigned N>
void print4(T (*x)[N])
{
}

struct X { int x[2][4]; };

int main()
{
   print1(X().x);
   print2(X().x);
   print3(&X().x);
   print4(&X().x);
   return 0;
}
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-09-14 22:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-09-14 15:43 c++/5786: array template argument deduction from temporary nathan
  -- strict thread matches above, loose matches on Subject: below --
2002-02-26  9:44 david.abrahams

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).