Changeset ee70ff5 for libcfa/src/collections/string.hfa
- Timestamp:
- Apr 2, 2025, 11:12:18 PM (9 months ago)
- Branches:
- master
- Children:
- 9aa8dcc
- Parents:
- f8913b7c
- File:
-
- 1 edited
-
libcfa/src/collections/string.hfa (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/collections/string.hfa
rf8913b7c ree70ff5 10 10 // Created On : Fri Sep 03 11:00:00 2021 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Tue Apr 1 09:16:39202513 // Update Count : 1 5512 // Last Modified On : Wed Apr 2 23:09:11 2025 13 // Update Count : 161 14 14 // 15 15 … … 28 28 29 29 // Getters 30 //static size_t inline __attribute__((always_inline)) size( char c ) { return sizeof( c ); }; // base case 31 //static size_t inline __attribute__((always_inline)) size( wchar_t wc ) { return sizeof( wc ); }; // base case 32 static inline size_t size( const char * cs ) { return strlen( cs ); }; 33 static inline size_t ?`len( const char * cs ) { return size( cs ); }; 34 size_t size( const string & s ); 35 size_t ?`len( const string & s ) { return size( s ); } 36 static inline size_t strlen( const string & s ) { return size( s ); } 30 static inline size_t len( const char * cs ) { return strlen( cs ); }; 31 size_t len( const string & s ); 32 static inline size_t strlen( const string & s ) { return len( s ); } 37 33 38 34 // RAII, assignment … … 169 165 string ?+?( char c, const char * s ); // add a character to a copy of the string 170 166 string ?+?( const char * c, const char * s ); // copy and add with two NULL-terminated string 171 string ?+?( const char * c, string & s );// copy and add with NULL-terminated string167 string ?+?( const char * c, const string & s ); // copy and add with NULL-terminated string 172 168 string ?+?( const string & s, const char * c ); // copy and add with NULL-terminated string 169 string ?+?( char c1, char c2 ); // add two characters 173 170 174 171 static inline string & strcat( string & s, const string & s2 ) { s += s2; return s; }
Note:
See TracChangeset
for help on using the changeset viewer.