This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Can't match void parameters for empty parms in ptr-mem-functions.
- To: "Martin v. Loewis" <martin at loewis dot home dot cs dot tu-berlin dot de>
- Subject: Re: Can't match void parameters for empty parms in ptr-mem-functions.
- From: Benjamin Scherrey <scherrey at switchco dot com>
- Date: Mon, 28 Feb 2000 19:10:39 -0500
- CC: scherrey at proteus-tech dot com, gcc at gcc dot gnu dot org
- Organization: Proteus Technologies, Inc.
- References: <38B4EF14.DAE79090@switchco.com> <200002241020.LAA01208@loewis.home.cs.tu-berlin.de>
- Reply-To: scherrey at proteus-tech dot com
Thanx for the pointer, Martin. Meanwhile, with some help from a fellow
programmer, I've come up with what should be a compliant solution to
my problem using traits characteristics and template specialization.
Unfortunately, g++ doesn't seem to cope with it and I'm having trouble
determining if my code is at fault or some feature I'm trying to use
simply isn't implemented or is broken. Attached is the revised code
which fails to compile. This time, however, the error message appears
nonsensical because in its "failure to match..." error, the first
candidate it suggests matches exactly!
Any ideas?
Ben Scherrey
"Martin v. Loewis" wrote:
> I believe your code is illformed, the instantiation of the template
> Matcher< Test, bool, void > already fails. 14.8.2, [temp.deduct]/2 says
>
> # ... Type deduction may fail for the following reasons: ...
> # Attempting to create a function type in which a parameter has a type
> # of void.
match.cpp