File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -72,6 +72,13 @@ impl PyRegex {
7272 /// function and returns all matched strings in a list, if no matches it
7373 /// returns a empty list
7474 ///
75+ /// # Example (python)
76+ /// ```python
77+ /// >>> a = mathes(r"n[o|0]*b", "Dont say noob say n00b or the bot will ban u")
78+ /// >>> a
79+ /// [(9,13),(18,22)]
80+ /// ```
81+ ///
7582 /// Args:
7683 /// other:
7784 /// The other string to be matched against the compiled regex.
@@ -130,7 +137,7 @@ fn list_captures(capture: regex::Captures) ->Vec<Option<String>> {
130137/// Function that given a `regex_pattern` and an input `input_str` returns a
131138/// vector of tuples that contain (start_match, end_match+1):
132139/// # Example (python)
133- /// ```bash
140+ /// ```python
134141/// >>> a = mathes(r"n[o|0]*b", "Dont say noob say n00b or the bot will ban u")
135142/// >>> a
136143/// [(9,13),(18,22)]
You can’t perform that action at this time.
0 commit comments