[][src]Function voca_rs::index::last_index_of

pub fn last_index_of(subject: &str, search: &str, from_index: usize) -> i8

Returns the last occurrence index of search in subject or -1 if not found. Case sensitive.

Arguments

Example

use voca_rs::*;
index::last_index_of("morning", "n", 0);
// => 5
index::last_index_of("evening", "o", 0);
// => -1
use voca_rs::Voca;
"morning"._last_index_of("n", 0);
// => 5