From 6238e376599a50e9b340052ab1c5361eadc9e2ce Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Thu, 30 Jun 2022 15:46:10 -0700 Subject: [PATCH] =?UTF-8?q?Match=20"#line"=20lines=20with=20leading=20whit?= =?UTF-8?q?espace=E2=80=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.py b/build.py index 82874d3b..b66c48b6 100755 --- a/build.py +++ b/build.py @@ -1336,7 +1336,7 @@ def cmd_sip(options, args): else: # ...or totally remove them by replacing those lines with '' import re - srcTxt = re.sub(r'^#line.*\n', '', srcTxt, flags=re.MULTILINE) + srcTxt = re.sub(r'^\s*#line.*\n', '', srcTxt, flags=re.MULTILINE) className = classesNeedingClassInfo.get(os.path.basename(src)) if className: srcTxt = injectClassInfo(className, srcTxt)