Changeset 18700
- Timestamp:
- 2009-03-17T14:31:58+13:00 (15 years ago)
- Location:
- gsdl/trunk/common-src/src/lib
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
gsdl/trunk/common-src/src/lib/text_t.cpp
r16066 r18700 358 358 } 359 359 360 text_t::iterator findlastchar (text_t::iterator first, text_t::iterator last ,360 text_t::iterator findlastchar (text_t::iterator first, text_t::iterator last_plus_one, 361 361 unsigned short c) 362 362 { 363 text_t::iterator current = last ;363 text_t::iterator current = last_plus_one - 1; 364 364 while (current != first) { 365 365 if (*current == c) break; … … 368 368 if (current == first) { 369 369 if (*current == c) return current; 370 return last ;370 return last_plus_one; 371 371 } 372 372 -
gsdl/trunk/common-src/src/lib/text_t.h
r16066 r18700 225 225 text_t::iterator findchar (text_t::iterator first, text_t::iterator last, 226 226 unsigned short c); 227 text_t::iterator findlastchar (text_t::iterator first, text_t::iterator last, 227 // Find the last occurrence of c between first and last_plus_one -1. Returns last_plus_one if not found. 228 text_t::iterator findlastchar (text_t::iterator first, text_t::iterator last_plus_one, 228 229 unsigned short c); 229 230 text_t::iterator findword (text_t::iterator first, text_t::iterator last,
Note:
See TracChangeset
for help on using the changeset viewer.