char[] tmp; test (toLower("1bac", tmp) == "1bac"); test (toLower("1BAC", tmp) == "1bac"); test (toUpper("1bac", tmp) == "1BAC"); test (toUpper("1BAC", tmp) == "1BAC"); test (icompare ("ABC", "abc") is 0); test (icompare ("abc", "abc") is 0); test (icompare ("abcd", "abc") > 0); test (icompare ("abc", "abcd") < 0); test (icompare ("ACC", "abc") > 0); test (isearch ("ACC", "abc") is 3); test (isearch ("ACC", "acc") is 0); test (isearch ("aACC", "acc") is 1);
Return the index position of a text pattern within src, or src.length upon failure.
This is a case-insensitive search (with thanks to Nietsnie)