From d5f8ce0b249e04b928d9513439b0e15cfc83ed80 Mon Sep 17 00:00:00 2001 From: Raoul Wols Date: Sat, 26 Aug 2017 19:19:24 +0200 Subject: [PATCH] Remove debug prints and format code --- server.py | 1 - support/headerdb.py | 7 +++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/server.py b/server.py index eb3eb59..7f9751f 100644 --- a/server.py +++ b/server.py @@ -337,7 +337,6 @@ def handle_compdb(self): headerdb = make_headerdb([[db]])[0] db = list(db._data) db.extend(headerdb.get_all_compile_commands()) - print(db) path = os.path.join(self.cmake.build_folder, "compile_commands.json") with open(path, "w") as f: json.dump( diff --git a/support/headerdb.py b/support/headerdb.py index c73e303..fecded4 100644 --- a/support/headerdb.py +++ b/support/headerdb.py @@ -97,8 +97,7 @@ def extract_include_dirs(compile_command): header_search_path.append(command[i][2:]) i += 1 return [ - os.path.join(compile_command.directory, p) - for p in header_search_path + os.path.join(compile_command.directory, p) for p in header_search_path ] @@ -208,9 +207,9 @@ def __init__(self, score=0, compile_command=None, db_idx=-1): def _make_headerdb1(compile_commands_iter, db_files, db_idx, header_mapping): for compile_command in compile_commands_iter: - print(compile_command.__class__.__name__, compile_command) if isinstance(compile_command, dict): - compile_command = JSONCompilationDatabase._dict_to_compile_command(compile_command) + compile_command = JSONCompilationDatabase._dict_to_compile_command( + compile_command) implicit_search_path = get_implicit_header_search_path(compile_command) header_search_paths = extract_include_dirs(compile_command) src_file = compile_command.normfile