public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* Re: c++/6432: __builtin_apply() rejected by g++ - per PR 102
@ 2002-04-23 16:58 jason
  0 siblings, 0 replies; 6+ messages in thread
From: jason @ 2002-04-23 16:58 UTC (permalink / raw)
  To: colin, gcc-bugs, gcc-prs, nobody

Synopsis: __builtin_apply() rejected by g++ - per PR 102

State-Changed-From-To: open->analyzed
State-Changed-By: jason
State-Changed-When: Tue Apr 23 16:58:41 2002
State-Changed-Why:
    As Gaby said when closing PR 102, you can make this work by casting fn1 to (void (*)(...)) instead of (void (*)()).

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


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

* Re: c++/6432: __builtin_apply() rejected by g++ - per PR 102
@ 2002-04-26  2:10 nathan
  0 siblings, 0 replies; 6+ messages in thread
From: nathan @ 2002-04-26  2:10 UTC (permalink / raw)
  To: colin, gcc-bugs, gcc-prs, nobody

Synopsis: __builtin_apply() rejected by g++ - per PR 102

State-Changed-From-To: analyzed->closed
State-Changed-By: nathan
State-Changed-When: Fri Apr 26 02:10:46 2002
State-Changed-Why:
    this is fixed on mainline and 3.1 branch

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


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

* Re: c++/6432: __builtin_apply() rejected by g++ - per PR 102
@ 2002-04-23 18:46 Jason Merrill
  0 siblings, 0 replies; 6+ messages in thread
From: Jason Merrill @ 2002-04-23 18:46 UTC (permalink / raw)
  To: nobody; +Cc: gcc-prs

The following reply was made to PR c++/6432; it has been noted by GNATS.

From: Jason Merrill <jason@redhat.com>
To: Colin McCormack <colin@field.medicine.adelaide.edu.au>
Cc: gcc-bugs@gcc.gnu.org, gcc-gnats@gcc.gnu.org
Subject: Re: c++/6432: __builtin_apply() rejected by g++ - per PR 102
Date: Wed, 24 Apr 2002 02:43:54 +0100

 >>>>> "Colin" == Colin McCormack <colin@field.medicine.adelaide.edu.au> writes:
 
 > On Wednesday 24 April 2002 09:58, jason@gcc.gnu.org wrote:
 >> As Gaby said when closing PR 102, you can make this work by casting fn1
 >> to (void (*)(...)) instead of (void (*)()).
 
 > Gaby must, as far as I can tell, have been compiling it under gcc and not
 > g++.
 
 More likely, he was compiling it under g++ 3.0.4 or the 3.1 branch, where
 it works fine.  I've verified that it doesn't work under 2.95, but that's
 unlikely to change, as nobody's working on 2.95 anymore.
 
 Jason


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

* Re: c++/6432: __builtin_apply() rejected by g++ - per PR 102
@ 2002-04-23 17:16 Andrew Pinski
  0 siblings, 0 replies; 6+ messages in thread
From: Andrew Pinski @ 2002-04-23 17:16 UTC (permalink / raw)
  To: nobody; +Cc: gcc-prs

The following reply was made to PR c++/6432; it has been noted by GNATS.

From: Andrew Pinski <pinskia@physics.uc.edu>
To: colin@field.medicine.adelaide.edu.au
Cc: gcc-gnats@gcc.gnu.org
Subject: Re: c++/6432: __builtin_apply() rejected by g++ - per PR 102
Date: Tue, 23 Apr 2002 20:03:38 -0400

 No the old PR was closed because it was fixed in a latter version like 
 3.0.
 With your example I receive an error of
 g++ temp2.cc
 temp2.cc: In function `void fn(int)':
 temp2.cc:5: invalid conversion from `void (*)()' to `void (*)(...)'
 
 So it looks like it has been fixed.
 
 
 Thanks,
 Andrew Pinski
 


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

* Re: c++/6432: __builtin_apply() rejected by g++ - per PR 102
@ 2002-04-23 17:16 Colin McCormack
  0 siblings, 0 replies; 6+ messages in thread
From: Colin McCormack @ 2002-04-23 17:16 UTC (permalink / raw)
  To: nobody; +Cc: gcc-prs

