api: add Match::len method

PR #97
This commit is contained in:
Ten0
2022-09-03 19:28:54 +02:00
committed by GitHub
parent 6cf8ffd7f4
commit 162f9c187d
+6
View File
@@ -275,6 +275,12 @@ impl Match {
self.end
}
/// The length, in bytes, of the match.
#[inline]
pub fn len(&self) -> usize {
self.len
}
/// Returns true if and only if this match is empty. That is, when
/// `start() == end()`.
///