diff options
| author | Jason Neal <jason.neal@astro.up.pt> | 2020-01-11 19:44:17 +1300 |
|---|---|---|
| committer | Damien George <damien.p.george@gmail.com> | 2020-01-12 13:44:59 +1100 |
| commit | 7ef2f65114f092be6303c145a2560fdf522dcde0 (patch) | |
| tree | 52ea36a8dc03bc5e6a4b0b4b332a5c8d784d8a39 /docs/library/ure.rst | |
| parent | 6632dd3981cbdca8e70c0bf19e36338101e9ce0e (diff) | |
docs/library: Add / to indicate positional-only args in library docs.
Removes the confusion of positional-only arguments which have defaults that
look like keyword arguments.
Diffstat (limited to 'docs/library/ure.rst')
| -rw-r--r-- | docs/library/ure.rst | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/docs/library/ure.rst b/docs/library/ure.rst index ac5f02f9e..ca5f35b70 100644 --- a/docs/library/ure.rst +++ b/docs/library/ure.rst @@ -124,7 +124,7 @@ Functions string for first position which matches regex (which still may be 0 if regex is anchored). -.. function:: sub(regex_str, replace, string, count=0, flags=0) +.. function:: sub(regex_str, replace, string, count=0, flags=0, /) Compile *regex_str* and search for it in *string*, replacing all matches with *replace*, and returning the new string. @@ -156,14 +156,14 @@ Compiled regular expression. Instances of this class are created using .. method:: regex.match(string) regex.search(string) - regex.sub(replace, string, count=0, flags=0) + regex.sub(replace, string, count=0, flags=0, /) Similar to the module-level functions :meth:`match`, :meth:`search` and :meth:`sub`. Using methods is (much) more efficient if the same regex is applied to multiple strings. -.. method:: regex.split(string, max_split=-1) +.. method:: regex.split(string, max_split=-1, /) Split a *string* using regex. If *max_split* is given, it specifies maximum number of splits to perform. Returns list of strings (there |
