Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed issues preventing compilation on VS 2022 17.1. #2000

Merged
merged 1 commit into from
Mar 4, 2022
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
5 changes: 4 additions & 1 deletion src/AppInstallerCommonCore/Public/winget/Registry.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,17 @@ namespace AppInstaller::Registry
{
namespace details
{
template<DWORD>
constexpr bool dependent_false = false;

template <DWORD Type>
struct ValueTypeSpecifics
{
using value_t = void;

static value_t Convert(const std::vector<BYTE>& data)
{
static_assert(false, "No Type specific override has been supplied");
static_assert(dependent_false<Type>, "No Type specific override has been supplied");
}
};

Expand Down
9 changes: 6 additions & 3 deletions src/AppInstallerRepositoryCore/SQLiteWrapper.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,20 +32,23 @@ namespace AppInstaller::Repository::SQLite

namespace details
{
template<typename>
constexpr bool dependent_false = false;

template <typename T, typename = void>
struct ParameterSpecificsImpl
{
static T& ToLog(T&&)
{
static_assert(false, "No type specific override has been supplied");
static_assert(dependent_false<T>, "No type specific override has been supplied");
}
static void Bind(sqlite3_stmt*, int, T&&)
{
static_assert(false, "No type specific override has been supplied");
static_assert(dependent_false<T>, "No type specific override has been supplied");
}
static T GetColumn(sqlite3_stmt*, int)
{
static_assert(false, "No type specific override has been supplied");
static_assert(dependent_false<T>, "No type specific override has been supplied");
}
};

Expand Down