public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "schmid at snake dot iap dot physik dot tu-darmstadt dot de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libstdc++/14648] New: hash_maps are broken (regression)
Date: Fri, 19 Mar 2004 08:53:00 -0000	[thread overview]
Message-ID: <20040319085249.14648.schmid@snake.iap.physik.tu-darmstadt.de> (raw)

hash_maps no longer work. This is a regression with respect to gcc 3.4.0 built 
last week. 
 
Consider the following code: 
 
source code th.C 
 
#include <ext/hash_map> 
#include <ext/rope> 
 
using namespace std; 
using namespace __gnu_cxx; 
 
int hmap1_test(int, char**) 
{ 
  typedef hash_map<char, crope, hash<char>, equal_to<char> > maptype; 
  maptype m; 
  m['l'] = "50"; 
  cout << "m['x'] = " << m['x'] << endl; 
  return 0; 
}  
 
g++ -v -W -Wall th.C 
Reading specs from /usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/specs 
Configured with: ../gcc/configure --enable-threads=posix --enable-languages=c,c
++,f77,objc --enable-__cxa_atexit --enable-libstdcxx-debug 
Thread model: posix 
gcc version 3.4.0 20040319 (prerelease) 
 /usr/local/libexec/gcc/i686-pc-linux-gnu/3.4.0/cc1plus -quiet -v -D_GNU_SOURCE 
th.C -quiet -dumpbase th.C -mtune=pentiumpro -auxbase th -W -Wall -version -o /
tmp/ccAyVpeT.s 
ignoring nonexistent directory "NONE/include" 
ignoring nonexistent directory "/usr/local/lib/gcc/
i686-pc-linux-gnu/3.4.0/../../../../i686-pc-linux-gnu/include" 
#include "..." search starts here: 
#include <...> search starts here: 
 /usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/../../../../include/c++/3.4.0 
 /usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/../../../../include/c++/3.4.0/
i686-pc-linux-gnu 
 /usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/../../../../include/c++/3.4.0/
backward 
 /usr/local/include 
 /usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/include 
 /usr/include 
End of search list. 
GNU C++ version 3.4.0 20040319 (prerelease) (i686-pc-linux-gnu) 
	compiled by GNU C version 3.4.0 20040319 (prerelease). 
GGC heuristics: --param ggc-min-expand=64 --param ggc-min-heapsize=64274 
/usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/../../../../include/c++/3.4.0/ext/
ropeimpl.h: In static member function `static bool __gnu_cxx::rope<_CharT, 
_Alloc>::_S_apply_to_pieces(__gnu_cxx::_Rope_char_consumer<_CharT>&, const 
__gnu_cxx::_Rope_RopeRep<_CharT, _Alloc>*, size_t, size_t) [with _CharT = char, 
_Alloc = std::allocator<char>]': 
/usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/../../../../include/c++/3.4.0/ext/
rope:1314:   instantiated from `void __gnu_cxx::rope<_CharT, 
_Alloc>::apply_to_pieces(size_t, size_t, 
__gnu_cxx::_Rope_char_consumer<_CharT>&) const [with _CharT = char, _Alloc = 
std::allocator<char>]' 
/usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/../../../../include/c++/3.4.0/ext/
ropeimpl.h:930:   instantiated from `std::basic_ostream<_CharT, _Traits>& 
__gnu_cxx::operator<<(std::basic_ostream<_CharT, _Traits>&, const 
__gnu_cxx::rope<_CharT, _Alloc>&) [with _CharT = char, _Traits = 
std::char_traits<char>, _Alloc = std::allocator<char>]' 
th.C:13:   instantiated from here 
/usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/../../../../include/c++/3.4.0/ext/
ropeimpl.h:877: error: cannot call member function `_Tp* 
__gnu_cxx::new_allocator<_Tp>::allocate(size_t, const void*) [with _Tp = char]' 
without object 
/usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/../../../../include/c++/3.4.0/ext/
rope:1314:   instantiated from `void __gnu_cxx::rope<_CharT, 
_Alloc>::apply_to_pieces(size_t, size_t, 
__gnu_cxx::_Rope_char_consumer<_CharT>&) const [with _CharT = char, _Alloc = 
std::allocator<char>]' 
/usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/../../../../include/c++/3.4.0/ext/
ropeimpl.h:930:   instantiated from `std::basic_ostream<_CharT, _Traits>& 
__gnu_cxx::operator<<(std::basic_ostream<_CharT, _Traits>&, const 
__gnu_cxx::rope<_CharT, _Alloc>&) [with _CharT = char, _Traits = 
std::char_traits<char>, _Alloc = std::allocator<char>]' 
th.C:13:   instantiated from here 
/usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/../../../../include/c++/3.4.0/ext/
ropeimpl.h:881: error: cannot call member function `void 
__gnu_cxx::new_allocator<_Tp>::deallocate(_Tp*, size_t) [with _Tp = char]' 
without object 
/usr/local/lib/gcc/i686-pc-linux-gnu/3.4.0/../../../../include/c++/3.4.0/ext/
ropeimpl.h:885: error: cannot call member function `void 
__gnu_cxx::new_allocator<_Tp>::deallocate(_Tp*, size_t) [with _Tp = char]' 
without object

-- 
           Summary: hash_maps are broken (regression)
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: libstdc++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: schmid at snake dot iap dot physik dot tu-darmstadt dot
                    de
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14648


             reply	other threads:[~2004-03-19  8:53 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-03-19  8:53 schmid at snake dot iap dot physik dot tu-darmstadt dot de [this message]
2004-03-19 10:06 ` [Bug libstdc++/14648] rope is " pcarlini at suse dot de
2004-03-19 12:49 ` pcarlini at suse dot de
2004-03-19 14:17 ` [Bug libstdc++/14648] [3.4/3.5 Regression] " pinskia at gcc dot gnu dot org
2004-03-19 16:08 ` cvs-commit at gcc dot gnu dot org
2004-03-19 16:11 ` [Bug libstdc++/14648] [3.4 " pcarlini at suse dot de
2004-03-19 16:27 ` mark at codesourcery dot com
2004-03-19 16:37 ` cvs-commit at gcc dot gnu dot org
2004-03-19 16:38 ` pcarlini at suse dot de

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040319085249.14648.schmid@snake.iap.physik.tu-darmstadt.de \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).