From f70d5af07f57b08c985b2a393103546a36a33721 Mon Sep 17 00:00:00 2001 From: blueloveTH Date: Mon, 19 Aug 2024 10:52:40 +0800 Subject: [PATCH] fix docs --- scripts/gen_docs.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/gen_docs.py b/scripts/gen_docs.py index 2336c8ad..99815d3a 100644 --- a/scripts/gen_docs.py +++ b/scripts/gen_docs.py @@ -37,8 +37,8 @@ class Function: with open('include/pocketpy/pocketpy.h') as f: header = f.read() -matches = re.finditer(r"((?:/// [^\n]+[\n])*?)PK_EXPORT\s+(\w+)\s+(\w+)(\(.*?\))\s*(PY_RAISE)?\s*(PY_RETURN)?\s*;", header, re.DOTALL) -# ^1 comment ^2 ret ^3 ^4 args ^5 py_raise? ^6 py_return? +matches = re.finditer(r"((?:/// [^\n]+[\n])*?)PK_EXPORT\s+(\w+\*?)\s+(\w+)(\(.*?\))\s*(PY_RAISE)?\s*(PY_RETURN)?\s*;", header, re.DOTALL) +# ^1 comment ^2 ret ^3 n ^4 args ^5 py_raise? ^6 py_return? functions: list[Function] = [] for match in matches: