From a56069b03d95d96cb90aa8a62d33ad45e0d79fe4 Mon Sep 17 00:00:00 2001 From: Peng Huang Date: Tue, 14 Mar 2023 15:47:02 +0000 Subject: [PATCH] Remove some unnecessary #include Change-Id: I51382e4b4d68da55631d37b1b72fecaaef2b16ee Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/124020 Reviewed-by: Austin Eng Commit-Queue: Peng Huang Kokoro: Kokoro --- src/dawn/native/d3d/PlatformFunctions.cpp | 2 -- src/dawn/native/d3d/PlatformFunctions.h | 3 +-- src/dawn/native/d3d12/PlatformFunctionsD3D12.cpp | 9 +-------- src/dawn/native/d3d12/PlatformFunctionsD3D12.h | 10 +--------- 4 files changed, 3 insertions(+), 21 deletions(-) diff --git a/src/dawn/native/d3d/PlatformFunctions.cpp b/src/dawn/native/d3d/PlatformFunctions.cpp index 52bfa0d0e9..4295fdb4ba 100644 --- a/src/dawn/native/d3d/PlatformFunctions.cpp +++ b/src/dawn/native/d3d/PlatformFunctions.cpp @@ -21,8 +21,6 @@ #include #include -#include "dawn/common/DynamicLib.h" - namespace dawn::native::d3d { namespace { // Extract Version from "10.0.{Version}.0" if possible, otherwise return 0. diff --git a/src/dawn/native/d3d/PlatformFunctions.h b/src/dawn/native/d3d/PlatformFunctions.h index 59fe910235..f039078348 100644 --- a/src/dawn/native/d3d/PlatformFunctions.h +++ b/src/dawn/native/d3d/PlatformFunctions.h @@ -19,10 +19,9 @@ #include -#include "dawn/native/d3d/d3d_platform.h" - #include "dawn/common/DynamicLib.h" #include "dawn/native/Error.h" +#include "dawn/native/d3d/d3d_platform.h" namespace dawn::native::d3d { diff --git a/src/dawn/native/d3d12/PlatformFunctionsD3D12.cpp b/src/dawn/native/d3d12/PlatformFunctionsD3D12.cpp index a2499976c8..2cd1c40582 100644 --- a/src/dawn/native/d3d12/PlatformFunctionsD3D12.cpp +++ b/src/dawn/native/d3d12/PlatformFunctionsD3D12.cpp @@ -14,14 +14,7 @@ #include "dawn/native/d3d12/PlatformFunctionsD3D12.h" -#include - -#include -#include -#include -#include - -#include "dawn/common/DynamicLib.h" +#include namespace dawn::native::d3d12 { diff --git a/src/dawn/native/d3d12/PlatformFunctionsD3D12.h b/src/dawn/native/d3d12/PlatformFunctionsD3D12.h index af6ae358af..22c59d82b7 100644 --- a/src/dawn/native/d3d12/PlatformFunctionsD3D12.h +++ b/src/dawn/native/d3d12/PlatformFunctionsD3D12.h @@ -15,22 +15,14 @@ #ifndef SRC_DAWN_NATIVE_D3D12_PLATFORMFUNCTIONS_H_ #define SRC_DAWN_NATIVE_D3D12_PLATFORMFUNCTIONS_H_ -#include - -#include - #include "dawn/native/d3d/PlatformFunctions.h" #include "dawn/native/d3d12/d3d12_platform.h" #include "dawn/common/DynamicLib.h" -#include "dawn/native/Error.h" namespace dawn::native::d3d12 { -// Loads the functions required from the platform dynamically so that we don't need to rely on -// them being present in the system. For example linking against d3d12.lib would prevent -// dawn_native from loading on Windows 7 system where d3d12.dll doesn't exist. -class PlatformFunctions : public d3d::PlatformFunctions { +class PlatformFunctions final : public d3d::PlatformFunctions { public: PlatformFunctions(); ~PlatformFunctions() override;