Topic: N2284: Some system_error issues
Author: =?iso-8859-1?q?Daniel_Kr=FCgler?= <daniel.kruegler@googlemail.com>
Date: Sun, 24 Jun 2007 15:54:43 CST Raw View
1) The synopsis of std::system_error in [syserr.syserr.overview]
should add the following line as the last part of the class
definition:
private:
mutable string msg; // For exposition only
Otherwise the implementation hint provided in p. 6 seems
incomplete.
2) In [syserr.syserr.overview] we have the class definition of
std::system_error. In contrast to all exception classes, which
are constructible with a what_arg string (see [std.exceptions],
or ios_base::failure in [ios::failure]), only overloads with with
const string& are possible. For consistency with the re-designed
remaining exception classes this class should also provide
c'tors which accept a const char* what_arg string.
Please note that this proposed addition makes sense even
considering the given implementation hint for what(), because
what_arg is required to be set as what_arg of the base class
runtime_error, which now has the additional c'tor overload
accepting a const char*.
Greetings from Bremen,
Daniel Kr gler
---
[ 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 ]
[ --- Please see the FAQ before posting. --- ]
[ FAQ: http://www.comeaucomputing.com/csc/faq.html ]
Author: pete@versatilecoding.com (Pete Becker)
Date: Mon, 25 Jun 2007 00:30:06 GMT Raw View
Daniel Kr=FCgler wrote:
> 1) The synopsis of std::system_error in [syserr.syserr.overview]
> should add the following line as the last part of the class
> definition:
>=20
> private:
> mutable string msg; // For exposition only
>=20
> Otherwise the implementation hint provided in p. 6 seems
> incomplete.
>=20
I'll think about it, but my initial inclination is to leave it as it is.=20
First, it's a hint, not a requirement. Second, it's in a note, so it's=20
not a requirement. <g> Yes, the hint is incomplete. I don't see any harm=20
in that.
--=20
-- Pete
Roundhouse Consulting, Ltd. (www.versatilecoding.com)
Author of "The Standard C++ Library Extensions: a Tutorial and=20
Reference." (www.petebecker.com/tr1book)
---
[ 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 ]
[ --- Please see the FAQ before posting. --- ]
[ FAQ: http://www.comeaucomputing.com/csc/faq.html ]