3131#include < ctype.h>
3232
3333
34- // an abstract class used as a means to proide a unique pointer type
35- // but really has no body
36- class __FlashStringHelper ;
37- #define FPSTR (pstr_pointer ) (reinterpret_cast <const __FlashStringHelper *>(pstr_pointer))
38- #define F (string_literal ) (FPSTR(PSTR(string_literal)))
34+ #define FPSTR (pstr_pointer ) (pstr_pointer)
35+ #define F (string_literal ) (string_literal)
3936
4037// An inherited class for holding the result of a concatenation. These
4138// result objects are assumed to be writable by subsequent concatenations.
@@ -62,7 +59,6 @@ class String {
6259 String (const uint8_t *cstr, unsigned int length) : String((const char *)cstr, length) {}
6360#endif
6461 String (const String &str);
65- String (const __FlashStringHelper *str);
6662#ifdef __GXX_EXPERIMENTAL_CXX0X__
6763 String (String &&rval);
6864 String (StringSumHelper &&rval);
@@ -103,7 +99,6 @@ class String {
10399 // marked as invalid ("if (s)" will be false).
104100 String & operator =(const String &rhs);
105101 String & operator =(const char *cstr);
106- String & operator = (const __FlashStringHelper *str);
107102#ifdef __GXX_EXPERIMENTAL_CXX0X__
108103 String & operator =(String &&rval);
109104 String & operator =(StringSumHelper &&rval);
@@ -128,7 +123,6 @@ class String {
128123 bool concat (double num);
129124 bool concat (long long num);
130125 bool concat (unsigned long long num);
131- bool concat (const __FlashStringHelper * str);
132126
133127 // if there's not enough memory for the concatenated value, the string
134128 // will be left unchanged (but this isn't signalled in any way)
@@ -180,10 +174,6 @@ class String {
180174 concat (num);
181175 return (*this );
182176 }
183- String & operator += (const __FlashStringHelper *str){
184- concat (str);
185- return (*this );
186- }
187177
188178 friend StringSumHelper & operator +(const StringSumHelper &lhs, const String &rhs);
189179 friend StringSumHelper & operator +(const StringSumHelper &lhs, const char *cstr);
@@ -195,7 +185,6 @@ class String {
195185 friend StringSumHelper & operator +(const StringSumHelper &lhs, unsigned long num);
196186 friend StringSumHelper & operator +(const StringSumHelper &lhs, float num);
197187 friend StringSumHelper & operator +(const StringSumHelper &lhs, double num);
198- friend StringSumHelper & operator +(const StringSumHelper &lhs, const __FlashStringHelper *rhs);
199188 friend StringSumHelper & operator +(const StringSumHelper &lhs, long long num);
200189 friend StringSumHelper & operator +(const StringSumHelper &lhs, unsigned long long num);
201190
@@ -228,17 +217,11 @@ class String {
228217 bool startsWith (const char *prefix) const {
229218 return this ->startsWith (String (prefix));
230219 }
231- bool startsWith (const __FlashStringHelper *prefix) const {
232- return this ->startsWith (String (prefix));
233- }
234220 bool startsWith (const String &prefix, unsigned int offset) const ;
235221 bool endsWith (const String &suffix) const ;
236222 bool endsWith (const char *suffix) const {
237223 return this ->endsWith (String (suffix));
238224 }
239- bool endsWith (const __FlashStringHelper * suffix) const {
240- return this ->endsWith (String (suffix));
241- }
242225
243226 // character access
244227 char charAt (unsigned int index) const ;
@@ -275,18 +258,9 @@ class String {
275258 void replace (const char *find, const String &replace) {
276259 this ->replace (String (find), replace);
277260 }
278- void replace (const __FlashStringHelper *find, const String &replace) {
279- this ->replace (String (find), replace);
280- }
281261 void replace (const char *find, const char *replace) {
282262 this ->replace (String (find), String (replace));
283263 }
284- void replace (const __FlashStringHelper *find, const char *replace) {
285- this ->replace (String (find), String (replace));
286- }
287- void replace (const __FlashStringHelper *find, const __FlashStringHelper *replace) {
288- this ->replace (String (find), String (replace));
289- }
290264 void remove (unsigned int index);
291265 void remove (unsigned int index, unsigned int count);
292266 void toLowerCase (void );
@@ -350,7 +324,6 @@ class String {
350324
351325 // copy and move
352326 String & copy (const char *cstr, unsigned int length);
353- String & copy (const __FlashStringHelper *pstr, unsigned int length);
354327#ifdef __GXX_EXPERIMENTAL_CXX0X__
355328 void move (String &rhs);
356329#endif
0 commit comments