#include <string>
#include <testsuite_hooks.h>
bool test02(void)
{
bool test __attribute__((unused)) = true;
typedef std::wstring::size_type csize_type;
csize_type npos = std::wstring::npos;
csize_type csz01, csz02;
const wchar_t str_lit01[] = L"mave";
const std::wstring str01(L"mavericks, santa cruz");
std::wstring str02(str_lit01);
std::wstring str03(L"s, s");
std::wstring str04;
std::wstring str05(L"xena rulez");
csz01 = str01.find_first_of(str01);
VERIFY( csz01 == 0 );
csz01 = str01.find_first_of(str01, 4);
VERIFY( csz01 == 4 );
csz01 = str01.find_first_of(str02, 0);
VERIFY( csz01 == 0 );
csz01 = str01.find_first_of(str02, 3);
VERIFY( csz01 == 3 );
csz01 = str01.find_first_of(str03, 0);
VERIFY( csz01 == 8 );
csz01 = str01.find_first_of(str03, 3);
VERIFY( csz01 == 8 );
csz01 = str01.find_first_of(str03, 12);
VERIFY( csz01 == 16 );
csz01 = str01.find_first_of(str05, 0);
VERIFY( csz01 == 1 );
csz01 = str01.find_first_of(str05, 4);
VERIFY( csz01 == 4 );
csz01 = str01.find_first_of(str04, 0);
VERIFY( csz01 == npos );
csz01 = str01.find_first_of(str04, 5);
VERIFY( csz01 == npos );
csz01 = str01.find_first_of(str_lit01, 0, 3);
VERIFY( csz01 == 0 );
csz01 = str01.find_first_of(str_lit01, 3, 0);
VERIFY( csz01 == npos );
csz01 = str01.find_first_of(str_lit01);
VERIFY( csz01 == 0 );
csz01 = str01.find_first_of(str_lit01, 3);
VERIFY( csz01 == 3 );
csz01 = str01.find_first_of(L'z');
csz02 = str01.size() - 1;
VERIFY( csz01 == csz02 );
return test;
}
int main()
{
test02();
return 0;
}