ERROR_NOT_SUPPORTED doesn't trigger Failed Hresult. Need E_NOTIMPL (#3396)

This commit is contained in:
Brian Martin 2020-04-01 10:06:00 -07:00 committed by GitHub
parent 052c1fda44
commit 77c7d09ced
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -154,7 +154,7 @@ bool IsFloat16Supported(const winrt::Windows::AI::MachineLearning::LearningModel
bool IsFloat16Supported(ID3D12Device* device) {
#ifndef USE_DML
throw winrt::hresult_error(ERROR_NOT_SUPPORTED, L"IsFloat16Supported is not implemented for WinML only build.");
throw winrt::hresult_error(E_NOTIMPL, L"IsFloat16Supported is not implemented for WinML only build.");
#else
bool isBlocked;
if (FAILED(IsFloat16Blocked(*device, &isBlocked)) || isBlocked) {