- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
at Intel C++ Compiler Version 11.0 and Ubuntu 8.04
user@ubuntu804~$ icpc -c -o main.o main.cpp (0): internal error: backend signals compilation aborted for main.cpp (code 4)
is this a bug of the compiler?
// main.cpp
#include
#include
namespace cxx {
using std::size_t;
using std::ptrdiff_t;
template
class my_allocator {
public:
typedef size_t size_type;
typedef ptrdiff_t difference_type;
typedef _Tp* pointer;
typedef const _Tp* const_pointer;
typedef _Tp& reference;
typedef const _Tp& const_reference;
typedef _Tp value_type;
template
struct rebind
{ typedef my_allocator<_Tp1> other; };
my_allocator() throw() {}
my_allocator(const my_allocator&) throw() {}
template
my_allocator(const my_allocator<_Tp1>&) throw() {}
~my_allocator() throw() {}
pointer address(reference __x) const
{ return &__x; }
const_pointer address(const_reference __x) const
{ return &__x; }
pointer allocate(size_type __n, const void* = 0)
{ return static_cast<_Tp*>(malloc(__n * sizeof(_Tp))); }
void deallocate(pointer __p, size_type)
{ free(static_cast
size_type max_size() const throw()
{ return size_t(-1) / sizeof(_Tp); }
void construct(pointer __p, const _Tp& __val)
{ ::new(__p) value_type(__val); }
void destroy(pointer __p)
{ __p->~_Tp(); }
};
template
bool operator==(const my_allocator<_Tp>&, const my_allocator<_Tp>&)
{ return true; }
template
bool operator!=(const my_allocator<_Tp>&, const my_allocator<_Tp>&)
{ return false; }
typedef std::basic_string
my_allocator
} // namespace cxx
int main()
{
cxx::my_string s = "Hello, World";
std::cout << s << std::endl;
}
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, any internal error is a bug, and you are welcome to post your reproducer in a problem report on you account on premier.intel.com.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page