Topic: std::ios::unsetf does not return


Author: a9804814@unet.univie.ac.at (Thomas Mang)
Date: Mon, 18 Nov 2002 16:12:30 +0000 (UTC)
Raw View
Hi everybody,


In std::ios (and certainly std::ios_base<..>) there are some member
functions to set/get the current formatting flags.

Of them, both overloaded versions of 'setf' and 'flags' return the old
formatting flags.
Only one, 'unsetf', does not return anything.


Why this inconsistency?

In practice, none of them except the normal get-function 'flags()'
would have to return the old value, 'flags()' is sufficient if the old
value matters.

But if all others return the old flags, I do not see a good reasoning
having 'unsetf' return void.


best regards,

Thomas

---
[ 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.jamesd.demon.co.uk/csc/faq.html                       ]