Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 10 additions & 8 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,25 +15,25 @@ jobs:
fail-fast: false

matrix:
os: [windows-2019, windows-2022]
toolset: [142, 143]
cppstd: ['17', '20', '23']
build-type: [Debug, Release]
exclude:
- os: windows-2019
- toolset: 142
cppstd: '23'
include:
- os: windows-2019
msvc-version: 142
- os: windows-2022
msvc-version: 143
- toolset: 142
conan-compiler-version: 192
- toolset: 143
conan-compiler-version: 194
- build-type: Debug
cmake-preset: conan-debug
- build-type: Release
cmake-preset: conan-release

name: MSVC ${{ matrix.msvc-version }} - C++${{ matrix.cppstd }} - ${{ matrix.build-type }}
name: MSVC ${{ matrix.toolset }} - C++${{ matrix.cppstd }} - ${{ matrix.build-type }}

runs-on: ${{ matrix.os }}
runs-on: windows-2022

steps:
- uses: actions/checkout@v4
Expand All @@ -52,6 +52,8 @@ jobs:
- name: Install dependencies
run: >
conan install .
-c tools.microsoft.msbuild:vs_version=17
-s compiler.version=${{ matrix.conan-compiler-version }}
-s compiler.cppstd=${{ matrix.cppstd }}
-s build_type=${{ matrix.build-type }}
-b missing
Expand Down
10 changes: 5 additions & 5 deletions include/zeus/expected.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

#define ZEUS_EXPECTED_VERSION_MAJOR 1
#define ZEUS_EXPECTED_VERSION_MINOR 3
#define ZEUS_EXPECTED_VERSION_PATCH 0
#define ZEUS_EXPECTED_VERSION_PATCH 1

#if defined(_MSVC_LANG)
#define ZEUS_EXPECTED_CPLUSPLUS _MSVC_LANG
Expand Down Expand Up @@ -197,14 +197,14 @@ class unexpected
friend constexpr void swap(unexpected &x, unexpected &y) noexcept(noexcept(x.swap(y))) { x.swap(y); }

template<class E2>
friend constexpr bool operator==(const unexpected &lhs, const unexpected<E2> &rhs) noexcept(noexcept(lhs.m_val == rhs.error()))
friend constexpr bool operator==(const unexpected &lhs, const unexpected<E2> &rhs) noexcept(noexcept(lhs.error() == rhs.error()))
{
return lhs.m_val == rhs.error();
return lhs.error() == rhs.error();
}
template<class E2>
friend constexpr bool operator!=(const unexpected &lhs, const unexpected<E2> &rhs) noexcept(noexcept(lhs.m_val != rhs.error()))
friend constexpr bool operator!=(const unexpected &lhs, const unexpected<E2> &rhs) noexcept(noexcept(lhs.error() != rhs.error()))
{
return lhs.m_val != rhs.error();
return lhs.error() != rhs.error();
}

private:
Expand Down