From 9fc07ef757d44f35056175669056650e212ab04e Mon Sep 17 00:00:00 2001 From: Yuanhao Jia Date: Thu, 3 Mar 2022 22:32:27 +0800 Subject: [PATCH] Fix namespace closing comment order in ddl2cpp script --- scripts/ddl2cpp | 2 +- scripts/sqlite2cpp.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/ddl2cpp b/scripts/ddl2cpp index 992396e1..b7d5c1df 100755 --- a/scripts/ddl2cpp +++ b/scripts/ddl2cpp @@ -460,7 +460,7 @@ def beginHeader(pathToHeader, namespace, nsList): def endHeader(header, nsList): - for ns in nsList: + for ns in reversed(nsList): print("} // namespace " + ns, file=header) print("#endif", file=header) header.close() diff --git a/scripts/sqlite2cpp.py b/scripts/sqlite2cpp.py index c6f243c2..acc34844 100644 --- a/scripts/sqlite2cpp.py +++ b/scripts/sqlite2cpp.py @@ -162,7 +162,7 @@ def main(): print(' };', file=header) - for ns in nsList: + for ns in reversed(nsList): print('} // namespace ' + ns, file=header) print('#endif', file=header)