diff options
author | Miodrag Milanovic <mmicko@gmail.com> | 2018-12-05 19:58:38 +0100 |
---|---|---|
committer | Miodrag Milanovic <mmicko@gmail.com> | 2018-12-05 19:58:38 +0100 |
commit | a6315833d3ca7eac414b8496d8ff12a7f30a4145 (patch) | |
tree | 04e362c936c5d6afea835793c0035a2236097ff3 /common/command.cc | |
parent | 697e2ed49039d3573a4fe8862341e85e47c74932 (diff) | |
download | nextpnr-a6315833d3ca7eac414b8496d8ff12a7f30a4145.tar.gz nextpnr-a6315833d3ca7eac414b8496d8ff12a7f30a4145.tar.bz2 nextpnr-a6315833d3ca7eac414b8496d8ff12a7f30a4145.zip |
Renamed LogLevel members, to prevent issue with system defines on Windows
Diffstat (limited to 'common/command.cc')
-rw-r--r-- | common/command.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/common/command.cc b/common/command.cc index 206a4d30..d332375a 100644 --- a/common/command.cc +++ b/common/command.cc @@ -131,9 +131,9 @@ void CommandHandler::setupContext(Context *ctx) } if (vm.count("quiet")) { - log_streams.push_back(std::make_pair(&std::cerr, LogLevel::WARNING)); + log_streams.push_back(std::make_pair(&std::cerr, LogLevel::WARNING_MSG)); } else { - log_streams.push_back(std::make_pair(&std::cerr, LogLevel::LOG)); + log_streams.push_back(std::make_pair(&std::cerr, LogLevel::LOG_MSG)); } if (vm.count("log")) { @@ -141,7 +141,7 @@ void CommandHandler::setupContext(Context *ctx) logfile = std::ofstream(logfilename); if (!logfile) log_error("Failed to open log file '%s' for writing.\n", logfilename.c_str()); - log_streams.push_back(std::make_pair(&logfile, LogLevel::LOG)); + log_streams.push_back(std::make_pair(&logfile, LogLevel::LOG_MSG)); } if (vm.count("force")) { @@ -285,8 +285,8 @@ void CommandHandler::conflicting_options(const boost::program_options::variables void CommandHandler::printFooter() { - int warning_count = get_or_default(message_count_by_level, LogLevel::WARNING, 0), - error_count = get_or_default(message_count_by_level, LogLevel::ERROR, 0); + int warning_count = get_or_default(message_count_by_level, LogLevel::WARNING_MSG, 0), + error_count = get_or_default(message_count_by_level, LogLevel::ERROR_MSG, 0); if (warning_count > 0 || error_count > 0) log_always("%d warning%s, %d error%s\n", warning_count, warning_count == 1 ? "" : "s", error_count, error_count == 1 ? "" : "s"); |