
On Fri, Nov 6, 2009 at 5:13 PM, Beman Dawes <bdawes@acm.org> wrote:
On Fri, Nov 6, 2009 at 1:17 PM, Emil Dotchevski <emildotchevski@gmail.com> wrote:
On Fri, Nov 6, 2009 at 9:44 AM, Zachary Turner <divisortheory@gmail.com> wrote:
Is there anything that can be done to improve the error messages generated by the compiler when a copy fails to be made due to a boost::noncopyable?
Easy cure is to spell out the private declarations for the copy constructor and the assignment operator "by hand". We all know that this spells "non-copyable".
Because of C++0x deleted functions, the idiom for noncopyable is going to change. [...]
Interesting stuff, however... I'm not sure if any of that will help the errors. I haven't tried any experiments, but It looks to me that even if the compiler tells you exactly what class is not copyable, it doesn't tell you where the attempted copy is taking place. And I'm not sure if anything but a compiler fix will make it better. Tony