diff --git a/DirectXTex/scoped.h b/DirectXTex/scoped.h index 3b9d566..9d8832d 100644 --- a/DirectXTex/scoped.h +++ b/DirectXTex/scoped.h @@ -16,21 +16,21 @@ //--------------------------------------------------------------------------------- struct aligned_deleter { void operator()(void* p) noexcept { _aligned_free(p); } }; -typedef std::unique_ptr ScopedAlignedArrayFloat; +using ScopedAlignedArrayFloat = std::unique_ptr; -typedef std::unique_ptr ScopedAlignedArrayXMVECTOR; +using ScopedAlignedArrayXMVECTOR = std::unique_ptr; //--------------------------------------------------------------------------------- struct handle_closer { void operator()(HANDLE h) noexcept { assert(h != INVALID_HANDLE_VALUE); if (h) CloseHandle(h); } }; -typedef std::unique_ptr ScopedHandle; +using ScopedHandle = std::unique_ptr; inline HANDLE safe_handle(HANDLE h) noexcept { return (h == INVALID_HANDLE_VALUE) ? nullptr : h; } //--------------------------------------------------------------------------------- struct find_closer { void operator()(HANDLE h) noexcept { assert(h != INVALID_HANDLE_VALUE); if (h) FindClose(h); } }; -typedef std::unique_ptr ScopedFindHandle; +using ScopedFindHandle = std::unique_ptr; //--------------------------------------------------------------------------------- class auto_delete_file diff --git a/Texassemble/texassemble.cpp b/Texassemble/texassemble.cpp index 8b54a3b..68edbc4 100644 --- a/Texassemble/texassemble.cpp +++ b/Texassemble/texassemble.cpp @@ -298,7 +298,7 @@ namespace struct find_closer { void operator()(HANDLE h) { assert(h != INVALID_HANDLE_VALUE); if (h) FindClose(h); } }; - typedef std::unique_ptr ScopedFindHandle; + using ScopedFindHandle = std::unique_ptr; #ifdef _PREFAST_ #pragma prefast(disable : 26018, "Only used with static internal arrays") diff --git a/Texconv/texconv.cpp b/Texconv/texconv.cpp index 97d423d..335688c 100644 --- a/Texconv/texconv.cpp +++ b/Texconv/texconv.cpp @@ -449,11 +449,11 @@ namespace struct handle_closer { void operator()(HANDLE h) { assert(h != INVALID_HANDLE_VALUE); if (h) CloseHandle(h); } }; - typedef std::unique_ptr ScopedHandle; + using ScopedHandle = std::unique_ptr; struct find_closer { void operator()(HANDLE h) { assert(h != INVALID_HANDLE_VALUE); if (h) FindClose(h); } }; - typedef std::unique_ptr ScopedFindHandle; + using ScopedFindHandle = std::unique_ptr; inline static bool ispow2(size_t x) { diff --git a/Texdiag/texdiag.cpp b/Texdiag/texdiag.cpp index 5d1d680..459d273 100644 --- a/Texdiag/texdiag.cpp +++ b/Texdiag/texdiag.cpp @@ -363,7 +363,7 @@ namespace struct find_closer { void operator()(HANDLE h) { assert(h != INVALID_HANDLE_VALUE); if (h) FindClose(h); } }; - typedef std::unique_ptr ScopedFindHandle; + using ScopedFindHandle = std::unique_ptr; #ifdef _PREFAST_ #pragma prefast(disable : 26018, "Only used with static internal arrays")