aboutsummaryrefslogtreecommitdiff
path: root/toolsrc/include
diff options
context:
space:
mode:
authorras0219 <533828+ras0219@users.noreply.github.com>2020-12-10 20:54:34 -0800
committerGitHub <noreply@github.com>2020-12-10 20:54:34 -0800
commitc2329ab26a6e9e06da101d8541c393c102ba6c8c (patch)
tree762cd489a062a85b218e67e4256edef22daec934 /toolsrc/include
parentc30903782c88967652178486a5f3e490fb2e8143 (diff)
downloadvcpkg-c2329ab26a6e9e06da101d8541c393c102ba6c8c.tar.gz
vcpkg-c2329ab26a6e9e06da101d8541c393c102ba6c8c.zip
[vcpkg] Improve error messages for incomplete Mono (#14948)
* [vcpkg] Improve error messages for incomplete Mono * [vcpkg] Add mono upgrade notice for Ubuntu 18.04 users * [vcpkg] Fix always failing to check CMake version due to preferring 'error' constructor in ExpectedS * [vcpkg] Eagerly display the 'Ubuntu needs new mono' message to avoid users needing to install it twice Co-authored-by: Robert Schumacher <roschuma@microsoft.com>
Diffstat (limited to 'toolsrc/include')
-rw-r--r--toolsrc/include/vcpkg/base/expected.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/toolsrc/include/vcpkg/base/expected.h b/toolsrc/include/vcpkg/base/expected.h
index 12bb64727..13e7b4bcb 100644
--- a/toolsrc/include/vcpkg/base/expected.h
+++ b/toolsrc/include/vcpkg/base/expected.h
@@ -110,7 +110,10 @@ namespace vcpkg
// Constructors are intentionally implicit
ExpectedT(const S& s, ExpectedRightTag = {}) : m_s(s) { }
- ExpectedT(S&& s, ExpectedRightTag = {}) : m_s(std::move(s)) { }
+ template<class = std::enable_if<!std::is_reference<S>::value>>
+ ExpectedT(S&& s, ExpectedRightTag = {}) : m_s(std::move(s))
+ {
+ }
ExpectedT(const T& t, ExpectedLeftTag = {}) : m_t(t) { }
template<class = std::enable_if<!std::is_reference<T>::value>>