aboutsummaryrefslogtreecommitdiff
path: root/toolsrc/include
diff options
context:
space:
mode:
authorAlexander Karatarakis <alkarata@microsoft.com>2017-04-03 16:27:51 -0700
committerAlexander Karatarakis <alkarata@microsoft.com>2017-04-04 16:44:45 -0700
commit95428f53691d232d961bb136f35d096967d38d5f (patch)
treeb9ce8db97c9aa4000d839e57aca7e70ef400a18d /toolsrc/include
parent9e19213498a4f77aa9b55ce1e81a3efaabfc9844 (diff)
downloadvcpkg-95428f53691d232d961bb136f35d096967d38d5f.tar.gz
vcpkg-95428f53691d232d961bb136f35d096967d38d5f.zip
optional<T> -> Optional<T>
Diffstat (limited to 'toolsrc/include')
-rw-r--r--toolsrc/include/vcpkg_Dependencies.h6
-rw-r--r--toolsrc/include/vcpkg_System.h4
-rw-r--r--toolsrc/include/vcpkg_optional.h14
3 files changed, 12 insertions, 12 deletions
diff --git a/toolsrc/include/vcpkg_Dependencies.h b/toolsrc/include/vcpkg_Dependencies.h
index b734295fc..f04c41574 100644
--- a/toolsrc/include/vcpkg_Dependencies.h
+++ b/toolsrc/include/vcpkg_Dependencies.h
@@ -25,15 +25,15 @@ namespace vcpkg::Dependencies
struct InstallPlanAction
{
InstallPlanAction();
- InstallPlanAction(const InstallPlanType& plan_type, optional<BinaryParagraph> binary_pgh, optional<SourceParagraph> source_pgh);
+ InstallPlanAction(const InstallPlanType& plan_type, Optional<BinaryParagraph> binary_pgh, Optional<SourceParagraph> source_pgh);
InstallPlanAction(const InstallPlanAction&) = delete;
InstallPlanAction(InstallPlanAction&&) = default;
InstallPlanAction& operator=(const InstallPlanAction&) = delete;
InstallPlanAction& operator=(InstallPlanAction&&) = default;
InstallPlanType plan_type;
- optional<BinaryParagraph> binary_pgh;
- optional<SourceParagraph> source_pgh;
+ Optional<BinaryParagraph> binary_pgh;
+ Optional<SourceParagraph> source_pgh;
};
struct PackageSpecWithInstallPlan
diff --git a/toolsrc/include/vcpkg_System.h b/toolsrc/include/vcpkg_System.h
index 2c2b945f4..e4f93ad8f 100644
--- a/toolsrc/include/vcpkg_System.h
+++ b/toolsrc/include/vcpkg_System.h
@@ -59,9 +59,9 @@ namespace vcpkg::System
return println(c, Strings::format(messageTemplate, messageArg1, messageArgs...));
}
- optional<std::wstring> get_environmental_variable(const CWStringView varname) noexcept;
+ Optional<std::wstring> get_environmental_variable(const CWStringView varname) noexcept;
- optional<std::wstring> get_registry_string(HKEY base, const CWStringView subkey, const CWStringView valuename);
+ Optional<std::wstring> get_registry_string(HKEY base, const CWStringView subkey, const CWStringView valuename);
const fs::path& get_ProgramFiles_32_bit();
diff --git a/toolsrc/include/vcpkg_optional.h b/toolsrc/include/vcpkg_optional.h
index 5aea6cc59..4a2ceec30 100644
--- a/toolsrc/include/vcpkg_optional.h
+++ b/toolsrc/include/vcpkg_optional.h
@@ -4,23 +4,23 @@
namespace vcpkg
{
- struct nullopt_t
+ struct NullOpt
{
- explicit constexpr nullopt_t(int) {}
+ explicit constexpr NullOpt(int) {}
};
- const static constexpr nullopt_t nullopt{ 0 };
+ const static constexpr NullOpt nullopt{ 0 };
template <class T>
- class optional
+ class Optional
{
public:
// Constructors are intentionally implicit
- constexpr optional(nullopt_t) : m_is_present(false), m_t() { }
+ constexpr Optional(NullOpt) : m_is_present(false), m_t() { }
- optional(const T& t) : m_is_present(true), m_t(t) { }
+ Optional(const T& t) : m_is_present(true), m_t(t) { }
- optional(T&& t) : m_is_present(true), m_t(std::move(t)) { }
+ Optional(T&& t) : m_is_present(true), m_t(std::move(t)) { }
T&& value_or_exit(const LineInfo& line_info) &&
{