summaryrefslogtreecommitdiff
path: root/doc/python_stub.py
diff options
context:
space:
mode:
Diffstat (limited to 'doc/python_stub.py')
-rwxr-xr-xdoc/python_stub.py12
1 files changed, 5 insertions, 7 deletions
diff --git a/doc/python_stub.py b/doc/python_stub.py
index 681533807..329f11473 100755
--- a/doc/python_stub.py
+++ b/doc/python_stub.py
@@ -38,16 +38,14 @@ STUB_HEADER = """\
from typing import Dict
"""
-CONSTANT_RE = r"""\
- `(?P<constant>WEECHAT_[A-Z0-9_]+)` \((?P<type>(string|integer))\)(?: \+)?\
-"""
+CONSTANT_RE = (
+ r""" `(?P<constant>WEECHAT_[A-Z0-9_]+)` \((?P<type>(string|integer))\)(?: \+)?"""
+)
-FUNCTION_RE = r"""\
-\[source,python\]
+FUNCTION_RE = r"""\[source,python\]
----
# prototype
-def (?P<function>\w+)(?P<args>[^)]*)(?P<return>\) -> [^:]+:) \.\.\.\
-"""
+def (?P<function>\w+)(?P<args>[^)]*)(?P<return>\) -> [^:]+:) \.\.\."""
def print_stub_constants() -> None: