Bug 1156632 - Remove unused forward class declarations - patch 4 - netwerk image and dom, r=ehsan
authorAndrea Marchesini <amarchesini@mozilla.com>
Wed, 22 Apr 2015 08:29:20 +0200
changeset 259359 60a2001adf9acc476ecb1ceb5652618c70e56f50
parent 259358 7617f4ffb3145987ec717a29789ff5636889fbf8
child 259360 d47f66ce3822cd4b95c99b3c0b123584486d119c
push idunknown
push userunknown
push dateunknown
reviewersehsan
bugs1156632
milestone40.0a1
Bug 1156632 - Remove unused forward class declarations - patch 4 - netwerk image and dom, r=ehsan
caps/DomainPolicy.h
caps/nsJSPrincipals.h
caps/nsPrincipal.h
caps/nsScriptSecurityManager.h
dom/battery/BatteryManager.h
dom/cache/OfflineStorage.h
dom/cache/ReadStream.h
dom/camera/GonkCameraControl.h
dom/camera/ICameraControl.h
dom/canvas/CanvasRenderingContext2D.h
dom/canvas/CanvasUtils.h
dom/canvas/WebGLContext.h
dom/canvas/WebGLFramebuffer.h
dom/canvas/WebGLObjectModel.h
dom/canvas/WebGLShaderPrecisionFormat.h
dom/canvas/nsICanvasRenderingContextInternal.h
dom/gamepad/GamepadService.h
dom/mobilemessage/MobileMessageCallback.h
dom/mobilemessage/ipc/SmsIPCService.h
dom/network/TCPServerSocketParent.h
dom/network/TCPSocketParent.h
dom/offline/nsDOMOfflineResourceList.h
dom/plugins/base/android/android_npapi.h
dom/plugins/base/nsPluginHost.h
dom/plugins/base/nsPluginInstanceOwner.h
dom/plugins/base/nsPluginTags.h
dom/plugins/ipc/PluginInstanceChild.h
dom/plugins/ipc/PluginInstanceParent.h
dom/plugins/ipc/PluginModuleChild.h
dom/plugins/ipc/PluginScriptableObjectParent.h
dom/quota/Client.h
dom/quota/QuotaManager.h
dom/quota/nsIOfflineStorage.h
dom/security/nsCORSListenerProxy.h
dom/vr/VRDevice.h
dom/xml/XMLDocument.h
dom/xml/nsXMLContentSink.h
image/encoders/ico/nsICOEncoder.h
image/src/DecodePool.h
image/src/ProgressTracker.h
image/src/RasterImage.h
image/src/SVGDocumentWrapper.h
image/src/VectorImage.h
ipc/dbus/RawDBusConnection.h
ipc/glue/GeckoChildProcessHost.h
ipc/glue/nsIIPCSerializableInputStream.h
modules/libjar/nsJAR.h
modules/libpref/Preferences.h
netwerk/base/ChannelDiverterChild.h
netwerk/base/Dashboard.h
netwerk/base/Predictor.h
netwerk/base/nsNativeConnectionHelper.h
netwerk/cache/nsDiskCacheStreams.h
netwerk/cache2/CacheEntry.h
netwerk/cache2/CacheFileIOManager.h
netwerk/cache2/CacheStorageService.h
netwerk/cookie/CookieServiceParent.h
netwerk/cookie/nsCookieService.h
netwerk/ipc/ChannelEventQueue.h
netwerk/protocol/ftp/FTPChannelParent.h
netwerk/protocol/http/ASpdySession.h
netwerk/protocol/http/HttpChannelParentListener.h
netwerk/protocol/http/InterceptedChannel.h
netwerk/protocol/http/TunnelUtils.h
netwerk/protocol/http/nsAHttpTransaction.h
netwerk/protocol/http/nsHttpChannel.h
netwerk/protocol/rtsp/controller/RtspControllerParent.h
netwerk/sctp/datachannel/DataChannel.h
toolkit/components/jsdownloads/src/DownloadPlatform.h
toolkit/components/places/Database.h
toolkit/components/places/nsNavBookmarks.h
toolkit/components/places/nsNavHistory.h
toolkit/components/startup/nsAppStartup.h
toolkit/crashreporter/google-breakpad/src/tools/mac/crash_report/on_demand_symbol_supplier.h
toolkit/xre/nsAppRunner.h
uriloader/prefetch/OfflineCacheUpdateParent.h
uriloader/prefetch/nsOfflineCacheUpdate.h
uriloader/prefetch/nsPrefetchService.h
--- a/caps/DomainPolicy.h
+++ b/caps/DomainPolicy.h
@@ -8,20 +8,16 @@
 #define DomainPolicy_h__
 
 #include "nsIDomainPolicy.h"
 #include "nsTHashtable.h"
 #include "nsURIHashKey.h"
 
 namespace mozilla {
 
-namespace dom {
-class nsIContentParent;
-};
-
 namespace ipc {
 class URIParams;
 };
 
 enum DomainSetChangeType{
     ACTIVATE_POLICY,
     DEACTIVATE_POLICY,
     ADD_DOMAIN,
--- a/caps/nsJSPrincipals.h
+++ b/caps/nsJSPrincipals.h
@@ -4,18 +4,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 /* describes principals by their orginating uris*/
 
 #ifndef nsJSPrincipals_h__
 #define nsJSPrincipals_h__
 #include "jsapi.h"
 #include "nsIPrincipal.h"
 
-class nsCString;
-
 struct nsJSPrincipals : nsIPrincipal, JSPrincipals
 {
   static bool Subsume(JSPrincipals *jsprin, JSPrincipals *other);
   static void Destroy(JSPrincipals *jsprin);
 
   /*
    * Get a weak reference to nsIPrincipal associated with the given JS
    * principal.
--- a/caps/nsPrincipal.h
+++ b/caps/nsPrincipal.h
@@ -10,19 +10,16 @@
 #include "nsCOMPtr.h"
 #include "nsJSPrincipals.h"
 #include "nsTArray.h"
 #include "nsAutoPtr.h"
 #include "nsIProtocolHandler.h"
 #include "nsNetUtil.h"
 #include "nsScriptSecurityManager.h"
 
-class nsIObjectInputStream;
-class nsIObjectOutputStream;
-
 class nsBasePrincipal : public nsJSPrincipals
 {
 public:
   nsBasePrincipal();
 
 protected:
   virtual ~nsBasePrincipal();
 
--- a/caps/nsScriptSecurityManager.h
+++ b/caps/nsScriptSecurityManager.h
@@ -12,23 +12,20 @@
 #include "nsCOMPtr.h"
 #include "nsIChannelEventSink.h"
 #include "nsIObserver.h"
 #include "plstr.h"
 #include "js/TypeDecls.h"
 
 #include <stdint.h>
 
-class nsIDocShell;
 class nsCString;
-class nsIClassInfo;
 class nsIIOService;
 class nsIStringBundle;
 class nsSystemPrincipal;
-class ClassInfoData;
 
 /////////////////////////////
 // nsScriptSecurityManager //
 /////////////////////////////
 #define NS_SCRIPTSECURITYMANAGER_CID \
 { 0x7ee2a4c0, 0x4b93, 0x17d3, \
 { 0xba, 0x18, 0x00, 0x60, 0xb0, 0xf1, 0x99, 0xa2 }}
 
--- a/dom/battery/BatteryManager.h
+++ b/dom/battery/BatteryManager.h
@@ -7,17 +7,16 @@
 #define mozilla_dom_battery_BatteryManager_h
 
 #include "Types.h"
 #include "mozilla/DOMEventTargetHelper.h"
 #include "mozilla/Observer.h"
 #include "nsCycleCollectionParticipant.h"
 
 class nsPIDOMWindow;
-class nsIScriptContext;
 
 namespace mozilla {
 
 namespace hal {
 class BatteryInformation;
 } // namespace hal
 
 namespace dom {
--- a/dom/cache/OfflineStorage.h
+++ b/dom/cache/OfflineStorage.h
@@ -8,18 +8,16 @@
 #define mozilla_dom_cache_QuotaOfflineStorage_h
 
 #include "nsISupportsImpl.h"
 #include "mozilla/AlreadyAddRefed.h"
 #include "mozilla/dom/cache/Context.h"
 #include "nsIOfflineStorage.h"
 #include "nsTArray.h"
 
-class nsIThread;
-
 namespace mozilla {
 namespace dom {
 namespace cache {
 
 class OfflineStorage final : public nsIOfflineStorage
 {
 public:
   static already_AddRefed<OfflineStorage>
--- a/dom/cache/ReadStream.h
+++ b/dom/cache/ReadStream.h
@@ -10,18 +10,16 @@
 #include "mozilla/ipc/FileDescriptor.h"
 #include "nsCOMPtr.h"
 #include "nsID.h"
 #include "nsIInputStream.h"
 #include "nsISupportsImpl.h"
 #include "nsRefPtr.h"
 #include "nsTArrayForwardDeclare.h"
 
-class nsIThread;
-
 namespace mozilla {
 namespace dom {
 namespace cache {
 
 class CacheReadStream;
 class CacheReadStreamOrVoid;
 class PCacheStreamControlParent;
 
--- a/dom/camera/GonkCameraControl.h
+++ b/dom/camera/GonkCameraControl.h
@@ -44,19 +44,16 @@ namespace android {
 
 namespace mozilla {
 
 namespace layers {
   class TextureClient;
   class ImageContainer;
 }
 
-class GonkRecorderProfile;
-class GonkRecorderProfileManager;
-
 class nsGonkCameraControl : public CameraControlImpl
 {
 public:
   nsGonkCameraControl(uint32_t aCameraId);
 
   void OnAutoFocusMoving(bool aIsMoving);
   void OnAutoFocusComplete(bool aSuccess, bool aExpired);
   void OnFacesDetected(camera_frame_metadata_t* aMetaData);
--- a/dom/camera/ICameraControl.h
+++ b/dom/camera/ICameraControl.h
@@ -8,18 +8,16 @@
 #include "nsCOMPtr.h"
 #include "nsString.h"
 #include "nsAutoPtr.h"
 #include "nsISupportsImpl.h"
 #include "base/basictypes.h"
 
 struct DeviceStorageFileDescriptor;
 
-class nsIFile;
-
 namespace mozilla {
 
 class CameraControlListener;
 
 // XXXmikeh - In some future patch this should move into the ICameraControl
 //  class as well, and the names updated to the 'k'-style;
 //  e.g. kParamPreviewSize, etc.
 enum {
--- a/dom/canvas/CanvasRenderingContext2D.h
+++ b/dom/canvas/CanvasRenderingContext2D.h
@@ -37,17 +37,16 @@ class SourceSurface;
 }
 
 namespace dom {
 class HTMLImageElementOrHTMLCanvasElementOrHTMLVideoElement;
 class ImageData;
 class StringOrCanvasGradientOrCanvasPattern;
 class OwningStringOrCanvasGradientOrCanvasPattern;
 class TextMetrics;
-class SVGMatrix;
 class CanvasFilterChainObserver;
 class CanvasPath;
 
 extern const mozilla::gfx::Float SIGMA_MAX;
 
 template<typename T> class Optional;
 
 struct CanvasBidiProcessor;
--- a/dom/canvas/CanvasUtils.h
+++ b/dom/canvas/CanvasUtils.h
@@ -10,20 +10,16 @@
 #include "mozilla/dom/ToJSValue.h"
 #include "jsapi.h"
 #include "mozilla/FloatingPoint.h"
 
 class nsIPrincipal;
 
 namespace mozilla {
 
-namespace gfx {
-class Matrix;
-}
-
 namespace dom {
 class HTMLCanvasElement;
 }
 
 namespace CanvasUtils {
 
 
 // Check that the rectangle [x,y,w,h] is a subrectangle of [0,0,realWidth,realHeight]
--- a/dom/canvas/WebGLContext.h
+++ b/dom/canvas/WebGLContext.h
@@ -63,33 +63,31 @@ class nsIDocShell;
 #define MINVALUE_GL_MAX_TEXTURE_IMAGE_UNITS           8     // Page 164
 #define MINVALUE_GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS    0     // Page 164
 #define MINVALUE_GL_MAX_RENDERBUFFER_SIZE             1024  // Different from the spec, which sets it to 1 on page 164
 #define MINVALUE_GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS  8     // Page 164
 
 namespace mozilla {
 
 class WebGLActiveInfo;
-class WebGLContextBoundObject;
 class WebGLContextLossHandler;
 class WebGLBuffer;
 class WebGLExtensionBase;
 class WebGLFramebuffer;
 class WebGLObserver;
 class WebGLProgram;
 class WebGLQuery;
 class WebGLRenderbuffer;
 class WebGLSampler;
 class WebGLShader;
 class WebGLShaderPrecisionFormat;
 class WebGLTexture;
 class WebGLTransformFeedback;
 class WebGLUniformLocation;
 class WebGLVertexArray;
-struct WebGLVertexAttribData;
 
 namespace dom {
 class Element;
 class ImageData;
 struct WebGLContextAttributes;
 template<typename> struct Nullable;
 }
 
--- a/dom/canvas/WebGLFramebuffer.h
+++ b/dom/canvas/WebGLFramebuffer.h
@@ -9,17 +9,16 @@
 #include "mozilla/LinkedList.h"
 #include "nsWrapperCache.h"
 #include "WebGLBindableName.h"
 #include "WebGLObjectModel.h"
 #include "WebGLStrongTypes.h"
 
 namespace mozilla {
 
-class WebGLFramebufferAttachable;
 class WebGLRenderbuffer;
 class WebGLTexture;
 
 namespace gl {
     class GLContext;
 }
 
 class WebGLFramebuffer final
--- a/dom/canvas/WebGLObjectModel.h
+++ b/dom/canvas/WebGLObjectModel.h
@@ -7,17 +7,16 @@
 #define WEBGLOBJECTMODEL_H_
 
 #include "nsCycleCollectionNoteChild.h"
 #include "nsICanvasRenderingContextInternal.h"
 #include "WebGLTypes.h"
 
 namespace mozilla {
 
-class WebGLBuffer;
 class WebGLContext;
 
 /* Each WebGL object class WebGLFoo wants to:
  *  - inherit WebGLRefCountedObject<WebGLFoo>
  *  - implement a Delete() method
  *  - have its destructor call DeleteOnce()
  *
  * This base class provides two features to WebGL object types:
--- a/dom/canvas/WebGLShaderPrecisionFormat.h
+++ b/dom/canvas/WebGLShaderPrecisionFormat.h
@@ -5,18 +5,16 @@
 
 #ifndef WEBGL_SHADER_PRECISION_FORMAT_H_
 #define WEBGL_SHADER_PRECISION_FORMAT_H_
 
 #include "WebGLObjectModel.h"
 
 namespace mozilla {
 
-class WebGLBuffer;
-
 class WebGLShaderPrecisionFormat final
     : public WebGLContextBoundObject
 {
 public:
     WebGLShaderPrecisionFormat(WebGLContext* context, GLint rangeMin,
                                GLint rangeMax, GLint precision)
         : WebGLContextBoundObject(context)
         , mRangeMin(rangeMin)
--- a/dom/canvas/nsICanvasRenderingContextInternal.h
+++ b/dom/canvas/nsICanvasRenderingContextInternal.h
@@ -14,17 +14,16 @@
 #include "mozilla/dom/HTMLCanvasElement.h"
 #include "GraphicsFilter.h"
 #include "mozilla/RefPtr.h"
 
 #define NS_ICANVASRENDERINGCONTEXTINTERNAL_IID \
 { 0x3cc9e801, 0x1806, 0x4ff6, \
   { 0x86, 0x14, 0xf9, 0xd0, 0xf4, 0xfb, 0x3b, 0x08 } }
 
-class gfxContext;
 class gfxASurface;
 class nsDisplayListBuilder;
 
 namespace mozilla {
 namespace layers {
 class CanvasLayer;
 class LayerManager;
 }
--- a/dom/gamepad/GamepadService.h
+++ b/dom/gamepad/GamepadService.h
@@ -11,18 +11,16 @@
 #include "nsCOMArray.h"
 #include "nsIGamepadServiceTest.h"
 #include "nsGlobalWindow.h"
 #include "nsIFocusManager.h"
 #include "nsIObserver.h"
 #include "nsITimer.h"
 #include "nsTArray.h"
 
-class nsIDOMDocument;
-
 namespace mozilla {
 namespace dom {
 
 class EventTarget;
 
 class GamepadService : public nsIObserver
 {
  public:
--- a/dom/mobilemessage/MobileMessageCallback.h
+++ b/dom/mobilemessage/MobileMessageCallback.h
@@ -5,18 +5,16 @@
 
 #ifndef mozilla_dom_mobilemessage_MobileMessageCallback_h
 #define mozilla_dom_mobilemessage_MobileMessageCallback_h
 
 #include "nsIMobileMessageCallback.h"
 #include "nsCOMPtr.h"
 #include "DOMRequest.h"
 
-class nsIDOMMozMmsMessage;
-
 namespace mozilla {
 namespace dom {
 namespace mobilemessage {
 
 class MobileMessageCallback final : public nsIMobileMessageCallback
 {
 public:
   NS_DECL_ISUPPORTS
--- a/dom/mobilemessage/ipc/SmsIPCService.h
+++ b/dom/mobilemessage/ipc/SmsIPCService.h
@@ -11,18 +11,16 @@
 #include "nsIMobileMessageDatabaseService.h"
 #include "nsIObserver.h"
 #include "mozilla/Attributes.h"
 
 namespace mozilla {
 namespace dom {
 namespace mobilemessage {
 
-class PSmsChild;
-
 class SmsIPCService final : public nsISmsService
                           , public nsIMmsService
                           , public nsIMobileMessageDatabaseService
                           , public nsIObserver
 {
 public:
   NS_DECL_ISUPPORTS
   NS_DECL_NSISMSSERVICE
--- a/dom/network/TCPServerSocketParent.h
+++ b/dom/network/TCPServerSocketParent.h
@@ -8,18 +8,16 @@
 #include "nsITCPServerSocketParent.h"
 #include "nsCycleCollectionParticipant.h"
 #include "nsCOMPtr.h"
 #include "nsIDOMTCPSocket.h"
 
 namespace mozilla {
 namespace dom {
 
-class PBrowserParent;
-
 class TCPServerSocketParent : public mozilla::net::PTCPServerSocketParent
                             , public nsITCPServerSocketParent
 {
 public:
   NS_DECL_CYCLE_COLLECTION_CLASS(TCPServerSocketParent)
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
   NS_DECL_NSITCPSERVERSOCKETPARENT
 
--- a/dom/network/TCPSocketParent.h
+++ b/dom/network/TCPSocketParent.h
@@ -14,18 +14,16 @@
 #include "mozilla/net/OfflineObserver.h"
 
 #define TCPSOCKETPARENT_CID \
   { 0x4e7246c6, 0xa8b3, 0x426d, { 0x9c, 0x17, 0x76, 0xda, 0xb1, 0xe1, 0xe1, 0x4a } }
 
 namespace mozilla {
 namespace dom {
 
-class PBrowserParent;
-
 class TCPSocketParentBase : public nsITCPSocketParent
                           , public mozilla::net::DisconnectableParent
 {
 public:
   NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(TCPSocketParentBase)
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
 
   void AddIPDLReference();
--- a/dom/offline/nsDOMOfflineResourceList.h
+++ b/dom/offline/nsDOMOfflineResourceList.h
@@ -21,18 +21,16 @@
 #include "nsIDOMEventListener.h"
 #include "nsIObserver.h"
 #include "nsIScriptContext.h"
 #include "nsCycleCollectionParticipant.h"
 #include "nsPIDOMWindow.h"
 #include "mozilla/DOMEventTargetHelper.h"
 #include "mozilla/ErrorResult.h"
 
-class nsIDOMWindow;
-
 namespace mozilla {
 namespace dom {
 class DOMStringList;
 } // namespace dom
 } // namespace mozilla
 
 class nsDOMOfflineResourceList final : public mozilla::DOMEventTargetHelper,
                                        public nsIDOMOfflineResourceList,
--- a/dom/plugins/base/android/android_npapi.h
+++ b/dom/plugins/base/android/android_npapi.h
@@ -82,17 +82,16 @@ struct ANPRectI {
     int32_t right;
     int32_t bottom;
 };
 
 struct ANPCanvas;
 struct ANPMatrix;
 struct ANPPaint;
 struct ANPPath;
-struct ANPRegion;
 struct ANPTypeface;
 
 enum ANPMatrixFlags {
     kIdentity_ANPMatrixFlag     = 0,
     kTranslate_ANPMatrixFlag    = 0x01,
     kScale_ANPMatrixFlag        = 0x02,
     kAffine_ANPMatrixFlag       = 0x04,
     kPerspective_ANPMatrixFlag  = 0x08,
--- a/dom/plugins/base/nsPluginHost.h
+++ b/dom/plugins/base/nsPluginHost.h
@@ -36,17 +36,16 @@
 namespace mozilla {
 namespace plugins {
 class PluginAsyncSurrogate;
 class PluginTag;
 } // namespace mozilla
 } // namespace plugins
 
 class nsNPAPIPlugin;
-class nsIComponentManager;
 class nsIFile;
 class nsIChannel;
 class nsPluginNativeWindow;
 class nsObjectLoadingContent;
 class nsPluginInstanceOwner;
 class nsPluginUnloadRunnable;
 class nsNPAPIPluginInstance;
 class nsNPAPIPluginStreamListener;
--- a/dom/plugins/base/nsPluginInstanceOwner.h
+++ b/dom/plugins/base/nsPluginInstanceOwner.h
@@ -35,17 +35,16 @@ struct MozPluginParameter;
 namespace widget {
 class PuppetWidget;
 }
 }
 
 using mozilla::widget::PuppetWidget;
 
 #ifdef MOZ_X11
-class gfxXlibSurface;
 #ifdef MOZ_WIDGET_QT
 #include "gfxQtNativeRenderer.h"
 #else
 #include "gfxXlibNativeRenderer.h"
 #endif
 #endif
 
 class nsPluginInstanceOwner final : public nsIPluginInstanceOwner,
--- a/dom/plugins/base/nsPluginTags.h
+++ b/dom/plugins/base/nsPluginTags.h
@@ -10,17 +10,16 @@
 #include "nscore.h"
 #include "nsAutoPtr.h"
 #include "nsCOMPtr.h"
 #include "nsCOMArray.h"
 #include "nsIPluginTag.h"
 #include "nsITimer.h"
 #include "nsString.h"
 
-class nsPluginHost;
 struct PRLibrary;
 struct nsPluginInfo;
 class nsNPAPIPlugin;
 
 // A linked-list of plugin information that is used for instantiating plugins
 // and reflecting plugin information into JavaScript.
 class nsPluginTag final : public nsIPluginTag
 {
--- a/dom/plugins/ipc/PluginInstanceChild.h
+++ b/dom/plugins/ipc/PluginInstanceChild.h
@@ -35,21 +35,16 @@
 
 #ifdef MOZ_WIDGET_GTK
 #include "gtk2xtbin.h"
 #endif
 
 class gfxASurface;
 
 namespace mozilla {
-
-namespace layers {
-struct RemoteImageData;
-}
-
 namespace plugins {
 
 class PBrowserStreamChild;
 class BrowserStreamChild;
 class StreamNotifyChild;
 
 class PluginInstanceChild : public PPluginInstanceChild
 {
--- a/dom/plugins/ipc/PluginInstanceParent.h
+++ b/dom/plugins/ipc/PluginInstanceParent.h
@@ -19,19 +19,16 @@
 
 #include "npfunctions.h"
 #include "nsAutoPtr.h"
 #include "nsDataHashtable.h"
 #include "nsHashKeys.h"
 #include "nsRect.h"
 #include "PluginDataResolver.h"
 
-#ifdef MOZ_X11
-class gfxXlibSurface;
-#endif
 #include "mozilla/unused.h"
 
 class gfxASurface;
 class gfxContext;
 class nsPluginInstanceOwner;
 
 namespace mozilla {
 namespace layers {
--- a/dom/plugins/ipc/PluginModuleChild.h
+++ b/dom/plugins/ipc/PluginModuleChild.h
@@ -52,17 +52,16 @@ class PCrashReporterChild;
 
 namespace plugins {
 
 #ifdef MOZ_WIDGET_QT
 class NestedLoopTimer;
 static const int kNestedLoopDetectorIntervalMs = 90;
 #endif
 
-class PluginScriptableObjectChild;
 class PluginInstanceChild;
 
 class PluginModuleChild : public PPluginModuleChild
 {
     typedef mozilla::dom::PCrashReporterChild PCrashReporterChild;
 protected:
     virtual mozilla::ipc::RacyInterruptPolicy
     MediateInterruptRace(const Message& parent, const Message& child) override
--- a/dom/plugins/ipc/PluginScriptableObjectParent.h
+++ b/dom/plugins/ipc/PluginScriptableObjectParent.h
@@ -11,17 +11,16 @@
 #include "mozilla/plugins/PluginMessageUtils.h"
 
 #include "npfunctions.h"
 #include "npruntime.h"
 
 namespace mozilla {
 namespace plugins {
 
-class PluginAsyncSurrogate;
 class PluginInstanceParent;
 class PluginScriptableObjectParent;
 
 struct ParentNPObject : NPObject
 {
   ParentNPObject()
     : NPObject(), parent(nullptr), invalidated(false) { }
 
--- a/dom/quota/Client.h
+++ b/dom/quota/Client.h
@@ -15,17 +15,16 @@ class nsIOfflineStorage;
 class nsIRunnable;
 
 #define IDB_DIRECTORY_NAME "idb"
 #define ASMJSCACHE_DIRECTORY_NAME "asmjs"
 #define DOMCACHE_DIRECTORY_NAME "cache"
 
 BEGIN_QUOTA_NAMESPACE
 
-class OriginOrPatternString;
 class UsageInfo;
 
 // An abstract interface for quota manager clients.
 // Each storage API must provide an implementation of this interface in order
 // to participate in centralized quota and storage handling.
 class Client
 {
 public:
--- a/dom/quota/QuotaManager.h
+++ b/dom/quota/QuotaManager.h
@@ -35,17 +35,16 @@ class nsIRunnable;
 namespace mozilla {
 namespace dom {
 class ContentParent;
 }
 }
 
 BEGIN_QUOTA_NAMESPACE
 
-class AcquireListener;
 class AsyncUsageRunnable;
 class CollectOriginsHelper;
 class FinalizeOriginEvictionRunnable;
 class GroupInfo;
 class GroupInfoPair;
 class OriginClearRunnable;
 class OriginInfo;
 class OriginOrPatternString;
--- a/dom/quota/nsIOfflineStorage.h
+++ b/dom/quota/nsIOfflineStorage.h
@@ -7,18 +7,16 @@
 #ifndef nsIOfflineStorage_h__
 #define nsIOfflineStorage_h__
 
 #include "mozilla/dom/quota/PersistenceType.h"
 
 #define NS_OFFLINESTORAGE_IID \
   {0x91c57bf2, 0x0eda, 0x4db6, {0x9f, 0xf6, 0xcb, 0x38, 0x26, 0x8d, 0xb3, 0x01}}
 
-class nsPIDOMWindow;
-
 namespace mozilla {
 namespace dom {
 
 class ContentParent;
 
 namespace quota {
 
 class Client;
--- a/dom/security/nsCORSListenerProxy.h
+++ b/dom/security/nsCORSListenerProxy.h
@@ -13,17 +13,16 @@
 #include "nsIURI.h"
 #include "nsTArray.h"
 #include "nsIInterfaceRequestor.h"
 #include "nsIChannelEventSink.h"
 #include "nsIAsyncVerifyRedirectCallback.h"
 #include "mozilla/Attributes.h"
 
 class nsIURI;
-class nsIParser;
 class nsIPrincipal;
 class nsINetworkInterceptController;
 
 nsresult
 NS_StartCORSPreflight(nsIChannel* aRequestChannel,
                       nsIStreamListener* aListener,
                       nsIPrincipal* aPrincipal,
                       bool aWithCredentials,
--- a/dom/vr/VRDevice.h
+++ b/dom/vr/VRDevice.h
@@ -19,18 +19,16 @@
 #include "nsTArray.h"
 #include "nsWrapperCache.h"
 
 #include "gfxVR.h"
 
 namespace mozilla {
 namespace dom {
 
-class Element;
-
 class VRFieldOfViewReadOnly : public nsWrapperCache
 {
 public:
   VRFieldOfViewReadOnly(nsISupports* aParent,
                         double aUpDegrees, double aRightDegrees,
                         double aDownDegrees, double aLeftDegrees)
     : mParent(aParent)
     , mUpDegrees(aUpDegrees)
--- a/dom/xml/XMLDocument.h
+++ b/dom/xml/XMLDocument.h
@@ -6,18 +6,16 @@
 #ifndef mozilla_dom_XMLDocument_h
 #define mozilla_dom_XMLDocument_h
 
 #include "mozilla/Attributes.h"
 #include "nsDocument.h"
 #include "nsIDOMXMLDocument.h"
 #include "nsIScriptContext.h"
 
-class nsIParser;
-class nsIDOMNode;
 class nsIURI;
 class nsIChannel;
 
 namespace mozilla {
 namespace dom {
 
 class XMLDocument : public nsDocument
 {
--- a/dom/xml/nsXMLContentSink.h
+++ b/dom/xml/nsXMLContentSink.h
@@ -17,17 +17,16 @@
 #include "nsCycleCollectionParticipant.h"
 #include "nsIDTD.h"
 #include "mozilla/dom/FromParser.h"
 
 class nsIDocument;
 class nsIURI;
 class nsIContent;
 class nsIParser;
-class nsViewManager;
 
 namespace mozilla {
 namespace dom {
 class NodeInfo;
 }
 }
 
 typedef enum {
--- a/image/encoders/ico/nsICOEncoder.h
+++ b/image/encoders/ico/nsICOEncoder.h
@@ -9,19 +9,16 @@
 #include "mozilla/ReentrantMonitor.h"
 
 #include "imgIEncoder.h"
 
 #include "nsAutoPtr.h"
 #include "nsCOMPtr.h"
 #include "ICOFileHeaders.h"
 
-class nsBMPEncoder;
-class nsPNGEncoder;
-
 #define NS_ICOENCODER_CID \
 { /*92AE3AB2-8968-41B1-8709-B6123BCEAF21 */          \
      0x92ae3ab2,                                     \
      0x8968,                                         \
      0x41b1,                                         \
     {0x87, 0x09, 0xb6, 0x12, 0x3b, 0Xce, 0xaf, 0x21} \
 }
 
--- a/image/src/DecodePool.h
+++ b/image/src/DecodePool.h
@@ -18,17 +18,16 @@
 
 class nsIThread;
 class nsIThreadPool;
 
 namespace mozilla {
 namespace image {
 
 class Decoder;
-class RasterImage;
 
 /**
  * DecodePool is a singleton class that manages decoding of raster images. It
  * owns a pool of image decoding threads that are used for asynchronous
  * decoding.
  *
  * DecodePool allows callers to run a decoder, handling management of the
  * decoder's lifecycle and whether it executes on the main thread,
--- a/image/src/ProgressTracker.h
+++ b/image/src/ProgressTracker.h
@@ -10,17 +10,16 @@
 #include "mozilla/RefPtr.h"
 #include "mozilla/WeakPtr.h"
 #include "nsCOMPtr.h"
 #include "nsTObserverArray.h"
 #include "nsThreadUtils.h"
 #include "nsRect.h"
 #include "IProgressObserver.h"
 
-class imgIContainer;
 class nsIRunnable;
 
 namespace mozilla {
 namespace image {
 
 class AsyncNotifyRunnable;
 class AsyncNotifyCurrentStateRunnable;
 class Image;
--- a/image/src/RasterImage.h
+++ b/image/src/RasterImage.h
@@ -34,17 +34,16 @@
 #include "mozilla/TimeStamp.h"
 #include "mozilla/WeakPtr.h"
 #include "mozilla/UniquePtr.h"
 #ifdef DEBUG
   #include "imgIContainerDebug.h"
 #endif
 
 class nsIInputStream;
-class nsIThreadPool;
 class nsIRequest;
 
 #define NS_RASTERIMAGE_CID \
 { /* 376ff2c1-9bf6-418a-b143-3340c00112f7 */         \
      0x376ff2c1,                                     \
      0x9bf6,                                         \
      0x418a,                                         \
     {0xb1, 0x43, 0x33, 0x40, 0xc0, 0x01, 0x12, 0xf7} \
@@ -118,17 +117,16 @@ class nsIRequest;
  * @par
  * The mAnim structure has members only needed for animated images, so
  * it's not allocated until the second frame is added.
  */
 
 namespace mozilla {
 
 namespace layers {
-class LayerManager;
 class ImageContainer;
 class Image;
 }
 
 namespace image {
 
 class Decoder;
 class FrameAnimator;
--- a/image/src/SVGDocumentWrapper.h
+++ b/image/src/SVGDocumentWrapper.h
@@ -12,17 +12,16 @@
 
 #include "nsCOMPtr.h"
 #include "nsIStreamListener.h"
 #include "nsIObserver.h"
 #include "nsIContentViewer.h"
 #include "nsWeakReference.h"
 #include "nsSize.h"
 
-class nsIAtom;
 class nsIPresShell;
 class nsIRequest;
 class nsILoadGroup;
 class nsIFrame;
 
 #define OBSERVER_SVC_CID "@mozilla.org/observer-service;1"
 
 // undef the GetCurrentTime macro defined in WinBase.h from the MS Platform SDK
--- a/image/src/VectorImage.h
+++ b/image/src/VectorImage.h
@@ -9,20 +9,16 @@
 #include "Image.h"
 #include "nsIStreamListener.h"
 #include "mozilla/MemoryReporting.h"
 
 class nsIRequest;
 class gfxDrawable;
 
 namespace mozilla {
-namespace layers {
-class LayerManager;
-class ImageContainer;
-}
 namespace image {
 
 struct SVGDrawingParameters;
 class  SVGDocumentWrapper;
 class  SVGRootRenderingObserver;
 class  SVGLoadEventListener;
 class  SVGParseCompleteListener;
 
--- a/ipc/dbus/RawDBusConnection.h
+++ b/ipc/dbus/RawDBusConnection.h
@@ -5,17 +5,16 @@
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef mozilla_ipc_dbus_gonk_rawdbusconnection_h__
 #define mozilla_ipc_dbus_gonk_rawdbusconnection_h__
 
 #include "mozilla/Scoped.h"
 
 struct DBusConnection;
-struct DBusError;
 struct DBusMessage;
 
 namespace mozilla {
 namespace ipc {
 
 typedef void (*DBusReplyCallback)(DBusMessage*, void*);
 
 class RawDBusConnection
--- a/ipc/glue/GeckoChildProcessHost.h
+++ b/ipc/glue/GeckoChildProcessHost.h
@@ -18,18 +18,16 @@
 #include "nsCOMPtr.h"
 #include "nsXULAppAPI.h"        // for GeckoProcessType
 #include "nsString.h"
 
 #if defined(XP_WIN) && defined(MOZ_SANDBOX)
 #include "sandboxBroker.h"
 #endif
 
-class nsIFile;
-
 namespace mozilla {
 namespace ipc {
 
 class GeckoChildProcessHost : public ChildProcessHost
 {
 protected:
   typedef mozilla::Monitor Monitor;
   typedef std::vector<std::string> StringVector;
--- a/ipc/glue/nsIIPCSerializableInputStream.h
+++ b/ipc/glue/nsIIPCSerializableInputStream.h
@@ -3,17 +3,16 @@
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef mozilla_ipc_nsIIPCSerializableInputStream_h
 #define mozilla_ipc_nsIIPCSerializableInputStream_h
 
 #include "nsISupports.h"
 #include "mozilla/Attributes.h"
 
-struct nsTArrayDefaultAllocator;
 template <class> class nsTArray;
 
 namespace mozilla {
 namespace ipc {
 
 class FileDescriptor;
 class InputStreamParams;
 
--- a/modules/libjar/nsJAR.h
+++ b/modules/libjar/nsJAR.h
@@ -25,17 +25,16 @@
 #include "nsIZipReader.h"
 #include "nsZipArchive.h"
 #include "nsIObserverService.h"
 #include "nsWeakReference.h"
 #include "nsIObserver.h"
 #include "mozilla/Attributes.h"
 
 class nsIX509Cert;
-class nsIInputStream;
 class nsJARManifestItem;
 class nsZipReaderCache;
 
 /* For mManifestStatus */
 typedef enum
 {
   JAR_MANIFEST_NOT_PARSED = 0,
   JAR_VALID_MANIFEST      = 1,
--- a/modules/libpref/Preferences.h
+++ b/modules/libpref/Preferences.h
@@ -15,18 +15,16 @@
 #include "nsIPrefBranchInternal.h"
 #include "nsIObserver.h"
 #include "nsCOMPtr.h"
 #include "nsTArray.h"
 #include "nsWeakReference.h"
 #include "mozilla/MemoryReporting.h"
 
 class nsIFile;
-class nsCString;
-class nsString;
 class nsAdoptingString;
 class nsAdoptingCString;
 
 #ifndef have_PrefChangedFunc_typedef
 typedef void (*PrefChangedFunc)(const char *, void *);
 #define have_PrefChangedFunc_typedef
 #endif
 
--- a/netwerk/base/ChannelDiverterChild.h
+++ b/netwerk/base/ChannelDiverterChild.h
@@ -4,23 +4,19 @@
  * 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/. */
 
 #ifndef _channeldiverterchild_h_
 #define _channeldiverterchild_h_
 
 #include "mozilla/net/PChannelDiverterChild.h"
 
-class nsIDivertableChannel;
-
 namespace mozilla {
 namespace net {
 
-class ChannelDiverterArgs;
-
 class ChannelDiverterChild :
   public PChannelDiverterChild
 {
 public:
   ChannelDiverterChild();
   virtual ~ChannelDiverterChild();
 };
 
--- a/netwerk/base/Dashboard.h
+++ b/netwerk/base/Dashboard.h
@@ -10,18 +10,16 @@
 #include "nsIDashboard.h"
 #include "nsIDashboardEventNotifier.h"
 #include "nsIDNSListener.h"
 #include "nsIServiceManager.h"
 #include "nsITimer.h"
 #include "nsITransport.h"
 
 class nsIDNSService;
-class nsISocketTransport;
-class nsIThread;
 
 namespace mozilla {
 namespace net {
 
 class SocketData;
 class HttpData;
 class DnsData;
 class WebSocketRequest;
--- a/netwerk/base/Predictor.h
+++ b/netwerk/base/Predictor.h
@@ -21,17 +21,16 @@
 #include "nsTArray.h"
 
 #include "mozilla/TimeStamp.h"
 
 class nsICacheStorage;
 class nsIDNSService;
 class nsIIOService;
 class nsINetworkPredictorVerifier;
-class nsIThread;
 class nsITimer;
 
 namespace mozilla {
 namespace net {
 
 class Predictor : public nsINetworkPredictor
                 , public nsIObserver
                 , public nsISpeculativeConnectionOverrider
--- a/netwerk/base/nsNativeConnectionHelper.h
+++ b/netwerk/base/nsNativeConnectionHelper.h
@@ -2,18 +2,16 @@
  * 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/. */
 
 #ifndef nsNativeConnectionHelper_h__
 #define nsNativeConnectionHelper_h__
 
 #include "nscore.h"
 
-class nsISocketTransport;
-
 class nsNativeConnectionHelper
 {
 public:
     /**
      * OnConnectionFailed
      *
      * Return true if the connection should be re-attempted.
      */
--- a/netwerk/cache/nsDiskCacheStreams.h
+++ b/netwerk/cache/nsDiskCacheStreams.h
@@ -13,17 +13,16 @@
 
 #include "nsCache.h"
 
 #include "nsIInputStream.h"
 #include "nsIOutputStream.h"
 
 #include "mozilla/Atomics.h"
 
-class nsDiskCacheInputStream;
 class nsDiskCacheDevice;
 
 class nsDiskCacheStreamIO : public nsIOutputStream {
 public:
     explicit nsDiskCacheStreamIO(nsDiskCacheBinding *   binding);
     
     NS_DECL_THREADSAFE_ISUPPORTS
     NS_DECL_NSIOUTPUTSTREAM
--- a/netwerk/cache2/CacheEntry.h
+++ b/netwerk/cache2/CacheEntry.h
@@ -28,27 +28,25 @@ static inline uint32_t
 PRTimeToSeconds(PRTime t_usec)
 {
   PRTime usec_per_sec = PR_USEC_PER_SEC;
   return uint32_t(t_usec /= usec_per_sec);
 }
 
 #define NowInSeconds() PRTimeToSeconds(PR_Now())
 
-class nsIStorageStream;
 class nsIOutputStream;
 class nsIURI;
 class nsIThread;
 
 namespace mozilla {
 namespace net {
 
 class CacheStorageService;
 class CacheStorage;
-class CacheFileOutputStream;
 class CacheOutputCloseListener;
 class CacheEntryHandle;
 
 class CacheEntry final : public nsICacheEntry
                        , public nsIRunnable
                        , public CacheFileListener
 {
 public:
--- a/netwerk/cache2/CacheFileIOManager.h
+++ b/netwerk/cache2/CacheFileIOManager.h
@@ -18,17 +18,16 @@
 #include "prio.h"
 
 //#define DEBUG_HANDLES 1
 
 class nsIFile;
 class nsITimer;
 class nsIDirectoryEnumerator;
 class nsILoadContextInfo;
-class nsICacheStorageVisitor;
 
 namespace mozilla {
 namespace net {
 
 class CacheFile;
 #ifdef DEBUG_HANDLES
 class CacheFileHandlesEntry;
 #endif
@@ -169,17 +168,16 @@ public:
 
 private:
   nsTHashtable<HandleHashKey> mTable;
 };
 
 ////////////////////////////////////////////////////////////////////////////////
 
 class OpenFileEvent;
-class CloseFileEvent;
 class ReadEvent;
 class WriteEvent;
 class MetadataWriteScheduleEvent;
 class CacheFileContextEvictor;
 
 #define CACHEFILEIOLISTENER_IID \
 { /* dcaf2ddc-17cf-4242-bca1-8c86936375a5 */       \
   0xdcaf2ddc,                                      \
--- a/netwerk/cache2/CacheStorageService.h
+++ b/netwerk/cache2/CacheStorageService.h
@@ -15,31 +15,29 @@
 #include "nsThreadUtils.h"
 #include "nsProxyRelease.h"
 #include "mozilla/Mutex.h"
 #include "mozilla/Atomics.h"
 #include "mozilla/TimeStamp.h"
 #include "nsTArray.h"
 
 class nsIURI;
-class nsICacheEntryOpenCallback;
 class nsICacheEntryDoomCallback;
 class nsICacheStorageVisitor;
 class nsIRunnable;
 class nsIThread;
 class nsIEventTarget;
 
 namespace mozilla {
 namespace net {
 
 class CacheStorageService;
 class CacheStorage;
 class CacheEntry;
 class CacheEntryHandle;
-class CacheEntryTable;
 
 class CacheMemoryConsumer
 {
 private:
   friend class CacheStorageService;
   uint32_t mReportedMemoryConsumption : 30;
   uint32_t mFlags : 2;
 
--- a/netwerk/cookie/CookieServiceParent.h
+++ b/netwerk/cookie/CookieServiceParent.h
@@ -5,17 +5,16 @@
 
 #ifndef mozilla_net_CookieServiceParent_h
 #define mozilla_net_CookieServiceParent_h
 
 #include "mozilla/net/PCookieServiceParent.h"
 #include "SerializedLoadContext.h"
 
 class nsCookieService;
-class nsIIOService;
 
 namespace mozilla {
 namespace net {
 
 class CookieServiceParent : public PCookieServiceParent
 {
 public:
   CookieServiceParent();
--- a/netwerk/cookie/nsCookieService.h
+++ b/netwerk/cookie/nsCookieService.h
@@ -37,17 +37,16 @@ class nsIURI;
 class nsIChannel;
 class nsIArray;
 class mozIStorageService;
 class mozIThirdPartyUtil;
 class ReadCookieDBListener;
 
 struct nsCookieAttributes;
 struct nsListIter;
-struct nsEnumerationData;
 
 namespace mozilla {
 namespace net {
 class CookieServiceParent;
 }
 }
 
 // hash key class
--- a/netwerk/ipc/ChannelEventQueue.h
+++ b/netwerk/ipc/ChannelEventQueue.h
@@ -8,17 +8,16 @@
 #ifndef mozilla_net_ChannelEventQueue_h
 #define mozilla_net_ChannelEventQueue_h
 
 #include <nsTArray.h>
 #include <nsAutoPtr.h>
 
 class nsISupports;
 class nsIEventTarget;
-class nsIThread;
 
 namespace mozilla {
 namespace net {
 
 class ChannelEvent
 {
  public:
   ChannelEvent() { MOZ_COUNT_CTOR(ChannelEvent); }
@@ -28,18 +27,16 @@ class ChannelEvent
 
 // Workaround for Necko re-entrancy dangers. We buffer IPDL messages in a
 // queue if still dispatching previous one(s) to listeners/observers.
 // Otherwise synchronous XMLHttpRequests and/or other code that spins the
 // event loop (ex: IPDL rpc) could cause listener->OnDataAvailable (for
 // instance) to be dispatched and called before mListener->OnStartRequest has
 // completed.
 
-class AutoEventEnqueuerBase;
-
 class ChannelEventQueue final
 {
   NS_INLINE_DECL_THREADSAFE_REFCOUNTING(ChannelEventQueue)
 
  public:
   explicit ChannelEventQueue(nsISupports *owner)
     : mSuspendCount(0)
     , mSuspended(false)
--- a/netwerk/protocol/ftp/FTPChannelParent.h
+++ b/netwerk/protocol/ftp/FTPChannelParent.h
@@ -10,17 +10,16 @@
 
 #include "ADivertableParentChannel.h"
 #include "mozilla/net/PFTPChannelParent.h"
 #include "mozilla/net/NeckoParent.h"
 #include "nsIParentChannel.h"
 #include "nsIInterfaceRequestor.h"
 #include "OfflineObserver.h"
 
-class nsFtpChannel;
 class nsILoadContext;
 
 namespace mozilla {
 namespace net {
 
 class FTPChannelParent final : public PFTPChannelParent
                              , public nsIParentChannel
                              , public nsIInterfaceRequestor
--- a/netwerk/protocol/http/ASpdySession.h
+++ b/netwerk/protocol/http/ASpdySession.h
@@ -10,18 +10,16 @@
 #include "nsAHttpTransaction.h"
 #include "prinrval.h"
 #include "nsString.h"
 
 class nsISocketTransport;
 
 namespace mozilla { namespace net {
 
-class nsHttpConnectionInfo;
-
 class ASpdySession : public nsAHttpTransaction
 {
 public:
   ASpdySession();
   virtual ~ASpdySession();
 
   virtual bool AddStream(nsAHttpTransaction *, int32_t,
                          bool, nsIInterfaceRequestor *) = 0;
--- a/netwerk/protocol/http/HttpChannelParentListener.h
+++ b/netwerk/protocol/http/HttpChannelParentListener.h
@@ -7,18 +7,16 @@
 
 #ifndef mozilla_net_HttpChannelCallbackWrapper_h
 #define mozilla_net_HttpChannelCallbackWrapper_h
 
 #include "nsIInterfaceRequestor.h"
 #include "nsIChannelEventSink.h"
 #include "nsIRedirectResultListener.h"
 
-class nsIParentChannel;
-
 namespace mozilla {
 namespace net {
 
 class HttpChannelParent;
 
 class HttpChannelParentListener final : public nsIInterfaceRequestor
                                       , public nsIChannelEventSink
                                       , public nsIRedirectResultListener
--- a/netwerk/protocol/http/InterceptedChannel.h
+++ b/netwerk/protocol/http/InterceptedChannel.h
@@ -8,17 +8,16 @@
 #define InterceptedChannel_h
 
 #include "nsINetworkInterceptController.h"
 #include "nsRefPtr.h"
 #include "mozilla/Maybe.h"
 
 class nsICacheEntry;
 class nsInputStreamPump;
-class nsIStorageStream;
 class nsIStreamListener;
 
 namespace mozilla {
 namespace net {
 
 class nsHttpChannel;
 class HttpChannelChild;
 class nsHttpResponseHead;
--- a/netwerk/protocol/http/TunnelUtils.h
+++ b/netwerk/protocol/http/TunnelUtils.h
@@ -169,17 +169,16 @@ private:
   bool mReadSegmentBlocked;
   uint32_t mNudgeCounter;
 };
 
 class SocketTransportShim;
 class InputStreamShim;
 class OutputStreamShim;
 class nsHttpConnection;
-class ASpdySession;
 
 class SpdyConnectTransaction final : public NullHttpTransaction
 {
 public:
   SpdyConnectTransaction(nsHttpConnectionInfo *ci,
                          nsIInterfaceRequestor *callbacks,
                          uint32_t caps,
                          nsHttpTransaction *trans,
--- a/netwerk/protocol/http/nsAHttpTransaction.h
+++ b/netwerk/protocol/http/nsAHttpTransaction.h
@@ -5,17 +5,16 @@
 #ifndef nsAHttpTransaction_h__
 #define nsAHttpTransaction_h__
 
 #include "nsISupports.h"
 #include "nsTArray.h"
 #include "nsWeakReference.h"
 
 class nsIInterfaceRequestor;
-class nsIEventTarget;
 class nsITransport;
 class nsILoadGroupConnectionInfo;
 
 namespace mozilla { namespace net {
 
 class nsAHttpConnection;
 class nsAHttpSegmentReader;
 class nsAHttpSegmentWriter;
--- a/netwerk/protocol/http/nsHttpChannel.h
+++ b/netwerk/protocol/http/nsHttpChannel.h
@@ -18,17 +18,16 @@
 #include "nsIHttpAuthenticableChannel.h"
 #include "nsIAsyncVerifyRedirectCallback.h"
 #include "nsIThreadRetargetableRequest.h"
 #include "nsIThreadRetargetableStreamListener.h"
 #include "nsWeakReference.h"
 #include "TimingStruct.h"
 #include "AutoClose.h"
 
-class nsIPrincipal;
 class nsDNSPrefetch;
 class nsICancelable;
 class nsIHttpChannelAuthProvider;
 class nsInputStreamPump;
 class nsISSLStatus;
 
 namespace mozilla { namespace net {
 
--- a/netwerk/protocol/rtsp/controller/RtspControllerParent.h
+++ b/netwerk/protocol/rtsp/controller/RtspControllerParent.h
@@ -10,18 +10,16 @@
 #include "mozilla/net/PRtspControllerParent.h"
 #include "mozilla/net/NeckoParent.h"
 #include "nsIStreamingProtocolController.h"
 #include "nsILoadContext.h"
 #include "nsIURI.h"
 #include "nsCOMPtr.h"
 #include "nsString.h"
 
-class nsIAuthPromptProvider;
-
 namespace mozilla {
 namespace net {
 
 class RtspControllerParent : public PRtspControllerParent
                            , public nsIStreamingProtocolListener
 {
  public:
   NS_DECL_THREADSAFE_ISUPPORTS
--- a/netwerk/sctp/datachannel/DataChannel.h
+++ b/netwerk/sctp/datachannel/DataChannel.h
@@ -43,17 +43,16 @@
 
 extern "C" {
   struct socket;
   struct sctp_rcvinfo;
 }
 
 namespace mozilla {
 
-class DTLSConnection;
 class DataChannelConnection;
 class DataChannel;
 class DataChannelOnMessageAvailable;
 
 // For queuing outgoing messages
 class BufferedMsg
 {
 public:
--- a/toolkit/components/jsdownloads/src/DownloadPlatform.h
+++ b/toolkit/components/jsdownloads/src/DownloadPlatform.h
@@ -4,19 +4,16 @@
 
 #ifndef __DownloadPlatform_h__
 #define __DownloadPlatform_h__
 
 #include "mozIDownloadPlatform.h"
 
 #include "nsCOMPtr.h"
 
-class nsIURI;
-class nsIFile;
-
 class DownloadPlatform : public mozIDownloadPlatform
 {
 protected:
 
   virtual ~DownloadPlatform() { }
 
 public:
 
--- a/toolkit/components/places/Database.h
+++ b/toolkit/components/places/Database.h
@@ -38,17 +38,16 @@
 #define TOPIC_PLACES_SHUTDOWN "places-shutdown"
 // For Internal use only.  Fired when connection is about to be closed, only
 // cleanup tasks should run at this stage, nothing should be added to the
 // database, nor APIs should be called.
 #define TOPIC_PLACES_WILL_CLOSE_CONNECTION "places-will-close-connection"
 // Fired when the connection has gone, nothing will work from now on.
 #define TOPIC_PLACES_CONNECTION_CLOSED "places-connection-closed"
 
-class nsIStringBundle;
 class nsIRunnable;
 
 namespace mozilla {
 namespace places {
 
 enum JournalMode {
   // Default SQLite journal mode.
   JOURNAL_DELETE = 0
--- a/toolkit/components/places/nsNavBookmarks.h
+++ b/toolkit/components/places/nsNavBookmarks.h
@@ -13,17 +13,16 @@
 #include "nsToolkitCompsCID.h"
 #include "nsCategoryCache.h"
 #include "nsTHashtable.h"
 #include "nsWeakReference.h"
 #include "mozilla/Attributes.h"
 #include "prtime.h"
 
 class nsNavBookmarks;
-class nsIOutputStream;
 
 namespace mozilla {
 namespace places {
 
   enum BookmarkStatementId {
     DB_FIND_REDIRECTED_BOOKMARK = 0
   , DB_GET_BOOKMARKS_FOR_URI
   };
--- a/toolkit/components/places/nsNavHistory.h
+++ b/toolkit/components/places/nsNavHistory.h
@@ -46,17 +46,16 @@
 #ifdef MOZ_XUL
 // Fired after autocomplete feedback has been updated.
 #define TOPIC_AUTOCOMPLETE_FEEDBACK_UPDATED "places-autocomplete-feedback-updated"
 #endif
 
 // Fired after frecency has been updated.
 #define TOPIC_FRECENCY_UPDATED "places-frecency-updated"
 
-class mozIAnnotationService;
 class nsNavHistory;
 class QueryKeyValuePair;
 class nsIEffectiveTLDService;
 class nsIIDNService;
 class PlacesSQLQueryBuilder;
 class nsIAutoCompleteController;
 
 // nsNavHistory
--- a/toolkit/components/startup/nsAppStartup.h
+++ b/toolkit/components/startup/nsAppStartup.h
@@ -17,18 +17,16 @@
 
 #if defined(XP_WIN)
 //XPerf-backed probes
 #include "mozilla/perfprobe.h"
 #include "nsAutoPtr.h"
 #endif //defined(XP_WIN)
 
 
-struct PLEvent;
-
 // {7DD4D320-C84B-4624-8D45-7BB9B2356977}
 #define NS_TOOLKIT_APPSTARTUP_CID \
 { 0x7dd4d320, 0xc84b, 0x4624, { 0x8d, 0x45, 0x7b, 0xb9, 0xb2, 0x35, 0x69, 0x77 } }
 
 
 class nsAppStartup final : public nsIAppStartup,
                            public nsIWindowCreator2,
                            public nsIObserver,
--- a/toolkit/crashreporter/google-breakpad/src/tools/mac/crash_report/on_demand_symbol_supplier.h
+++ b/toolkit/crashreporter/google-breakpad/src/tools/mac/crash_report/on_demand_symbol_supplier.h
@@ -36,17 +36,16 @@
 #include <map>
 #include <string>
 #include "google_breakpad/processor/symbol_supplier.h"
 
 namespace google_breakpad {
 
 using std::map;
 using std::string;
-class MinidumpModule;
 
 class OnDemandSymbolSupplier : public SymbolSupplier {
  public:
   // |search_dir| is the directory to search for alternative symbols with
   // the same name as the module in the minidump
   OnDemandSymbolSupplier(const string &search_dir,
                          const string &symbol_search_dir);
   virtual ~OnDemandSymbolSupplier() {}
--- a/toolkit/xre/nsAppRunner.h
+++ b/toolkit/xre/nsAppRunner.h
@@ -27,21 +27,17 @@
 #include "nscore.h"
 #include "nsXULAppAPI.h"
 
 // This directory service key is a lot like NS_APP_LOCALSTORE_50_FILE,
 // but it is always the "main" localstore file, even when we're in safe mode
 // and we load localstore from somewhere else.
 #define NS_LOCALSTORE_UNSAFE_FILE "LStoreS"
 
-class nsACString;
-struct nsStaticModuleInfo;
-
 class nsINativeAppSupport;
-class nsICmdLineService;
 class nsXREDirProvider;
 class nsIToolkitProfileService;
 class nsIFile;
 class nsIProfileLock;
 class nsIProfileUnlocker;
 class nsIFactory;
 
 extern nsXREDirProvider* gDirServiceProvider;
--- a/uriloader/prefetch/OfflineCacheUpdateParent.h
+++ b/uriloader/prefetch/OfflineCacheUpdateParent.h
@@ -9,20 +9,16 @@
 #include "mozilla/docshell/POfflineCacheUpdateParent.h"
 #include "nsIOfflineCacheUpdate.h"
 
 #include "nsString.h"
 #include "nsILoadContext.h"
 
 namespace mozilla {
 
-namespace dom {
-class TabParent;
-}
-
 namespace ipc {
 class URIParams;
 } // namespace ipc
 
 namespace docshell {
 
 class OfflineCacheUpdateParent : public POfflineCacheUpdateParent
                                , public nsIOfflineCacheUpdateObserver
--- a/uriloader/prefetch/nsOfflineCacheUpdate.h
+++ b/uriloader/prefetch/nsOfflineCacheUpdate.h
@@ -31,19 +31,16 @@
 #include "nsICryptoHash.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/WeakPtr.h"
 #include "nsTHashtable.h"
 #include "nsHashKeys.h"
 
 class nsOfflineCacheUpdate;
 
-class nsIUTF8StringEnumerator;
-class nsILoadContext;
-
 class nsOfflineCacheUpdateItem : public nsIStreamListener
                                , public nsIRunnable
                                , public nsIInterfaceRequestor
                                , public nsIChannelEventSink
 {
 public:
     NS_DECL_ISUPPORTS
     NS_DECL_NSIREQUESTOBSERVER
--- a/uriloader/prefetch/nsPrefetchService.h
+++ b/uriloader/prefetch/nsPrefetchService.h
@@ -15,17 +15,16 @@
 #include "nsIChannel.h"
 #include "nsIURI.h"
 #include "nsWeakReference.h"
 #include "nsCOMPtr.h"
 #include "nsAutoPtr.h"
 #include "mozilla/Attributes.h"
 
 class nsPrefetchService;
-class nsPrefetchListener;
 class nsPrefetchNode;
 
 //-----------------------------------------------------------------------------
 // nsPrefetchService
 //-----------------------------------------------------------------------------
 
 class nsPrefetchService final : public nsIPrefetchService
                               , public nsIWebProgressListener