Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c++ > #8687

Re: reading a file into std::string

From Nobody <nobody@nowhere.com>
Subject Re: reading a file into std::string
Date 2011-08-12 05:00 +0100
Message-Id <pan.2011.08.12.04.00.23.833000@nowhere.com>
Newsgroups comp.lang.c++
References (6 earlier) <4e40d7a6$0$310$14726298@news.sunsite.dk> <j1rnh3$fo$1@dont-email.me> <4e4275ed$0$306$14726298@news.sunsite.dk> <pan.2011.08.11.07.57.41.711000@nowhere.com> <9ahqgnFlk2U1@mid.individual.net>
Organization Zen Internet

Show all headers | View raw


On Thu, 11 Aug 2011 12:51:10 +0200, Bo Persson wrote:

>>> That is strange. I thought both <istream> and <ostream> were
>>> children of parent class <iostream> and they will inherit
>>> std::endl from <iostream>.
>>
>> <istream>, <ostream> and <iostream> are headers, not classes,
>> although classes with those names exist.
>>
>> Also, std::endl() is a function, not a method.
> 
> And even better (or worse?) is that iostream inherits from both 
> istream and ostream, not the other way round.

Right. istream and ostream inherit from ios, the common base class for
all streams. iostream is the input-AND-output stream class (i.e.
read-write streams, analogous to fopen()'s "plus" modes: r+/w+/a+).

Back to comp.lang.c++ | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

reading a file into std::string arnuld <sunrise@invalid.address> - 2011-08-08 13:15 +0000
  Re: reading a file into std::string Marc <marc.glisse@gmail.com> - 2011-08-08 13:40 +0000
  Re: reading a file into std::string Sam <sam@email-scan.com> - 2011-08-08 08:58 -0500
    Re: reading a file into std::string Sam <sam@email-scan.com> - 2011-08-08 09:05 -0500
      Re: reading a file into std::string red floyd <no.spam.here@its.invalid> - 2011-08-08 13:23 -0700
        Re: reading a file into std::string arnuld <sunrise@invalid.address> - 2011-08-09 05:13 +0000
          Re: reading a file into std::string red floyd <no.spam.here@its.invalid> - 2011-08-08 23:12 -0700
            Re: reading a file into std::string arnuld <sunrise@invalid.address> - 2011-08-09 06:45 +0000
              Re: reading a file into std::string red floyd <no.spam.here@its.invalid> - 2011-08-09 09:26 -0700
                Re: reading a file into std::string arnuld <sunrise@invalid.address> - 2011-08-10 10:58 +0000
                Re: reading a file into std::string "Bo Persson" <bop@gmb.dk> - 2011-08-10 16:19 +0200
                Re: reading a file into std::string red floyd <no.spam.here@its.invalid> - 2011-08-10 10:06 -0700
              Re: reading a file into std::string red floyd <no.spam.here@its.invalid> - 2011-08-09 09:28 -0700
              Re: reading a file into std::string red floyd <no.spam.here@its.invalid> - 2011-08-09 09:33 -0700
                Re: reading a file into std::string arnuld <sunrise@invalid.address> - 2011-08-10 12:13 +0000
                Re: reading a file into std::string Nobody <nobody@nowhere.com> - 2011-08-11 08:57 +0100
                Re: reading a file into std::string "Bo Persson" <bop@gmb.dk> - 2011-08-11 12:51 +0200
                Re: reading a file into std::string Nobody <nobody@nowhere.com> - 2011-08-12 05:00 +0100
      Re: reading a file into std::string Nana J. Osei <mppccf0987@att.net> - 2011-08-13 23:18 +0000
        Re: reading a file into std::string Sam <sam@email-scan.com> - 2011-08-13 20:58 -0500
    Re: reading a file into std::string Juha Nieminen <nospam@thanks.invalid> - 2011-08-09 11:26 +0000
      Re: reading a file into std::string Marc <marc.glisse@gmail.com> - 2011-08-09 12:54 +0000
        Re: reading a file into std::string Juha Nieminen <nospam@thanks.invalid> - 2011-08-09 16:33 +0000
          Re: reading a file into std::string Marc <marc.glisse@gmail.com> - 2011-08-09 16:47 +0000
            Re: reading a file into std::string red floyd <no.spam.here@its.invalid> - 2011-08-09 11:27 -0700
              Re: reading a file into std::string Joshua Maurice <joshuamaurice@gmail.com> - 2011-08-11 15:34 -0700
                Re: reading a file into std::string Juha Nieminen <nospam@thanks.invalid> - 2011-08-12 05:47 +0000
      Re: reading a file into std::string arnuld <sunrise@invalid.address> - 2011-08-09 12:57 +0000
        Re: reading a file into std::string Joshua Maurice <joshuamaurice@gmail.com> - 2011-08-11 15:40 -0700
  Re: reading a file into std::string Jean-Luc Romano <jl_post@hotmail.com> - 2011-08-12 11:28 -0700
    Re: reading a file into std::string Lynn McGuire <lmc@winsim.com> - 2011-08-12 15:56 -0500

csiph-web