This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Error report (gcc 3.1)


Hello - thank for your effort with gcc.  I had an error compiling a simple
program, and here follows a minimal example; the example is so minimal I
assume it is correct (and works with KAI's KCC).  Please, help...

----------------Begin output of g++ -v --help:
Reading specs from /usr/soft/lib/gcc-lib/i686-pc-linux-gnu/3.1/specs
Configured with: ../gcc-3.1/configure --prefix=/usr/soft
Thread model: single
gcc version 3.1

 /usr/soft/lib/gcc-lib/i686-pc-linux-gnu/3.1/cc1 -lang-c -v -D__GNUC__=3
-D__GNUC_MINOR__=1 -D__GNUC_PATCHLEVEL__=0 -D__ELF__ -Dunix
-D__gnu_linux__ -Dlinux -D__ELF__ -D__unix__ -D__gnu_linux__ -D__linux__
-D__unix -D__linux -Asystem=posix -D__NO_INLINE__ -D__STDC_HOSTED__=1
-Acpu=i386 -Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i686__
-D__tune_pentiumpro__ help-dummy -quiet -dumpbase help-dummy -version
--help -o /tmp/ccsv9G1s.s

----------------Begin file bar.cxx
#include <fstream>

int main() {
  std::ifstream is("foo.cxx");
  return 0;
}

----------------Begin output of g++ -o bar bar.cxx
In file included from /usr/soft/include/g++-v3/fstream:48,
                 from bar.cxx:1:
/usr/soft/include/g++-v3/bits/basic_file.h:52: parse error before `{' token
/usr/soft/include/g++-v3/bits/basic_file.h:57: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:57: function `int std::overflow(int
   = -1)' is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:60: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:60: function `int std::underflow()'
   is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:63: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:63: function `int std::uflow()' is
   initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:66: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:66: function `int
   std::pbackfail(int)' is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:69: parse error before `*' token
/usr/soft/include/g++-v3/bits/basic_file.h:69: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:69: function `streamsize
   std::xsputn(...)' is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:72: `_CharT' was not declared in
   this scope
/usr/soft/include/g++-v3/bits/basic_file.h:72: `__s' was not declared in this
   scope
/usr/soft/include/g++-v3/bits/basic_file.h:72: parse error before `)' token
/usr/soft/include/g++-v3/bits/basic_file.h:72: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:72: function `streamsize
   std::xsgetn(...)' is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:76: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:76: function `streamoff
   std::seekoff(long int, std::_Ios_Seekdir, std::_Ios_Openmode =
   std::operator|(std::_Ios_Openmode,
   std::_Ios_Openmode)((std::_Ios_Openmode)8, (std::_Ios_Openmode)16))' is
   initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:80: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:80: function `streamoff
   std::seekpos(long int, std::_Ios_Openmode =
   std::operator|(std::_Ios_Openmode,
   std::_Ios_Openmode)((std::_Ios_Openmode)8, (std::_Ios_Openmode)16))' is
   initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:83: `_CharT' was not declared in
   this scope
/usr/soft/include/g++-v3/bits/basic_file.h:83: `__b' was not declared in this
   scope
/usr/soft/include/g++-v3/bits/basic_file.h:83: parse error before `)' token
/usr/soft/include/g++-v3/bits/basic_file.h:83: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:83: function `std::streambuf*
   std::setbuf(...)' is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:86: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:86: function `int std::sync()' is
   initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:89: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:89: function `int std::doallocate()'
   is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:92: `_CharT' was not declared in
   this scope
/usr/soft/include/g++-v3/bits/basic_file.h:92: `__s' was not declared in this
   scope
/usr/soft/include/g++-v3/bits/basic_file.h:92: parse error before `)' token
/usr/soft/include/g++-v3/bits/basic_file.h:92: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:92: function `streamsize
   std::sys_read(...)' is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:95: parse error before `*' token
/usr/soft/include/g++-v3/bits/basic_file.h:95: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:95: function `streamsize
   std::sys_write(...)' is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:98: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:98: function `streamoff
   std::sys_seek(long int, std::_Ios_Seekdir)' is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:101: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:101: function `int std::sys_close()'
   is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:104: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:104: function `int
   std::sys_stat(void*)' is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:107: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:107: function `int std::showmanyc()'
   is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:110: virtual outside class
   declaration
