diff --git a/include/EASTL/string_view.h b/include/EASTL/string_view.h index 7eccc788..c2d5bc91 100644 --- a/include/EASTL/string_view.h +++ b/include/EASTL/string_view.h @@ -214,12 +214,21 @@ namespace eastl auto* pEnd = mpBegin + mnCount; if (EASTL_LIKELY(((npos - sw.size()) >= pos) && (pos + sw.size()) <= mnCount)) { - const value_type* const pTemp = eastl::search(mpBegin + pos, pEnd, sw.data(), sw.data() + sw.size()); - - if ((pTemp != pEnd) || (sw.size() == 0)) - return (size_type)(pTemp - mpBegin); + for (size_type i =pos;i<=mnCount-sw.size();i++){ + if(mpBegin[i]==sw[0]){ + //if first char matches + size_type j=1; + while(j