OxL Reference

method Regex.isMatch

True when the pattern matches anywhere in s.

Example:

oxl✓ checked in CI
fn main() io {
  let re = Regex.compile("[0-9]+")!
  print("{re.isMatch("ab12")}")
}
Output
true
pub(api) fn isMatch(s: str) -> bool

Since. 1.0.0-beta

Parameters

NameType
sstr

Returns

bool

Effects

none declared (pure unless the body says otherwise)

Defined in: std/core/text.oxl:1281

See also