From -3966855669360744686
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f78e5,a4a0f2ad834f7335
X-Google-Attributes: gidf78e5,public
From: Oleg Zabluda <zabluda@math.psu.edu>
Subject: Re: [io]fstreams ctors
Date: 1998/02/02
Message-ID: <6b2f7c$uqj@marianna.psu.edu>#1/1
X-Deja-AN: 321778695
References: <34CF78BF.5718@pratique.fr> <6aoof1$c9d$1@shell7.ba.best.com> <34D20BFB.5736@pratique.fr>
X-Original-Date: 1 Feb 1998 13:34:20 -0500
X-Server-Date: 1 Feb 1998 17:38:29 GMT
Reply-To: zabluda@math.psu.edu (Oleg Zabluda)
Originator: austern@isolde.mti.sgi.com
Organization: Penn State University, Center for Academic Computing
X-Auth: PGPMoose V1.1 PGP comp.std.c++ iQBVAwUBNNYOz0y4NqrwXLNJAQHUyQH/cVWA2zlSF4dZYbgTIrpkPWVVSovqTyrL fkEzhMogDAFt4ppHLJYeMB3CtcmVAfVTJIL58H7MebG81MvoFMoIdQ== =VZmY
Newsgroups: comp.std.c++


Valentin Bonnard <bonnardv@pratique.fr> wrote:
: Nathan Myers wrote:
: > 
: > Valentin Bonnard  <bonnardv@pratique.fr> wrote:
: > >fstreams ctors only take const char*, not wstring
: > >or at least const charT*. Is it intentionnal ?
: > >Is it an oversight ?
: > 
: > It is a "permitted extension" to provide more constructors,
: > as long as it can't change the behavior of a conforming program.

: class SillyConverter
: {
: public:
:     operator const char* ();
:     operator const charT* ();
:     operator string ();
: } s;

: ifstream ifs (s);

Hmm... It seems like your example shows that the "permitted extention",
Nathan refers to, is actually _never_ permitted.

Oleg.
-- 
Life is a sexually transmitted, 100% lethal disease.
---
[ comp.std.c++ is moderated.  To submit articles: Try just posting with your 
                newsreader.  If that fails, use mailto:std-c++@ncar.ucar.edu
  comp.std.c++ FAQ: http://reality.sgi.com/austern/std-c++/faq.html
  Moderation policy: http://reality.sgi.com/austern/std-c++/policy.html
  Comments? mailto:std-c++-request@ncar.ucar.edu 
]



