Skip to content

Commit 0021018

Browse files
committed
Removed unused flags from String (free 1 byte of SRAM)
1 parent e4e2a47 commit 0021018

File tree

7 files changed

+2
-7
lines changed

7 files changed

+2
-7
lines changed

build/shared/revisions.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ ARDUINO 1.5.3 BETA
2222
* avr: Added recipe for assembly files (C. A. Church)
2323
* avr: Use analogPinToChannel if it's defined (Kristian Sloth Lauszus)
2424
* avr: Optimized HardwareSerial buffer (Matthijs Kooijman)
25+
* removed unused flags from String (free 1 byte of SRAM)
2526

2627
[libraries]
2728
* sam: Added CAN library (still in early stage of development) (Palliser)

hardware/arduino/avr/cores/arduino/WString.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,6 @@ inline void String::init(void)
134134
buffer = NULL;
135135
capacity = 0;
136136
len = 0;
137-
flags = 0;
138137
}
139138

140139
void String::invalidate(void)

hardware/arduino/avr/cores/arduino/WString.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,6 @@ class String
191191
char *buffer; // the actual char array
192192
unsigned int capacity; // the array length minus one (for the '\0')
193193
unsigned int len; // the String length (not counting the '\0')
194-
unsigned char flags; // unused, for future features
195194
protected:
196195
void init(void);
197196
void invalidate(void);

hardware/arduino/avr/cores/robot/WString.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,6 @@ inline void String::init(void)
134134
buffer = NULL;
135135
capacity = 0;
136136
len = 0;
137-
flags = 0;
138137
}
139138

140139
void String::invalidate(void)

hardware/arduino/avr/cores/robot/WString.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ class String
113113
String & operator += (const String &rhs) {concat(rhs); return (*this);}
114114
String & operator += (const char *cstr) {concat(cstr); return (*this);}
115115
String & operator += (char c) {concat(c); return (*this);}
116-
String & operator += (unsigned char num) {concat(num); return (*this);}
116+
String & operator += (unsigned char num) {concat(num); return (*this);}
117117
String & operator += (int num) {concat(num); return (*this);}
118118
String & operator += (unsigned int num) {concat(num); return (*this);}
119119
String & operator += (long num) {concat(num); return (*this);}
@@ -191,7 +191,6 @@ class String
191191
char *buffer; // the actual char array
192192
unsigned int capacity; // the array length minus one (for the '\0')
193193
unsigned int len; // the String length (not counting the '\0')
194-
unsigned char flags; // unused, for future features
195194
protected:
196195
void init(void);
197196
void invalidate(void);

hardware/arduino/sam/cores/arduino/WString.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,6 @@ inline void String::init(void)
135135
buffer = NULL;
136136
capacity = 0;
137137
len = 0;
138-
flags = 0;
139138
}
140139

141140
void String::invalidate(void)

hardware/arduino/sam/cores/arduino/WString.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,6 @@ class String
191191
char *buffer; // the actual char array
192192
unsigned int capacity; // the array length minus one (for the '\0')
193193
unsigned int len; // the String length (not counting the '\0')
194-
unsigned char flags; // unused, for future features
195194
protected:
196195
void init(void);
197196
void invalidate(void);

0 commit comments

Comments
 (0)