This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Using incomplete types to instantiate STL-Templates?
- From: Wolfgang Bangerth <bangerth at ices dot utexas dot edu>
- To: Gabriel Dos Reis <gdr at integrable-solutions dot net>
- Cc: gcc at gcc dot gnu dot org, Christian Ehrhardt <ehrhardt at mathematik dot uni-ulm dot de>
- Date: Wed, 30 Apr 2003 15:13:26 -0500 (CDT)
- Subject: Re: Using incomplete types to instantiate STL-Templates?
> | I think that's weird, and
> | personally consider it a defect in the way the concepts checks are
> | implemented.
>
> STL concepts checking in pure C++ is a tough task. I would be pleased to
> read your implementations :-)
Fair enough. I didn't imply any blame in my wording -- heck, all my job in
gcc is pointing out errors in some part of gcc or other ;-) If I had to
fix them all, I'd have a problem...
What I thought is that deferring concepts check to the time we actually
instantiate an object might be done by placing the check machinery into
the constructors, since that's the first place we end up in anyway.
[Thinks] Actually, that's not true -- you might just be passed a pointer
and call member functions from there. So one would have to duplicate
concepts checks in _all_ member functions. Nope, I don't think we want to
do that.
I think I now see what you mean :-) That being said, I still think it's a
defect, even though it may be impossible to fix it.
Time for constraints on template parameters...
W.
-------------------------------------------------------------------------
Wolfgang Bangerth email: bangerth@ices.utexas.edu
www: http://www.ices.utexas.edu/~bangerth/