bobzhang/asciidoctor/regex does not have a README file
pub suberror RegexError {
RegexError(pattern~ : String, pos~ : Int, message~ : String)
} derive(Debug)pub struct MatchData {
input : String
// private fields
}pub struct Regex {
source : String
// private fields
}fn Regex::try_replace(self : Regex, s : String, f : (MatchData) -> String, once? : Bool) -> String raise RegexTimeouttest {
let re = @regex.compile("(\\w+)@(\\w+)")
guard re.find("mail: joe@example") is Some(m) else { fail("no match") }
debug_inspect(m.group(2), content="Some(\"example\")")
inspect(@regex.compile("HELLO", flags="i").matches("hello"), content="true")
}Install
Download zipA port of Asciidoctor (AsciiDoc processor) to MoonBit
Dependencies