Topic: auto_ptr as a member function
Author: rkdious@ix.netcom.com (Daniel)
Date: 1996/07/19 Raw View
Is it possible to have a member of type auto_ptr in a class? How would this
work.
-Daniel
[ comp.std.c++ is moderated. To submit articles: try just posting with ]
[ your news-reader. If that fails, use mailto:std-c++@ncar.ucar.edu ]
[ FAQ: http://reality.sgi.com/employees/austern_mti/std-c++/faq.html ]
[ Policy: http://reality.sgi.com/employees/austern_mti/std-c++/policy.html ]
[ Comments? mailto:std-c++-request@ncar.ucar.edu ]
Author: jodle@bix.com (jodle)
Date: 1996/07/21 Raw View
Daniel (rkdious@ix.netcom.com) wrote:
: Is it possible to have a member of type auto_ptr in a class? How would this
: work.
auto_ptr is not a type. It is a template. It cannot be used as a member
of a class or any other kind of variable. auto_ptr<int> and auto_ptr<X>
(if X is a type) are types. You could have either of these as members of
a class, even in a class named X.
---
[ comp.std.c++ is moderated. To submit articles: try just posting with ]
[ your news-reader. If that fails, use mailto:std-c++@ncar.ucar.edu ]
[ FAQ: http://reality.sgi.com/employees/austern_mti/std-c++/faq.html ]
[ Policy: http://reality.sgi.com/employees/austern_mti/std-c++/policy.html ]
[ Comments? mailto:std-c++-request@ncar.ucar.edu ]