/usr/soft/include/g++-v3/bits/basic_file.h:110: function `void
   std::imbue(void*)' is initialized like a variable
/usr/soft/include/g++-v3/bits/basic_file.h:133: parse error before `*' token
/usr/soft/include/g++-v3/bits/basic_file.h:136: parse error before `::' token
/usr/soft/include/g++-v3/bits/basic_file.h:141: type specifier omitted for
   parameter `ios_base'
/usr/soft/include/g++-v3/bits/basic_file.h:141: parse error before `::' token
/usr/soft/include/g++-v3/bits/basic_file.h:148: parse error before `::' token
/usr/soft/include/g++-v3/bits/basic_file.h:185: `streamsize' declared as a
   `virtual' field
/usr/soft/include/g++-v3/bits/basic_file.h:185: parse error before `(' token
/usr/soft/include/g++-v3/bits/basic_file.h:191: `streamsize' declared as a
   `virtual' field
/usr/soft/include/g++-v3/bits/basic_file.h:191: declaration of `int
   __basic_file<_CharT>::streamsize'
/usr/soft/include/g++-v3/bits/basic_file.h:185: conflicts with previous
   declaration `int __basic_file<_CharT>::streamsize'
/usr/soft/include/g++-v3/bits/basic_file.h:191: parse error before `(' token
/usr/soft/include/g++-v3/bits/basic_file.h:197: `streamoff' declared as a
   `virtual' field
/usr/soft/include/g++-v3/bits/basic_file.h:197: parse error before `(' token
/usr/soft/include/g++-v3/bits/basic_file.h:204: `streamoff' declared as a
   `virtual' field
/usr/soft/include/g++-v3/bits/basic_file.h:204: declaration of `int
   __basic_file<_CharT>::streamoff'
/usr/soft/include/g++-v3/bits/basic_file.h:197: conflicts with previous
   declaration `int __basic_file<_CharT>::streamoff'
/usr/soft/include/g++-v3/bits/basic_file.h:204: parse error before `(' token
/usr/soft/include/g++-v3/bits/basic_file.h:207: `streambuf' declared as a
   `virtual' field
/usr/soft/include/g++-v3/bits/basic_file.h:207: parse error before `*' token
/usr/soft/include/g++-v3/bits/basic_file.h:220: `streamsize' declared as a
   `virtual' field
/usr/soft/include/g++-v3/bits/basic_file.h:220: declaration of `int
   __basic_file<_CharT>::streamsize'
/usr/soft/include/g++-v3/bits/basic_file.h:185: conflicts with previous
   declaration `int __basic_file<_CharT>::streamsize'
/usr/soft/include/g++-v3/bits/basic_file.h:220: parse error before `(' token
/usr/soft/include/g++-v3/bits/basic_file.h:226: `streamsize' declared as a
   `virtual' field
/usr/soft/include/g++-v3/bits/basic_file.h:226: declaration of `int
   __basic_file<_CharT>::streamsize'
/usr/soft/include/g++-v3/bits/basic_file.h:185: conflicts with previous
   declaration `int __basic_file<_CharT>::streamsize'
/usr/soft/include/g++-v3/bits/basic_file.h:226: parse error before `(' token
/usr/soft/include/g++-v3/bits/basic_file.h:232: `streamoff' declared as a
   `virtual' field
/usr/soft/include/g++-v3/bits/basic_file.h:232: declaration of `int
   __basic_file<_CharT>::streamoff'
/usr/soft/include/g++-v3/bits/basic_file.h:197: conflicts with previous
   declaration `int __basic_file<_CharT>::streamoff'
/usr/soft/include/g++-v3/bits/basic_file.h:232: parse error before `(' token
/usr/soft/include/g++-v3/bits/basic_file.h:246: parse error before `}' token
In file included from /usr/soft/include/g++-v3/bits/basic_file.h:250,
                 from /usr/soft/include/g++-v3/fstream:48,
                 from bar.cxx:1:
/usr/soft/include/g++-v3/i686-pc-linux-gnu/bits/basic_file_model.h:38: parse
   error before `*' token
/usr/soft/include/g++-v3/i686-pc-linux-gnu/bits/basic_file_model.h:38: confused by earlier errors, bailing out

-- 
Maurizio Loreti                         http://www.pd.infn.it/~loreti/mlo.html
Univ. of Padova, Dept. of Physics - Padova, Italy            loreti@pd.infn.it


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]