This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: std::ofstream
- To: Benjamin Kosnik <bkoz at redhat dot com>
- Subject: Re: std::ofstream
- From: Dean Hoover <dhoover at rochester dot rr dot com>
- Date: Wed, 18 Jul 2001 14:46:01 -0400
- CC: libstdc++ at gcc dot gnu dot org
- References: <Pine.SOL.3.91.1010718112516.28924C-100000@taarna.cygnus.com>
- Reply-To: dhoover at acm dot org
Benjamin Kosnik wrote:
> > #include <iostream>
> >
> > int main()
> > {
> > std::ofstream file("xyz.out", std::ios::out|std::ios::app);
> > }
>
> > Am I in error somewhere?
>
> Yes: std::ofstream is in <fstream>. You'll need to include that file.
>
> -benjamin
thanks. that worked.