size = size_in;
}
- T* to_allocate(size_t margin=0)
+ T* to_allocate(size_t margin=0) const
{
T* p = new T [ size + margin ];
memcpy(p,ptr,sizeof(T) * size);
size = size_in;
}
- T* to_allocate(size_t margin=0)
+ T* to_allocate(size_t margin=0) const
{
T* p = (void*)new char [ size + margin ];
memcpy(p,ptr,sizeof(char) * size);
size = size_in;
}
- T* to_allocate(size_t margin=0)
+ T* to_allocate(size_t margin=0) const
{
T* p = (void*)new char [ size + margin ];
memcpy((void*)p,ptr,sizeof(char) * size);
////////////////////////////////////////////////
- ::std::string to_string()
+ ::std::string to_string() const
{
return ::std::string(ptr, size);
}