From 96dcfa6b446e5e94143b2d83c587d09b0d00031f Mon Sep 17 00:00:00 2001 From: Alex Turbov Date: Tue, 23 Aug 2022 20:31:35 +0400 Subject: ccmake.cxx: Use anonymous namespace instead of `static` --- Source/CursesDialog/ccmake.cxx | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/Source/CursesDialog/ccmake.cxx b/Source/CursesDialog/ccmake.cxx index 70ed648..2986265 100644 --- a/Source/CursesDialog/ccmake.cxx +++ b/Source/CursesDialog/ccmake.cxx @@ -23,12 +23,13 @@ #include "cmSystemTools.h" #include "cmake.h" -static const char* cmDocumentationName[][2] = { +namespace { +const char* cmDocumentationName[][2] = { { nullptr, " ccmake - Curses Interface for CMake." }, { nullptr, nullptr } }; -static const char* cmDocumentationUsage[][2] = { +const char* cmDocumentationUsage[][2] = { { nullptr, " ccmake \n" " ccmake " }, @@ -39,22 +40,18 @@ static const char* cmDocumentationUsage[][2] = { { nullptr, nullptr } }; -static const char* cmDocumentationUsageNote[][2] = { +const char* cmDocumentationUsageNote[][2] = { { nullptr, "Run 'ccmake --help' for more information." }, { nullptr, nullptr } }; -static const char* cmDocumentationOptions[][2] = { - CMAKE_STANDARD_OPTIONS_TABLE, - { nullptr, nullptr } -}; - -cmCursesForm* cmCursesForm::CurrentForm = nullptr; +const char* cmDocumentationOptions[][2] = { CMAKE_STANDARD_OPTIONS_TABLE, + { nullptr, nullptr } }; #ifndef _WIN32 extern "C" { -static void onsig(int /*unused*/) +void onsig(int /*unused*/) { if (cmCursesForm::CurrentForm) { cmCursesForm::CurrentForm->HandleResize(); @@ -63,6 +60,9 @@ static void onsig(int /*unused*/) } } #endif // _WIN32 +} // anonymous namespace + +cmCursesForm* cmCursesForm::CurrentForm = nullptr; int main(int argc, char const* const* argv) { -- cgit v0.12