This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

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/



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]