str.cpp

changeset 18
a6732098fed8
parent 0
c51cce84a9ac
child 25
c74bb88f537d
equal deleted inserted replaced
17:5606eebd0b90 18:a6732098fed8
3 #include <string.h> 3 #include <string.h>
4 #include <stdarg.h> 4 #include <stdarg.h>
5 #include <assert.h> 5 #include <assert.h>
6 // #include <initializer_list> 6 // #include <initializer_list>
7 #include "str.h" 7 #include "str.h"
8 #include "common.h"
9 #include "misc.h"
8 10
9 #define ITERATE_STRING(u) \ 11 #define ITERATE_STRING(u) \
10 for (unsigned int u = 0; u < strlen (text); u++) 12 for (unsigned int u = 0; u < strlen (text); u++)
11 13
12 // ============================================================================ 14 // ============================================================================
462 } 464 }
463 465
464 std::vector<str> str::operator/ (str splitstring) {return split(splitstring);} 466 std::vector<str> str::operator/ (str splitstring) {return split(splitstring);}
465 std::vector<str> str::operator/ (char* splitstring) {return split(splitstring);} 467 std::vector<str> str::operator/ (char* splitstring) {return split(splitstring);}
466 std::vector<str> str::operator/ (const char* splitstring) {return split(splitstring);} 468 std::vector<str> str::operator/ (const char* splitstring) {return split(splitstring);}
469
470 str& str::operator+= (vertex vrt) {
471 appendformat ("%s", vrt.getStringRep (false).chars());
472 return *this;
473 }

mercurial