diff options
author | Alex Turbov <i.zaufi@gmail.com> | 2019-07-04 18:04:19 (GMT) |
---|---|---|
committer | Alex Turbov <i.zaufi@gmail.com> | 2019-07-09 22:06:14 (GMT) |
commit | b821f9ad62d97b975255380674aaedfce296a8b8 (patch) | |
tree | 6a6cded47e71bae966932acb9cdf665b4a4ae308 /Source/cmakemain.cxx | |
parent | f374ffb14b3e55bbee8e7bb0eb3e5a33ee3612f1 (diff) | |
download | CMake-b821f9ad62d97b975255380674aaedfce296a8b8.zip CMake-b821f9ad62d97b975255380674aaedfce296a8b8.tar.gz CMake-b821f9ad62d97b975255380674aaedfce296a8b8.tar.bz2 |
Refactor: Optimize some stream output operations
- remove redundant `std::flush` right after `std::endl`
- join some string literals
Signed-off-by: Alex Turbov <i.zaufi@gmail.com>
Diffstat (limited to 'Source/cmakemain.cxx')
-rw-r--r-- | Source/cmakemain.cxx | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/Source/cmakemain.cxx b/Source/cmakemain.cxx index a6348b3..f80829f 100644 --- a/Source/cmakemain.cxx +++ b/Source/cmakemain.cxx @@ -159,7 +159,7 @@ static std::string cmakemainGetStack(cmake* cm) static void cmakemainMessageCallback(const std::string& m, const char* /*unused*/, cmake* cm) { - std::cerr << m << cmakemainGetStack(cm) << std::endl << std::flush; + std::cerr << m << cmakemainGetStack(cm) << std::endl; } static void cmakemainProgressCallback(const std::string& m, float prog, @@ -178,8 +178,6 @@ static void cmakemainProgressCallback(const std::string& m, float prog, if ((prog < 0) || (!dir.empty())) { std::cout << "-- " << m << dir << cmakemainGetStack(cm) << std::endl; } - - std::cout.flush(); } int main(int ac, char const* const* av) |