From b6cb1707b0b84a701b0c10bbe19eda790594de4d Mon Sep 17 00:00:00 2001 From: Joel Rosdahl Date: Mon, 21 Sep 2020 08:25:38 +0200 Subject: [PATCH] Pass Args by const ref MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit It doesn’t matter in practice, but LGTM gets happier. --- src/argprocessing.hpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/argprocessing.hpp b/src/argprocessing.hpp index 6a34ab6af..c040c44e5 100644 --- a/src/argprocessing.hpp +++ b/src/argprocessing.hpp @@ -28,9 +28,9 @@ class Context; struct ProcessArgsResult { ProcessArgsResult(Statistic error); - ProcessArgsResult(Args preprocessor_args, - Args extra_args_to_hash, - Args compiler_args); + ProcessArgsResult(const Args& preprocessor_args, + const Args& extra_args_to_hash, + const Args& compiler_args); // nullopt on success, otherwise the statistics counter that should be // incremented. @@ -50,9 +50,9 @@ inline ProcessArgsResult::ProcessArgsResult(Statistic error_) : error(error_) { } -inline ProcessArgsResult::ProcessArgsResult(Args preprocessor_args_, - Args extra_args_to_hash_, - Args compiler_args_) +inline ProcessArgsResult::ProcessArgsResult(const Args& preprocessor_args_, + const Args& extra_args_to_hash_, + const Args& compiler_args_) : preprocessor_args(preprocessor_args_), extra_args_to_hash(extra_args_to_hash_), compiler_args(compiler_args_) -- 2.47.3