aboutsummaryrefslogtreecommitdiff
path: root/toolsrc/include
diff options
context:
space:
mode:
authorAlexander Karatarakis <alkarata@microsoft.com>2017-04-03 14:43:44 -0700
committerAlexander Karatarakis <alkarata@microsoft.com>2017-04-04 16:44:41 -0700
commit1c1423014f5aab77339ebcb261e1d33e3106ec5d (patch)
tree61d1e76d550cecefbc4a31b4803137d9cbcf0c43 /toolsrc/include
parent830a4d97d470dad6ca4a27ef1eecce17057fa432 (diff)
downloadvcpkg-1c1423014f5aab77339ebcb261e1d33e3106ec5d.tar.gz
vcpkg-1c1423014f5aab77339ebcb261e1d33e3106ec5d.zip
opt_bool->OptBool
Diffstat (limited to 'toolsrc/include')
-rw-r--r--toolsrc/include/OptBool.h (renamed from toolsrc/include/opt_bool.h)12
-rw-r--r--toolsrc/include/PostBuildLint_BuildInfo.h4
-rw-r--r--toolsrc/include/vcpkg_cmd_arguments.h8
3 files changed, 12 insertions, 12 deletions
diff --git a/toolsrc/include/opt_bool.h b/toolsrc/include/OptBool.h
index 06642a399..4098e6f03 100644
--- a/toolsrc/include/opt_bool.h
+++ b/toolsrc/include/OptBool.h
@@ -3,24 +3,24 @@
#include <string>
#include <map>
-namespace vcpkg::opt_bool
+namespace vcpkg::OptBool
{
- enum class type
+ enum class Type
{
UNSPECIFIED = 0,
ENABLED,
DISABLED
};
- type parse(const std::string& s);
+ Type parse(const std::string& s);
template <class T>
- type from_map(const std::map<T, std::string>& map, const T& key)
+ Type from_map(const std::map<T, std::string>& map, const T& key)
{
auto it = map.find(key);
if (it == map.cend())
{
- return type::UNSPECIFIED;
+ return Type::UNSPECIFIED;
}
return parse(*it);
@@ -29,5 +29,5 @@ namespace vcpkg::opt_bool
namespace vcpkg
{
- using opt_bool_t = opt_bool::type;
+ using OptBoolT = OptBool::Type;
} \ No newline at end of file
diff --git a/toolsrc/include/PostBuildLint_BuildInfo.h b/toolsrc/include/PostBuildLint_BuildInfo.h
index bac024e01..cbc944488 100644
--- a/toolsrc/include/PostBuildLint_BuildInfo.h
+++ b/toolsrc/include/PostBuildLint_BuildInfo.h
@@ -2,7 +2,7 @@
#include "filesystem_fs.h"
#include "PostBuildLint_BuildPolicies.h"
-#include "opt_bool.h"
+#include "OptBool.h"
#include "PostBuildLint_LinkageType.h"
namespace vcpkg::PostBuildLint
@@ -14,7 +14,7 @@ namespace vcpkg::PostBuildLint
LinkageType::type crt_linkage;
LinkageType::type library_linkage;
- std::map<BuildPolicies::type, opt_bool_t> policies;
+ std::map<BuildPolicies::type, OptBoolT> policies;
};
BuildInfo read_build_info(const fs::path& filepath);
diff --git a/toolsrc/include/vcpkg_cmd_arguments.h b/toolsrc/include/vcpkg_cmd_arguments.h
index 91f7de8ac..6f06ad98d 100644
--- a/toolsrc/include/vcpkg_cmd_arguments.h
+++ b/toolsrc/include/vcpkg_cmd_arguments.h
@@ -3,7 +3,7 @@
#include <memory>
#include <vector>
#include <unordered_set>
-#include "opt_bool.h"
+#include "OptBool.h"
namespace vcpkg
{
@@ -14,9 +14,9 @@ namespace vcpkg
std::unique_ptr<std::string> vcpkg_root_dir;
std::unique_ptr<std::string> target_triplet;
- opt_bool_t debug = opt_bool_t::UNSPECIFIED;
- opt_bool_t sendmetrics = opt_bool_t::UNSPECIFIED;
- opt_bool_t printmetrics = opt_bool_t::UNSPECIFIED;
+ OptBoolT debug = OptBoolT::UNSPECIFIED;
+ OptBoolT sendmetrics = OptBoolT::UNSPECIFIED;
+ OptBoolT printmetrics = OptBoolT::UNSPECIFIED;
std::string command;
std::vector<std::string> command_arguments;