nsReadingIterator<CharT> start( BeginReading() ); nsReadingIterator<CharT> end( EndReading() );
nsReadingIterator<CharT> iter, done_searching; BeginReading(iter).advance( PRInt32(aOffset) ); EndReading(done_searching);
basic_nsAReadableString<CharT>::FindChar( CharT aChar, PRUint32 aOffset ) const  {    nsReadingIterator<CharT> start( BeginReading() );    nsReadingIterator<CharT> end( EndReading() );    start += aOffset;    PRUint32 pos = 0;    while (start != end) {      PRUint32 fraglen = start.size_forward();      const CharT* findPtr = nsCharTraits<CharT>::find(start.get(), fraglen, aChar);      if (findPtr) {        return pos + (findPtr-start.get());      }      pos += fraglen;      start += fraglen;    }    return -1;  }