commit 83b9068bf35e2ba69d3a40ee87e3e47187648364 parent 001b4040409561ef0aec1e9380f78aa1b2a5cb9b Author: serge-sans-paille <sguelton@mozilla.com> Date: Wed, 12 Nov 2025 17:49:20 +0000 Bug 1999710 - Remove unused STL header inclusions in gfx/** r=gfx-reviewers,lsalzman Differential Revision: https://phabricator.services.mozilla.com/D272281 Diffstat:
40 files changed, 0 insertions(+), 50 deletions(-)
diff --git a/gfx/2d/DrawTargetCairo.cpp b/gfx/2d/DrawTargetCairo.cpp @@ -42,8 +42,6 @@ #define PIXMAN_DONT_DEFINE_STDINT #include "pixman.h" -#include <algorithm> - // 2^23 #define CAIRO_COORD_MAX (Float(0x7fffff)) diff --git a/gfx/2d/DrawTargetOffset.h b/gfx/2d/DrawTargetOffset.h @@ -12,8 +12,6 @@ #include "Filters.h" #include "Logging.h" -#include <vector> - namespace mozilla { namespace gfx { diff --git a/gfx/2d/Filters.h b/gfx/2d/Filters.h @@ -12,7 +12,6 @@ #include "Point.h" #include "Matrix.h" -#include <vector> namespace mozilla { namespace gfx { diff --git a/gfx/2d/ImageScaling.h b/gfx/2d/ImageScaling.h @@ -9,7 +9,6 @@ #include "Types.h" -#include <vector> #include "Point.h" namespace mozilla { diff --git a/gfx/2d/IterableArena.h b/gfx/2d/IterableArena.h @@ -12,7 +12,6 @@ #include <string.h> #include <utility> -#include <vector> #include "mozilla/Assertions.h" #include "mozilla/gfx/Logging.h" diff --git a/gfx/2d/Matrix.cpp b/gfx/2d/Matrix.cpp @@ -7,7 +7,6 @@ #include "Matrix.h" #include "Quaternion.h" #include "Tools.h" -#include <algorithm> #include <ostream> #include <math.h> #include <float.h> // for FLT_EPSILON diff --git a/gfx/2d/NativeFontResourceMac.cpp b/gfx/2d/NativeFontResourceMac.cpp @@ -5,7 +5,6 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ #include <unordered_map> -#include <unordered_set> #include "NativeFontResourceMac.h" #include "UnscaledFontMac.h" #include "Types.h" diff --git a/gfx/2d/Quaternion.cpp b/gfx/2d/Quaternion.cpp @@ -7,7 +7,6 @@ #include "Quaternion.h" #include "Matrix.h" #include "Tools.h" -#include <algorithm> #include <ostream> #include <math.h> diff --git a/gfx/2d/RecordedEvent.h b/gfx/2d/RecordedEvent.h @@ -11,7 +11,6 @@ #include <sstream> #include <cstring> #include <functional> -#include <vector> #include "RecordingTypes.h" #include "mozilla/PodOperations.h" diff --git a/gfx/gl/SharedSurface.h b/gfx/gl/SharedSurface.h @@ -16,7 +16,6 @@ #define SHARED_SURFACE_H_ #include <queue> -#include <set> #include <stdint.h> #include "GLContext.h" // Bug 1635644 diff --git a/gfx/layers/AnimationHelper.h b/gfx/layers/AnimationHelper.h @@ -14,7 +14,6 @@ #include "mozilla/TimeStamp.h" // for TimeStamp #include "mozilla/TimingParams.h" #include "X11UndefineNone.h" -#include <unordered_map> namespace mozilla::layers { class Animation; diff --git a/gfx/layers/Compositor.h b/gfx/layers/Compositor.h @@ -23,7 +23,6 @@ #include "mozilla/widget/CompositorWidget.h" #include "nsISupportsImpl.h" // for MOZ_COUNT_CTOR, etc #include "nsRegion.h" -#include <vector> #include "mozilla/WidgetUtils.h" /** diff --git a/gfx/layers/D3D11ShareHandleImage.cpp b/gfx/layers/D3D11ShareHandleImage.cpp @@ -5,7 +5,6 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ #include "D3D11ShareHandleImage.h" -#include <memory> #include "DXVA2Manager.h" #include "WMF.h" #include "d3d11.h" diff --git a/gfx/layers/D3D11ZeroCopyTextureImage.cpp b/gfx/layers/D3D11ZeroCopyTextureImage.cpp @@ -5,7 +5,6 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ #include <d3d11.h> -#include <memory> #include <mfobjects.h> #include "D3D11ZeroCopyTextureImage.h" diff --git a/gfx/layers/NativeLayerCA.h b/gfx/layers/NativeLayerCA.h @@ -9,7 +9,6 @@ #include <IOSurface/IOSurfaceRef.h> #include <deque> -#include <unordered_map> #include <ostream> #include "mozilla/Mutex.h" diff --git a/gfx/layers/NativeLayerWayland.h b/gfx/layers/NativeLayerWayland.h @@ -7,7 +7,6 @@ #define mozilla_layers_NativeLayerWayland_h #include <deque> -#include <unordered_map> #include "mozilla/Mutex.h" #include "mozilla/layers/NativeLayer.h" diff --git a/gfx/layers/apz/public/APZPublicUtils.h b/gfx/layers/apz/public/APZPublicUtils.h @@ -11,7 +11,6 @@ // of gfx/layers. For internal utilities, prefer APZUtils.h. #include <stdint.h> -#include <utility> #include "ScrollAnimationBezierPhysics.h" #include "Units.h" #include "mozilla/DefineEnum.h" diff --git a/gfx/layers/apz/src/APZUtils.h b/gfx/layers/apz/src/APZUtils.h @@ -13,7 +13,6 @@ // Do not include this header from source files outside of gfx/layers. #include <stdint.h> // for uint32_t -#include <type_traits> #include "gfxTypes.h" #include "FrameMetrics.h" #include "LayersTypes.h" diff --git a/gfx/layers/apz/util/APZEventState.h b/gfx/layers/apz/util/APZEventState.h @@ -23,7 +23,6 @@ #include "nsIWeakReferenceUtils.h" // for nsWeakPtr #include <functional> -#include <unordered_map> template <class> class nsCOMPtr; diff --git a/gfx/layers/client/CompositableClient.h b/gfx/layers/client/CompositableClient.h @@ -9,9 +9,6 @@ #include <stdint.h> // for uint64_t -#include <map> // for map -#include <vector> // for vector - #include "mozilla/Assertions.h" // for MOZ_CRASH #include "mozilla/DataMutex.h" #include "mozilla/RefPtr.h" // for already_AddRefed, RefCounted diff --git a/gfx/layers/composite/CompositableHost.cpp b/gfx/layers/composite/CompositableHost.cpp @@ -5,8 +5,6 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ #include "CompositableHost.h" -#include <map> // for _Rb_tree_iterator, map, etc -#include <utility> // for pair #include "Effects.h" // for EffectMask, Effect, etc #include "gfxUtils.h" #include "mozilla/gfx/gfxVars.h" diff --git a/gfx/layers/ipc/APZCTreeManagerChild.h b/gfx/layers/ipc/APZCTreeManagerChild.h @@ -11,8 +11,6 @@ #include "mozilla/layers/IAPZCTreeManager.h" #include "mozilla/layers/PAPZCTreeManagerChild.h" -#include <unordered_map> - namespace mozilla { namespace layers { diff --git a/gfx/layers/ipc/CanvasTranslator.h b/gfx/layers/ipc/CanvasTranslator.h @@ -10,7 +10,6 @@ #include <deque> #include <memory> #include <unordered_map> -#include <vector> #include "mozilla/dom/ipc/IdType.h" #include "mozilla/gfx/InlineTranslator.h" diff --git a/gfx/layers/ipc/CompositableTransactionParent.h b/gfx/layers/ipc/CompositableTransactionParent.h @@ -7,7 +7,6 @@ #ifndef MOZILLA_LAYERS_COMPOSITABLETRANSACTIONPARENT_H #define MOZILLA_LAYERS_COMPOSITABLETRANSACTIONPARENT_H -#include <vector> // for vector #include "mozilla/NotNull.h" #include "mozilla/layers/ISurfaceAllocator.h" // for ISurfaceAllocator #include "mozilla/layers/LayersMessages.h" // for EditReply, etc diff --git a/gfx/layers/ipc/CompositorBridgeParent.cpp b/gfx/layers/ipc/CompositorBridgeParent.cpp @@ -8,7 +8,6 @@ #include <stdio.h> // for fprintf, stdout #include <stdint.h> // for uint64_t -#include <map> // for _Rb_tree_iterator, etc #include <utility> // for pair #include "apz/src/APZCTreeManager.h" // for APZCTreeManager diff --git a/gfx/layers/ipc/LayerTreeOwnerTracker.cpp b/gfx/layers/ipc/LayerTreeOwnerTracker.cpp @@ -11,7 +11,6 @@ #include "mozilla/gfx/GPUProcessManager.h" // for GPUProcessManager #include <functional> -#include <utility> // for std::make_pair namespace mozilla { namespace layers { diff --git a/gfx/layers/opengl/CompositorOGL.h b/gfx/layers/opengl/CompositorOGL.h @@ -7,8 +7,6 @@ #ifndef MOZILLA_GFX_COMPOSITOROGL_H #define MOZILLA_GFX_COMPOSITOROGL_H -#include <map> -#include <unordered_map> #include <unordered_set> #include "gfx2DGlue.h" diff --git a/gfx/layers/wr/WebRenderBridgeParent.h b/gfx/layers/wr/WebRenderBridgeParent.h @@ -8,7 +8,6 @@ #define mozilla_layers_WebRenderBridgeParent_h #include <unordered_map> -#include <unordered_set> #include "CompositableHost.h" // for CompositableHost, ImageCompositeNotificationInfo #include "GLContextProvider.h" diff --git a/gfx/layers/wr/WebRenderScrollData.h b/gfx/layers/wr/WebRenderScrollData.h @@ -7,7 +7,6 @@ #ifndef GFX_WEBRENDERSCROLLDATA_H #define GFX_WEBRENDERSCROLLDATA_H -#include <map> #include <iosfwd> #include "chrome/common/ipc_message_utils.h" diff --git a/gfx/tests/gtest/TestArrayView.cpp b/gfx/tests/gtest/TestArrayView.cpp @@ -3,7 +3,6 @@ /* This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ -#include <limits> #include "gtest/gtest.h" diff --git a/gfx/tests/gtest/TextureHelper.h b/gfx/tests/gtest/TextureHelper.h @@ -4,8 +4,6 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ -#include <vector> - #include "Types.h" #include "gfxImageSurface.h" #include "gfxPlatform.h" diff --git a/gfx/thebes/DeviceManagerDx.h b/gfx/thebes/DeviceManagerDx.h @@ -7,7 +7,6 @@ #define mozilla_gfx_thebes_DeviceManagerDx_h #include <set> -#include <vector> #include "gfxPlatform.h" #include "gfxTelemetry.h" diff --git a/gfx/thebes/PrintTargetSkPDF.cpp b/gfx/thebes/PrintTargetSkPDF.cpp @@ -7,7 +7,6 @@ #include "mozilla/gfx/2D.h" #include "nsString.h" -#include <vector> #include "skia/src/pdf/SkPDFUtils.h" diff --git a/gfx/thebes/gfxASurface.cpp b/gfx/thebes/gfxASurface.cpp @@ -19,7 +19,6 @@ #include "gfxRect.h" #include "cairo.h" -#include <algorithm> #ifdef CAIRO_HAS_WIN32_SURFACE # include "gfxWindowsSurface.h" diff --git a/gfx/thebes/gfxBlur.cpp b/gfx/thebes/gfxBlur.cpp @@ -15,7 +15,6 @@ #include "nsExpirationTracker.h" #include "nsClassHashtable.h" #include "gfxUtils.h" -#include <limits> #include <cmath> using namespace mozilla; diff --git a/gfx/thebes/gfxFont.h b/gfx/thebes/gfxFont.h @@ -8,7 +8,6 @@ #define GFX_FONT_H #include <new> -#include <utility> #include <functional> #include "PLDHashTable.h" #include "ThebesRLBoxTypes.h" diff --git a/gfx/thebes/gfxFontUtils.h b/gfx/thebes/gfxFontUtils.h @@ -9,7 +9,6 @@ #include <string.h> #include <algorithm> #include <new> -#include <utility> #include "gfxPlatform.h" #include "harfbuzz/hb.h" #include "mozilla/Assertions.h" diff --git a/gfx/thebes/gfxPattern.cpp b/gfx/thebes/gfxPattern.cpp @@ -14,8 +14,6 @@ #include "cairo.h" -#include <vector> - using namespace mozilla::gfx; gfxPattern::gfxPattern(const DeviceColor& aColor) : mExtend(ExtendMode::CLAMP) { diff --git a/gfx/thebes/gfxWindowsPlatform.cpp b/gfx/thebes/gfxWindowsPlatform.cpp @@ -51,8 +51,6 @@ #include "nsWindowsHelpers.h" #include "gfx2DGlue.h" -#include <string> - #include <d3d10_1.h> #include "mozilla/gfx/2D.h" diff --git a/gfx/webrender_bindings/WebRenderAPI.h b/gfx/webrender_bindings/WebRenderAPI.h @@ -11,7 +11,6 @@ #include <stdint.h> #include <vector> #include <unordered_map> -#include <unordered_set> #include "mozilla/AlreadyAddRefed.h" #include "mozilla/gfx/CompositorHitTestInfo.h"