summaryrefslogtreecommitdiff
path: root/doctest/parts/doctest_impl.h
diff options
context:
space:
mode:
Diffstat (limited to 'doctest/parts/doctest_impl.h')
-rw-r--r--doctest/parts/doctest_impl.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/doctest/parts/doctest_impl.h b/doctest/parts/doctest_impl.h
index b1c822c..a17a767 100644
--- a/doctest/parts/doctest_impl.h
+++ b/doctest/parts/doctest_impl.h
@@ -292,21 +292,21 @@ void String::copy(const String& other) {
data.size = other.data.size;
data.capacity = data.size + 1;
data.ptr = new char[data.capacity];
- memcpy(data.ptr, other.data.ptr, data.size + 1u);
+ memcpy(data.ptr, other.data.ptr, size_t(data.size + 1));
}
}
String::String(const char* in) {
unsigned in_len = strlen(in);
if(in_len <= last) {
- memcpy(buf, in, in_len + 1u);
+ memcpy(buf, in, size_t(in_len + 1));
setLast(last - in_len);
} else {
setOnHeap();
data.size = in_len;
data.capacity = data.size + 1;
data.ptr = new char[data.capacity];
- memcpy(data.ptr, in, in_len + 1u);
+ memcpy(data.ptr, in, size_t(in_len + 1));
}
}