pro64-support
[Top] [All Lists]

STLport

To: pro64-support@xxxxxxxxxxx
Subject: STLport
From: John Hsu <jonhsu@xxxxxxxxxxxxx>
Date: Mon, 29 Jan 2001 19:16:22 -0800
Sender: owner-pro64-support@xxxxxxxxxxx
Hi,

I'm trying to run the test cases from STLport with a version of the
Pro64 compiler and I've hit the following front-end bug:

sgiCC -O -c hmap1.cpp
/usr/lib/gcc-lib/ia64-hp-linux/2.9-ia64-000216/../../../../include/g++-3/ropeimpl.h:
In method `void
_Rope_RopeRep<_CharT, _Alloc>::_M_free_tree () [with _CharT = char,
_Alloc = allocator<char>]':
/usr/lib/gcc-lib/ia64-hp-linux/2.9-ia64-000216/../../../../include/g++-3/stl_rope.h:504:
instantiated from here
/usr/lib/gcc-lib/ia64-hp-linux/2.9-ia64-000216/../../../../include/g++-3/ropeimpl.h:334:
Internal
compiler error.
/usr/lib/gcc-lib/ia64-hp-linux/2.9-ia64-000216/../../../../include/g++-3/ropeimpl.h:334:
Please submit
a full bug report.
/usr/lib/gcc-lib/ia64-hp-linux/2.9-ia64-000216/../../../../include/g++-3/ropeimpl.h:334:
See
<URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.

It appears to be a problem in the GNU front end, not the Pro64 compiler.
The STLport website says that STLport should work with egcs 2.81 and
above, although I'm not actually building STLport, just the test cases.
I wasn't sure if I should send this to gnu.org directly or pass it on
through you.

#ifdef MAIN 
#define hmap1_test main
#endif
// STLport regression testsuite component.
// To compile as a separate example, please #define MAIN.

#include <iostream>
#include <hash_map>
#include <rope>

#if !defined (STLPORT) || defined(__STL_USE_NAMESPACES)
using namespace std;
#endif

int hmap1_test(int, char**)
{
  cout<<"Results of hmap1_test:"<<endl;
  typedef hash_map<char, crope, hash<char>, equal_to<char> > maptype;
  maptype m;
  // Store mappings between roman numerals and decimals.
  m['l'] = "50";
  m['x'] = "20"; // Deliberate mistake.
  m['v'] = "5";
  m['i'] = "1";
  cout << "m['x'] = " << m['x'] << endl;
  m['x'] = "10"; // Correct mistake.
  cout << "m['x'] = " << m['x'] << endl;
  cout << "m['z'] = " << m['z'] << endl; // Note default value is added.
  cout << "m.count('z') = " << m.count('z') << endl;
  pair<maptype::iterator, bool> p =
      m.insert(pair<const char, crope>('c', crope("100")));
  if(p.second)
    cout << "First insertion successful" << endl;
  p = m.insert(pair<const char, crope>('c', crope("100")));
  if(p.second)
    cout << "Second insertion successful" << endl;
  else
    cout << "Existing pair " <<(*(p.first)).first
         << " -> " <<(*(p.first)).second << endl;
  return 0;
}
<Prev in Thread] Current Thread [Next in Thread>
  • STLport, John Hsu <=