Afficher un message
Vieux 12/12/2007, 16h51   #9
Pete Becker
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: std::wcout and const char *

On 2007-12-12 10:28:09 -0500, James Kanze <james.kanze@gmail.com> said:

> On Dec 12, 2:40 pm, Stefan Naewe <nos...@please.net> wrote:
>
>> But really: Who cares in this case if it just works (with some
>> modifications and only (?) with g++ (see my other post)) ?

>
> Does it work? It might, or it might not. Or it might work some
> of the time, and not others. There are things you can
> reasonably define in std::, and expect to get away with it. But
> this isn't one of them.
>


But as a short-term debugging aid, this is fine: if it detects
problems, you fix them. Once you've done that, you remove it. I've
occasionally gone so far as to add #error statements to standard
headers when I couldn't figure out why some header was being included
in a bogus context. (One of the Windows headers pulls in <stdlib.h>
while inside an extern "C" block. Sigh.)

--
Pete
Roundhouse Consulting, Ltd. (www.versatilecoding.com) Author of "The
Standard C++ Library Extensions: a Tutorial and Reference
(www.petebecker.com/tr1book)

  Réponse avec citation
 
Page generated in 0,04843 seconds with 9 queries