We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c606292 commit ecfafe3Copy full SHA for ecfafe3
cores/esp32/WString.cpp
@@ -35,6 +35,12 @@ String::String(const char *cstr) {
35
copy(cstr, strlen(cstr));
36
}
37
38
+String::String(const char *cstr, unsigned int length) {
39
+ init();
40
+ if (cstr)
41
+ copy(cstr, length);
42
+}
43
+
44
String::String(const String &value) {
45
init();
46
*this = value;
cores/esp32/WString.h
@@ -55,6 +55,7 @@ class String {
55
// fails, the string will be marked as invalid (i.e. "if (s)" will
56
// be false).
57
String(const char *cstr = "");
58
+ String(const char *cstr, unsigned int length);
59
String(const String &str);
60
String(const __FlashStringHelper *str);
61
#ifdef __GXX_EXPERIMENTAL_CXX0X__
0 commit comments