From 29ff5f77ee9dbdd5a4aac292fee2599e2ea9cfc1 Mon Sep 17 00:00:00 2001 From: Tobias Hunger Date: Fri, 18 Jan 2019 12:44:15 +0100 Subject: [PATCH] CMake: pro2cmake.py: Do not double-report include files Do not add scopes that are going to get merged into their parent scope as a child of the parent scope. This leads to the information of the child scope being duplicated. Change-Id: If4d6a83b9c9eac477959e7774e9cf65fd4df98e6 Reviewed-by: Frederik Gladhorn --- util/cmake/pro2cmake.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/util/cmake/pro2cmake.py b/util/cmake/pro2cmake.py index 78c75683a2..9b819e58ec 100755 --- a/util/cmake/pro2cmake.py +++ b/util/cmake/pro2cmake.py @@ -901,9 +901,9 @@ def do_include(scope: Scope, *, debug: bool = False) -> None: include_result = parseProFile(include_file, debug=debug) include_scope \ - = Scope.FromDict(scope, include_file, + = Scope.FromDict(None, include_file, include_result.asDict().get('statements'), - '', dir) + '', dir) # This scope will be merged into scope, so no parent_scope! do_include(include_scope)