The following reply was made to PR c++/6432; it has been noted by GNATS.

From: Colin McCormack <colin@field.medicine.adelaide.edu.au>
To: jason@gcc.gnu.org, gcc-bugs@gcc.gnu.org, gcc-prs@gcc.gnu.org,
	nobody@gcc.gnu.org, gcc-gnats@gcc.gnu.org
Cc:  
Subject: Re: c++/6432: __builtin_apply() rejected by g++ - per PR 102
Date: Wed, 24 Apr 2002 10:09:29 +1000

 On Wednesday 24 April 2002 09:58, jason@gcc.gnu.org wrote:
 > As Gaby said when closing PR 102, you can make this work by casting fn1
 > to (void (*)(...)) instead of (void (*)()).
 
 Gaby was mistaken.
 
 Gaby must, as far as I can tell, have been compiling it under gcc and not g++.
 
 Evidence (code modified as per Gaby's suggestion):
 
 extern void fn1();
 void fn (int b){
    __builtin_apply( (void (*)(...))fn1,
                    __builtin_apply_args(),
                    32);
 }
 
 Output:
 g++ builtin_apply.cc
 builtin_apply.cc: In function `void fn(int)':
 builtin_apply.cc:5: argument passing to `void * ()(unsigned int)' from `void 
 *'
 Compilation exited abnormally with code 1 at Wed Apr 24 10:01:44
 
 Conclusion:
 
 Problem still exists.
 
 Please re-open the PR.
 
 Colin.
 
 On Wednesday 24 April 2002 09:58, jason@gcc.gnu.org wrote:
 > Synopsis: __builtin_apply() rejected by g++ - per PR 102
 >
 > State-Changed-From-To: open->analyzed
 > State-Changed-By: jason
 > State-Changed-When: Tue Apr 23 16:58:41 2002
 > State-Changed-Why:
 >     As Gaby said when closing PR 102, you can make this work by casting fn1
 > to (void (*)(...)) instead of (void (*)()).
 >
 > 
 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=6432


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

* c++/6432: __builtin_apply() rejected by g++ - per PR 102
@ 2002-04-23 16:46 colin
  0 siblings, 0 replies; 6+ messages in thread
From: colin @ 2002-04-23 16:46 UTC (permalink / raw)
  To: gcc-gnats


>Number:         6432
>Category:       c++
>Synopsis:       __builtin_apply() rejected by g++ - per PR 102
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    unassigned
>State:          open
>Class:          rejects-legal
>Submitter-Id:   net
>Arrival-Date:   Tue Apr 23 16:46:02 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Colin McCormack
>Release:        gcc version 2.95.4 20011002 (Debian prerelease)
>Organization:
>Environment:
System: Linux colin.sharedtech.dyndns.org 2.4.18-686 #2 Wed Mar 20 20:21:31 EST 2002 i686 unknown
Architecture: i686

	
host: i686-pc-linux-gnu
build: i686-pc-linux-gnu
target: i686-pc-linux-gnu
>Description:
g++ rejects all possible constructions of __builtin_apply() by requiring the second argument to be of an impossible type, with an error: argument passing to `void * ()(unsigned int)' from `void *'.  Please note the impossible type `void * () (unsigned int)'

>How-To-Repeat:
run g++ over the following code:
----
extern void fn1();
void fn (int b){
   __builtin_apply( (void (*)())fn1,
                   __builtin_apply_args(),
                   32);
}
----
NB: this bug was reported in Problem Report 102 on March 12th 2000, and was closed in error.  The bug is, and has been, causing my GPL'd project a great deal of difficulty, and its fix should be straight forward.
>Fix:
There is no fix or workaround possible within g++

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


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

end of thread, other threads:[~2002-04-26  9:10 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-04-23 16:58 c++/6432: __builtin_apply() rejected by g++ - per PR 102 jason
  -- strict thread matches above, loose matches on Subject: below --
2002-04-26  2:10 nathan
2002-04-23 18:46 Jason Merrill
2002-04-23 17:16 Andrew Pinski
2002-04-23 17:16 Colin McCormack
2002-04-23 16:46 colin

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