From 7e0278b5426162f47b6a79916d78ff5db20fa7cd Mon Sep 17 00:00:00 2001 From: tastytea Date: Sun, 29 Dec 2019 08:46:15 +0100 Subject: [PATCH] Reduce scope of using declarations in main.cpp. --- src/main.cpp | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index fc9d433..c81f5ad 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -16,18 +16,11 @@ #include #include -using namespace mastorss; -using std::chrono::seconds; -using std::getenv; -using std::cout; -using std::cerr; -using std::runtime_error; -using std::string_view; -using std::vector; -using std::this_thread::sleep_for; - namespace mastorss { +using std::cout; +using std::cerr; + namespace error { constexpr int noprofile = 1; @@ -60,6 +53,15 @@ void print_help(const string_view &command) int main(int argc, char *argv[]) { + using namespace mastorss; + using std::chrono::seconds; + using std::getenv; + using std::cerr; + using std::runtime_error; + using std::string_view; + using std::vector; + using std::this_thread::sleep_for; + const vector args(argv, argv + argc); if (getenv("MASTORSS_DEBUG") == nullptr)