| ... | ... | @@ -378,17 +378,11 @@ test endsWithIgnoreCase { |
| 378 | 378 | try std.testing.expect(!endsWithIgnoreCase("BoB", "Bo")); |
| 379 | 379 | } |
| 380 | 380 | |
| 381 | | /// Deprecated in favor of `findIgnoreCase`. |
| 382 | | pub const indexOfIgnoreCase = findIgnoreCase; |
| 383 | | |
| 384 | 381 | /// Finds `needle` in `haystack`, ignoring case, starting at index 0. |
| 385 | 382 | pub fn findIgnoreCase(haystack: []const u8, needle: []const u8) ?usize { |
| 386 | 383 | return findIgnoreCasePos(haystack, 0, needle); |
| 387 | 384 | } |
| 388 | 385 | |
| 389 | | /// Deprecated in favor of `findIgnoreCasePos`. |
| 390 | | pub const indexOfIgnoreCasePos = findIgnoreCasePos; |
| 391 | | |
| 392 | 386 | /// Finds `needle` in `haystack`, ignoring case, starting at `start_index`. |
| 393 | 387 | /// Uses Boyer-Moore-Horspool algorithm on large inputs; `findIgnoreCasePosLinear` on small inputs. |
| 394 | 388 | pub fn findIgnoreCasePos(haystack: []const u8, start_index: usize, needle: []const u8) ?usize { |
| ... | ... | @@ -410,9 +404,6 @@ pub fn findIgnoreCasePos(haystack: []const u8, start_index: usize, needle: []con |
| 410 | 404 | return null; |
| 411 | 405 | } |
| 412 | 406 | |
| 413 | | /// Deprecated in favor of `findIgnoreCaseLinear`. |
| 414 | | pub const indexOfIgnoreCasePosLinear = findIgnoreCasePosLinear; |
| 415 | | |
| 416 | 407 | /// Consider using `findIgnoreCasePos` instead of this, which will automatically use a |
| 417 | 408 | /// more sophisticated algorithm on larger inputs. |
| 418 | 409 | pub fn findIgnoreCasePosLinear(haystack: []const u8, start_index: usize, needle: []const u8) ?usize { |