From a2aa336eebb8c016cc6e920a9d7d21a1097623f6 Mon Sep 17 00:00:00 2001 From: Myun2 Date: Sat, 18 Sep 2010 04:25:15 +0900 Subject: [PATCH] =?utf8?q?sized=5Fptr.hpp,=20sized=5Fcharbuf.hpp:=20const?= =?utf8?q?=E3=82=92=E4=BB=98=E3=81=91=E3=81=BE=E3=81=97=E3=82=87=E3=81=86?= =?utf8?q?=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- roast/include/roast/memory/sized_ptr.hpp | 6 +++--- roast/include/roast/str/sized_charbuf.hpp | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/roast/include/roast/memory/sized_ptr.hpp b/roast/include/roast/memory/sized_ptr.hpp index f1ebd052..05184a0f 100644 --- a/roast/include/roast/memory/sized_ptr.hpp +++ b/roast/include/roast/memory/sized_ptr.hpp @@ -31,7 +31,7 @@ namespace roast 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); @@ -101,7 +101,7 @@ namespace roast 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); @@ -124,7 +124,7 @@ namespace roast 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); diff --git a/roast/include/roast/str/sized_charbuf.hpp b/roast/include/roast/str/sized_charbuf.hpp index 469ba902..659b98fa 100644 --- a/roast/include/roast/str/sized_charbuf.hpp +++ b/roast/include/roast/str/sized_charbuf.hpp @@ -23,7 +23,7 @@ namespace roast //////////////////////////////////////////////// - ::std::string to_string() + ::std::string to_string() const { return ::std::string(ptr, size); } -- 2.11.0