author | Joshua Cranmer <Pidgeot18@gmail.com> |
Fri, 06 Jul 2012 15:14:07 -0500 | |
changeset 106217 | fc4f105722ef11c244ee7f98c0aa6825ca84ad2d |
parent 106216 | 950048a5830253cf3611c82ed6d4e475c16a2dab |
child 106218 | 5a9c9b6b78c47590bf74611c4b4283231916bc21 |
push id | 214 |
push user | akeybl@mozilla.com |
push date | Wed, 14 Nov 2012 20:38:59 +0000 |
treeherder | mozilla-release@c8b08ec8e1aa [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
reviewers | ehsan |
bugs | 773637 |
milestone | 17.0a1 |
first release with | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
last release without | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
--- a/browser/components/migration/src/nsIEHistoryEnumerator.cpp +++ b/browser/components/migration/src/nsIEHistoryEnumerator.cpp @@ -68,17 +68,17 @@ nsIEHistoryEnumerator::EnsureInitialized return; hr = mIEHistory->EnumUrls(getter_AddRefs(mURLEnumerator)); if (FAILED(hr)) return; } NS_IMETHODIMP -nsIEHistoryEnumerator::HasMoreElements(bool* _retval NS_OUTPARAM) +nsIEHistoryEnumerator::HasMoreElements(bool* _retval) { *_retval = false; EnsureInitialized(); MOZ_ASSERT(mURLEnumerator, "Should have instanced an IE History URLEnumerator"); if (!mURLEnumerator) return NS_OK; @@ -119,17 +119,17 @@ nsIEHistoryEnumerator::HasMoreElements(b if (statURL.pwcsTitle) ::CoTaskMemFree(statURL.pwcsTitle); return NS_OK; } NS_IMETHODIMP -nsIEHistoryEnumerator::GetNext(nsISupports** _retval NS_OUTPARAM) +nsIEHistoryEnumerator::GetNext(nsISupports** _retval) { *_retval = nsnull; if (!mCachedNextEntry) return NS_ERROR_FAILURE; NS_ADDREF(*_retval = mCachedNextEntry); // Release the cached entry, so it can't be returned twice.
--- a/caps/include/nsPrincipal.h +++ b/caps/include/nsPrincipal.h @@ -24,22 +24,22 @@ public: nsBasePrincipal(); protected: virtual ~nsBasePrincipal(); public: NS_IMETHOD_(nsrefcnt) AddRef(void); NS_IMETHOD_(nsrefcnt) Release(void); - NS_SCRIPTABLE NS_IMETHOD GetPreferences(char** prefBranch NS_OUTPARAM, char** id NS_OUTPARAM, char** subjectName NS_OUTPARAM, char** grantedList NS_OUTPARAM, char** deniedList NS_OUTPARAM, bool* isTrusted NS_OUTPARAM); + NS_SCRIPTABLE NS_IMETHOD GetPreferences(char** prefBranch, char** id, char** subjectName, char** grantedList, char** deniedList, bool* isTrusted); NS_IMETHOD GetSecurityPolicy(void** aSecurityPolicy); NS_IMETHOD SetSecurityPolicy(void* aSecurityPolicy); - NS_IMETHOD CanEnableCapability(const char* capability, PRInt16* _retval NS_OUTPARAM); - NS_IMETHOD IsCapabilityEnabled(const char* capability, void* annotation, bool* _retval NS_OUTPARAM); - NS_IMETHOD EnableCapability(const char* capability, void** annotation NS_INOUTPARAM); + NS_IMETHOD CanEnableCapability(const char* capability, PRInt16* _retval); + NS_IMETHOD IsCapabilityEnabled(const char* capability, void* annotation, bool* _retval); + NS_IMETHOD EnableCapability(const char* capability, void** annotation); NS_IMETHOD GetHasCertificate(bool* aHasCertificate); NS_IMETHOD GetFingerprint(nsACString& aFingerprint); NS_IMETHOD GetPrettyName(nsACString& aPrettyName); NS_IMETHOD GetSubjectName(nsACString& aSubjectName); NS_IMETHOD GetCertificate(nsISupports** aCertificate); NS_IMETHOD GetCsp(nsIContentSecurityPolicy** aCsp); NS_IMETHOD SetCsp(nsIContentSecurityPolicy* aCsp); public: @@ -109,25 +109,25 @@ protected: bool mTrusted; }; class nsPrincipal : public nsBasePrincipal { public: NS_DECL_ISUPPORTS_INHERITED NS_DECL_NSISERIALIZABLE - NS_IMETHOD Equals(nsIPrincipal* other, bool* _retval NS_OUTPARAM); - NS_IMETHOD EqualsIgnoringDomain(nsIPrincipal* other, bool* _retval NS_OUTPARAM); + NS_IMETHOD Equals(nsIPrincipal* other, bool* _retval); + NS_IMETHOD EqualsIgnoringDomain(nsIPrincipal* other, bool* _retval); NS_IMETHOD GetHashValue(PRUint32* aHashValue); NS_IMETHOD GetURI(nsIURI** aURI); NS_IMETHOD GetDomain(nsIURI** aDomain); NS_IMETHOD SetDomain(nsIURI* aDomain); NS_IMETHOD GetOrigin(char** aOrigin); - NS_IMETHOD Subsumes(nsIPrincipal* other, bool* _retval NS_OUTPARAM); - NS_IMETHOD SubsumesIgnoringDomain(nsIPrincipal* other, bool* _retval NS_OUTPARAM); + NS_IMETHOD Subsumes(nsIPrincipal* other, bool* _retval); + NS_IMETHOD SubsumesIgnoringDomain(nsIPrincipal* other, bool* _retval); NS_IMETHOD CheckMayLoad(nsIURI* uri, bool report); NS_IMETHOD GetExtendedOrigin(nsACString& aExtendedOrigin); NS_IMETHOD GetAppStatus(PRUint16* aAppStatus); NS_IMETHOD GetAppId(PRUint32* aAppStatus); #ifdef DEBUG virtual void dumpImpl(); #endif @@ -187,25 +187,25 @@ public: protected: virtual ~nsExpandedPrincipal(); public: NS_DECL_ISUPPORTS_INHERITED NS_DECL_NSIEXPANDEDPRINCIPAL NS_DECL_NSISERIALIZABLE - NS_IMETHOD Equals(nsIPrincipal* other, bool* _retval NS_OUTPARAM); - NS_IMETHOD EqualsIgnoringDomain(nsIPrincipal* other, bool* _retval NS_OUTPARAM); + NS_IMETHOD Equals(nsIPrincipal* other, bool* _retval); + NS_IMETHOD EqualsIgnoringDomain(nsIPrincipal* other, bool* _retval); NS_IMETHOD GetHashValue(PRUint32* aHashValue); NS_IMETHOD GetURI(nsIURI** aURI); NS_IMETHOD GetDomain(nsIURI** aDomain); NS_IMETHOD SetDomain(nsIURI* aDomain); NS_IMETHOD GetOrigin(char** aOrigin); - NS_IMETHOD Subsumes(nsIPrincipal* other, bool* _retval NS_OUTPARAM); - NS_IMETHOD SubsumesIgnoringDomain(nsIPrincipal* other, bool* _retval NS_OUTPARAM); + NS_IMETHOD Subsumes(nsIPrincipal* other, bool* _retval); + NS_IMETHOD SubsumesIgnoringDomain(nsIPrincipal* other, bool* _retval); NS_IMETHOD CheckMayLoad(nsIURI* uri, bool report); NS_IMETHOD GetExtendedOrigin(nsACString& aExtendedOrigin); NS_IMETHOD GetAppStatus(PRUint16* aAppStatus); NS_IMETHOD GetAppId(PRUint32* aAppStatus); #ifdef DEBUG virtual void dumpImpl(); #endif
--- a/chrome/src/nsChromeRegistry.h +++ b/chrome/src/nsChromeRegistry.h @@ -52,19 +52,19 @@ class nsChromeRegistry : public nsIToolk { public: NS_DECL_ISUPPORTS // nsIXULChromeRegistry methods: NS_IMETHOD ReloadChrome(); NS_IMETHOD RefreshSkins(); NS_IMETHOD AllowScriptsForPackage(nsIURI* url, - bool* _retval NS_OUTPARAM); + bool* _retval); NS_IMETHOD AllowContentToAccess(nsIURI* url, - bool* _retval NS_OUTPARAM); + bool* _retval); // nsIChromeRegistry methods: NS_IMETHOD_(bool) WrappersEnabled(nsIURI *aURI); NS_IMETHOD ConvertChromeURL(nsIURI* aChromeURI, nsIURI* *aResult); // nsChromeRegistry methods: nsChromeRegistry() : mInitialized(false) { } virtual ~nsChromeRegistry();
--- a/content/base/src/nsGenericElement.h +++ b/content/base/src/nsGenericElement.h @@ -457,17 +457,17 @@ public: static void FireNodeInserted(nsIDocument* aDoc, nsINode* aParent, nsTArray<nsCOMPtr<nsIContent> >& aNodes); /** * Helper methods for implementing querySelector/querySelectorAll */ static nsIContent* doQuerySelector(nsINode* aRoot, const nsAString& aSelector, - nsresult *aResult NS_OUTPARAM); + nsresult *aResult); static nsresult doQuerySelectorAll(nsINode* aRoot, const nsAString& aSelector, nsIDOMNodeList **aReturn); /** * Method to create and dispatch a left-click event loosely based on * aSourceEvent. If aFullDispatch is true, the event will be dispatched * through the full dispatching of the presshell of the aPresContext; if it's
--- a/content/events/src/nsDOMEventTargetHelper.h +++ b/content/events/src/nsDOMEventTargetHelper.h @@ -207,17 +207,17 @@ private: return _to AddSystemEventListener(type, listener, aUseCapture, aWantsUntrusted, _argc); \ } \ NS_SCRIPTABLE NS_IMETHOD RemoveEventListener(const nsAString & type, nsIDOMEventListener *listener, bool useCapture) { \ return _to RemoveEventListener(type, listener, useCapture); \ } \ NS_IMETHOD RemoveSystemEventListener(const nsAString & type, nsIDOMEventListener *listener, bool aUseCapture) { \ return _to RemoveSystemEventListener(type, listener, aUseCapture); \ } \ - NS_SCRIPTABLE NS_IMETHOD DispatchEvent(nsIDOMEvent *evt, bool *_retval NS_OUTPARAM) { \ + NS_SCRIPTABLE NS_IMETHOD DispatchEvent(nsIDOMEvent *evt, bool *_retval) { \ return _to DispatchEvent(evt, _retval); \ } \ virtual nsIDOMEventTarget * GetTargetForDOMEvent(void) { \ return _to GetTargetForDOMEvent(); \ } \ virtual nsIDOMEventTarget * GetTargetForEventTargetChain(void) { \ return _to GetTargetForEventTargetChain(); \ } \ @@ -228,16 +228,16 @@ private: return _to PostHandleEvent(aVisitor); \ } \ virtual nsresult DispatchDOMEvent(nsEvent *aEvent, nsIDOMEvent *aDOMEvent, nsPresContext *aPresContext, nsEventStatus *aEventStatus) { \ return _to DispatchDOMEvent(aEvent, aDOMEvent, aPresContext, aEventStatus); \ } \ virtual nsEventListenerManager * GetListenerManager(bool aMayCreate) { \ return _to GetListenerManager(aMayCreate); \ } \ - virtual nsIScriptContext * GetContextForEventHandlers(nsresult *aRv NS_OUTPARAM) { \ + virtual nsIScriptContext * GetContextForEventHandlers(nsresult *aRv) { \ return _to GetContextForEventHandlers(aRv); \ } \ virtual JSContext * GetJSContextForEventHandlers(void) { \ return _to GetJSContextForEventHandlers(); \ } #endif // nsDOMEventTargetHelper_h_
--- a/content/html/content/src/nsDOMStringMap.cpp +++ b/content/html/content/src/nsDOMStringMap.cpp @@ -84,17 +84,17 @@ NS_IMETHODIMP_(bool) nsDOMStringMap::Has return false; } return mElement->HasAttr(kNameSpaceID_None, attrAtom); } /* [noscript] DOMString getDataAttr (in DOMString prop); */ NS_IMETHODIMP nsDOMStringMap::GetDataAttr(const nsAString& aProp, - nsAString& aResult NS_OUTPARAM) + nsAString& aResult) { nsAutoString attr; if (!DataPropToAttr(aProp, attr)) { aResult.SetIsVoid(true); return NS_OK; }
--- a/content/html/content/src/nsHTMLSelectElement.h +++ b/content/html/content/src/nsHTMLSelectElement.h @@ -303,17 +303,17 @@ public: /** * Checks whether an option is disabled (even if it's part of an optgroup) * * @param aIndex the index of the option to check * @return whether the option is disabled */ NS_IMETHOD IsOptionDisabled(PRInt32 aIndex, - bool *aIsDisabled NS_OUTPARAM); + bool *aIsDisabled); /** * Sets multiple options (or just sets startIndex if select is single) * and handles notifications and cleanup and everything under the sun. * When this method exits, the select will be in a consistent state. i.e. * if you set the last option to false, it will select an option anyway. * * @param aStartIndex the first index to set @@ -328,30 +328,30 @@ public: * @return whether any options were actually changed */ NS_IMETHOD SetOptionsSelectedByIndex(PRInt32 aStartIndex, PRInt32 aEndIndex, bool aIsSelected, bool aClearAll, bool aSetDisabled, bool aNotify, - bool* aChangedSomething NS_OUTPARAM); + bool* aChangedSomething); /** * Finds the index of a given option element * * @param aOption the option to get the index of * @param aStartIndex the index to start looking at * @param aForward TRUE to look forward, FALSE to look backward * @return the option index */ NS_IMETHOD GetOptionIndex(nsIDOMHTMLOptionElement* aOption, PRInt32 aStartIndex, bool aForward, - PRInt32* aIndex NS_OUTPARAM); + PRInt32* aIndex); /** * Called when an attribute is about to be changed */ virtual nsresult BindToTree(nsIDocument* aDocument, nsIContent* aParent, nsIContent* aBindingParent, bool aCompileEventHandlers); virtual void UnbindFromTree(bool aDeep, bool aNullParent);
--- a/dom/base/nsDOMWindowUtils.cpp +++ b/dom/base/nsDOMWindowUtils.cpp @@ -1925,17 +1925,17 @@ nsDOMWindowUtils::StartFrameTimeRecordin return NS_ERROR_FAILURE; mgr->StartFrameTimeRecording(); return NS_OK; } NS_IMETHODIMP -nsDOMWindowUtils::StopFrameTimeRecording(PRUint32 *frameCount NS_OUTPARAM, float **frames NS_OUTPARAM) +nsDOMWindowUtils::StopFrameTimeRecording(PRUint32 *frameCount, float **frames) { NS_ENSURE_ARG_POINTER(frameCount); NS_ENSURE_ARG_POINTER(frames); nsCOMPtr<nsIWidget> widget = GetWidget(); if (!widget) return NS_ERROR_FAILURE;
--- a/dom/base/nsGlobalWindowCommands.cpp +++ b/dom/base/nsGlobalWindowCommands.cpp @@ -89,17 +89,17 @@ const char * const sSelectBottomString = // a base class for selection-related commands, for code sharing class nsSelectionCommandsBase : public nsIControllerCommand { public: virtual ~nsSelectionCommandsBase() {} NS_DECL_ISUPPORTS - NS_IMETHOD IsCommandEnabled(const char * aCommandName, nsISupports *aCommandContext, bool *_retval NS_OUTPARAM); + NS_IMETHOD IsCommandEnabled(const char * aCommandName, nsISupports *aCommandContext, bool *_retval); NS_IMETHOD GetCommandStateParams(const char * aCommandName, nsICommandParams *aParams, nsISupports *aCommandContext); NS_IMETHOD DoCommandParams(const char * aCommandName, nsICommandParams *aParams, nsISupports *aCommandContext); protected: static nsresult GetPresShellFromWindow(nsPIDOMWindow *aWindow, nsIPresShell **aPresShell); static nsresult GetSelectionControllerFromWindow(nsPIDOMWindow *aWindow, nsISelectionController **aSelCon);
--- a/dom/devicestorage/nsDeviceStorage.cpp +++ b/dom/devicestorage/nsDeviceStorage.cpp @@ -1225,32 +1225,32 @@ nsDOMDeviceStorage::GetType(nsAString & default: aType.AssignLiteral("default"); break; } return NS_OK; } NS_IMETHODIMP -nsDOMDeviceStorage::Add(nsIDOMBlob *aBlob, nsIDOMDOMRequest * *_retval NS_OUTPARAM) +nsDOMDeviceStorage::Add(nsIDOMBlob *aBlob, nsIDOMDOMRequest * *_retval) { // possible race here w/ unique filename char buffer[128]; NS_MakeRandomString(buffer, 128); nsString path; path.AssignWithConversion(nsDependentCString(buffer)); return AddNamed(aBlob, path, _retval); } NS_IMETHODIMP nsDOMDeviceStorage::AddNamed(nsIDOMBlob *aBlob, const nsAString & aPath, - nsIDOMDOMRequest * *_retval NS_OUTPARAM) + nsIDOMDOMRequest * *_retval) { // if the blob is null here, bail if (aBlob == nsnull) return NS_OK; nsCOMPtr<nsPIDOMWindow> win = do_QueryReferent(mOwner); if (!win) { return NS_ERROR_UNEXPECTED; @@ -1272,33 +1272,33 @@ nsDOMDeviceStorage::AddNamed(nsIDOMBlob } NS_DispatchToMainThread(r); return NS_OK; } NS_IMETHODIMP nsDOMDeviceStorage::Get(const JS::Value & aPath, JSContext* aCx, - nsIDOMDOMRequest * *_retval NS_OUTPARAM) + nsIDOMDOMRequest * *_retval) { return GetInternal(aPath, aCx, _retval, false); } NS_IMETHODIMP nsDOMDeviceStorage::GetEditable(const JS::Value & aPath, JSContext* aCx, - nsIDOMDOMRequest * *_retval NS_OUTPARAM) + nsIDOMDOMRequest * *_retval) { return GetInternal(aPath, aCx, _retval, true); } nsresult nsDOMDeviceStorage::GetInternal(const JS::Value & aPath, JSContext* aCx, - nsIDOMDOMRequest * *_retval NS_OUTPARAM, + nsIDOMDOMRequest * *_retval, bool aEditable) { nsCOMPtr<nsPIDOMWindow> win = do_QueryReferent(mOwner); if (!win) { return NS_ERROR_UNEXPECTED; } nsRefPtr<DOMRequest> request = new DOMRequest(win); @@ -1326,17 +1326,17 @@ nsDOMDeviceStorage::GetInternal(const JS r = new DeviceStorageRequest(DeviceStorageRequest::DEVICE_STORAGE_REQUEST_READ, win, mURI, dsf, request); } NS_DispatchToMainThread(r); return NS_OK; } NS_IMETHODIMP -nsDOMDeviceStorage::Delete(const JS::Value & aPath, JSContext* aCx, nsIDOMDOMRequest * *_retval NS_OUTPARAM) +nsDOMDeviceStorage::Delete(const JS::Value & aPath, JSContext* aCx, nsIDOMDOMRequest * *_retval) { nsCOMPtr<nsIRunnable> r; nsCOMPtr<nsPIDOMWindow> win = do_QueryReferent(mOwner); if (!win) { return NS_ERROR_UNEXPECTED; }
--- a/dom/devicestorage/nsDeviceStorage.h +++ b/dom/devicestorage/nsDeviceStorage.h @@ -78,17 +78,17 @@ public: PRInt32 SetRootFileForType(const nsAString& aType, const PRInt32 aIndex); static void CreateDeviceStoragesFor(nsPIDOMWindow* aWin, const nsAString &aType, nsIVariant** _retval); private: ~nsDOMDeviceStorage(); - nsresult GetInternal(const JS::Value & aName, JSContext* aCx, nsIDOMDOMRequest * *_retval NS_OUTPARAM, bool aEditable); + nsresult GetInternal(const JS::Value & aName, JSContext* aCx, nsIDOMDOMRequest * *_retval, bool aEditable); nsresult EnumerateInternal(const JS::Value & aName, const JS::Value & aOptions, JSContext* aCx, PRUint8 aArgc, bool aEditable, nsIDOMDeviceStorageCursor** aRetval); PRInt32 mStorageType; nsCOMPtr<nsIFile> mFile; nsWeakPtr mOwner; nsCOMPtr<nsIURI> mURI;
--- a/dom/interfaces/events/nsIDOMEvent.idl +++ b/dom/interfaces/events/nsIDOMEvent.idl @@ -195,17 +195,17 @@ nsresult NS_NewDOMMouseScrollEvent(nsIDOMEvent** aInstancePtrResult, nsPresContext* aPresContext, class nsInputEvent *aEvent); nsresult NS_NewDOMDragEvent(nsIDOMEvent** aInstancePtrResult, nsPresContext* aPresContext, class nsDragEvent *aEvent); nsresult NS_NewDOMKeyboardEvent(nsIDOMEvent** aInstancePtrResult, nsPresContext* aPresContext, class nsKeyEvent *aEvent); nsresult NS_NewDOMCompositionEvent(nsIDOMEvent** aInstancePtrResult, nsPresContext* aPresContext, class nsCompositionEvent *aEvent); nsresult -NS_NewDOMMutationEvent(nsIDOMEvent** aResult NS_OUTPARAM, nsPresContext* aPresContext, class nsMutationEvent* aEvent); +NS_NewDOMMutationEvent(nsIDOMEvent** aResult, nsPresContext* aPresContext, class nsMutationEvent* aEvent); nsresult NS_NewDOMPopupBlockedEvent(nsIDOMEvent** aResult, nsPresContext* aPresContext, nsEvent* aEvent); nsresult NS_NewDOMDeviceOrientationEvent(nsIDOMEvent** aResult, nsPresContext* aPresContext, nsEvent* aEvent); nsresult NS_NewDOMDeviceLightEvent(nsIDOMEvent** aResult, nsPresContext* aPresContext, nsEvent* aEvent); nsresult NS_NewDOMDeviceMotionEvent(nsIDOMEvent** aResult, nsPresContext* aPresContext, nsEvent* aEvent);
--- a/dom/src/geolocation/nsGeolocation.cpp +++ b/dom/src/geolocation/nsGeolocation.cpp @@ -944,17 +944,17 @@ nsGeolocation::GetCurrentPosition(nsIDOM return NS_OK; } NS_IMETHODIMP nsGeolocation::WatchPosition(nsIDOMGeoPositionCallback *callback, nsIDOMGeoPositionErrorCallback *errorCallback, const jsval& options, JSContext* cx, - PRInt32 *_retval NS_OUTPARAM) + PRInt32 *_retval) { NS_ENSURE_ARG_POINTER(callback); if (!sGeoEnabled) return NS_ERROR_NOT_AVAILABLE; if (mPendingCallbacks.Length() > MAX_GEO_REQUESTS_PER_WINDOW)
--- a/dom/system/gonk/nsVolume.cpp +++ b/dom/system/gonk/nsVolume.cpp @@ -43,17 +43,17 @@ NS_IMETHODIMP nsVolume::GetMountPoint(ns } NS_IMETHODIMP nsVolume::GetState(PRInt32 *aState) { *aState = mState; return NS_OK; } -NS_IMETHODIMP nsVolume::GetStats(nsIVolumeStat **aResult NS_OUTPARAM) +NS_IMETHODIMP nsVolume::GetStats(nsIVolumeStat **aResult) { if (mState != STATE_MOUNTED) { return NS_ERROR_NOT_AVAILABLE; } NS_IF_ADDREF(*aResult = new nsVolumeStat(mMountPoint)); return NS_OK; }
--- a/dom/system/gonk/nsVolumeService.cpp +++ b/dom/system/gonk/nsVolumeService.cpp @@ -48,29 +48,29 @@ nsVolumeService::nsVolumeService() nsVolumeService::~nsVolumeService() { XRE_GetIOMessageLoop()->PostTask( FROM_HERE, NewRunnableFunction(ShutdownVolumeServiceIOThread)); } /* nsIVolume getVolumeByName (in DOMString volName); */ -NS_IMETHODIMP nsVolumeService::GetVolumeByName(const nsAString &aVolName, nsIVolume **aResult NS_OUTPARAM) +NS_IMETHODIMP nsVolumeService::GetVolumeByName(const nsAString &aVolName, nsIVolume **aResult) { nsRefPtr<nsVolume> vol = FindVolumeByName(aVolName); if (!vol) { return NS_ERROR_NOT_AVAILABLE; } NS_ADDREF(*aResult = vol); return NS_OK; } /* nsIVolume getVolumeByPath (in DOMString path); */ -NS_IMETHODIMP nsVolumeService::GetVolumeByPath(const nsAString &aPath, nsIVolume **aResult NS_OUTPARAM) +NS_IMETHODIMP nsVolumeService::GetVolumeByPath(const nsAString &aPath, nsIVolume **aResult) { nsCString utf8Path = NS_ConvertUTF16toUTF8(aPath); char realPathBuf[PATH_MAX]; if (!realpath(utf8Path.get(), realPathBuf)) { return NSRESULT_FOR_ERRNO(); }
--- a/image/src/RasterImage.h +++ b/image/src/RasterImage.h @@ -148,20 +148,20 @@ public: // BEGIN NS_DECL_IMGICONTAINER (minus GetAnimationMode/SetAnimationMode) // ** Don't edit this chunk except to mirror changes in imgIContainer.idl ** NS_SCRIPTABLE NS_IMETHOD GetWidth(PRInt32 *aWidth); NS_SCRIPTABLE NS_IMETHOD GetHeight(PRInt32 *aHeight); NS_SCRIPTABLE NS_IMETHOD GetType(PRUint16 *aType); NS_IMETHOD_(PRUint16) GetType(void); NS_SCRIPTABLE NS_IMETHOD GetAnimated(bool *aAnimated); NS_SCRIPTABLE NS_IMETHOD GetCurrentFrameIsOpaque(bool *aCurrentFrameIsOpaque); - NS_IMETHOD GetFrame(PRUint32 aWhichFrame, PRUint32 aFlags, gfxASurface **_retval NS_OUTPARAM); - NS_IMETHOD GetImageContainer(mozilla::layers::ImageContainer **_retval NS_OUTPARAM); - NS_IMETHOD CopyFrame(PRUint32 aWhichFrame, PRUint32 aFlags, gfxImageSurface **_retval NS_OUTPARAM); - NS_IMETHOD ExtractFrame(PRUint32 aWhichFrame, const nsIntRect & aRect, PRUint32 aFlags, imgIContainer **_retval NS_OUTPARAM); + NS_IMETHOD GetFrame(PRUint32 aWhichFrame, PRUint32 aFlags, gfxASurface **_retval); + NS_IMETHOD GetImageContainer(mozilla::layers::ImageContainer **_retval); + NS_IMETHOD CopyFrame(PRUint32 aWhichFrame, PRUint32 aFlags, gfxImageSurface **_retval); + NS_IMETHOD ExtractFrame(PRUint32 aWhichFrame, const nsIntRect & aRect, PRUint32 aFlags, imgIContainer **_retval); NS_IMETHOD Draw(gfxContext *aContext, gfxPattern::GraphicsFilter aFilter, const gfxMatrix & aUserSpaceToImageSpace, const gfxRect & aFill, const nsIntRect & aSubimage, const nsIntSize & aViewportSize, PRUint32 aFlags); NS_IMETHOD_(nsIFrame *) GetRootLayoutFrame(void); NS_SCRIPTABLE NS_IMETHOD RequestDecode(void); NS_SCRIPTABLE NS_IMETHOD LockImage(void); NS_SCRIPTABLE NS_IMETHOD UnlockImage(void); NS_SCRIPTABLE NS_IMETHOD RequestDiscard(void); NS_SCRIPTABLE NS_IMETHOD ResetAnimation(void); NS_IMETHOD_(void) RequestRefresh(const mozilla::TimeStamp& aTime);
--- a/image/src/VectorImage.h +++ b/image/src/VectorImage.h @@ -34,20 +34,20 @@ public: // BEGIN NS_DECL_IMGICONTAINER (minus GetAnimationMode/SetAnimationMode) // ** Don't edit this chunk except to mirror changes in imgIContainer.idl ** NS_SCRIPTABLE NS_IMETHOD GetWidth(PRInt32 *aWidth); NS_SCRIPTABLE NS_IMETHOD GetHeight(PRInt32 *aHeight); NS_SCRIPTABLE NS_IMETHOD GetType(PRUint16 *aType); NS_IMETHOD_(PRUint16) GetType(void); NS_SCRIPTABLE NS_IMETHOD GetAnimated(bool *aAnimated); NS_SCRIPTABLE NS_IMETHOD GetCurrentFrameIsOpaque(bool *aCurrentFrameIsOpaque); - NS_IMETHOD GetFrame(PRUint32 aWhichFrame, PRUint32 aFlags, gfxASurface **_retval NS_OUTPARAM); - NS_IMETHOD GetImageContainer(mozilla::layers::ImageContainer **_retval NS_OUTPARAM) { *_retval = NULL; return NS_OK; } - NS_IMETHOD CopyFrame(PRUint32 aWhichFrame, PRUint32 aFlags, gfxImageSurface **_retval NS_OUTPARAM); - NS_IMETHOD ExtractFrame(PRUint32 aWhichFrame, const nsIntRect & aRect, PRUint32 aFlags, imgIContainer **_retval NS_OUTPARAM); + NS_IMETHOD GetFrame(PRUint32 aWhichFrame, PRUint32 aFlags, gfxASurface **_retval); + NS_IMETHOD GetImageContainer(mozilla::layers::ImageContainer **_retval) { *_retval = NULL; return NS_OK; } + NS_IMETHOD CopyFrame(PRUint32 aWhichFrame, PRUint32 aFlags, gfxImageSurface **_retval); + NS_IMETHOD ExtractFrame(PRUint32 aWhichFrame, const nsIntRect & aRect, PRUint32 aFlags, imgIContainer **_retval); NS_IMETHOD Draw(gfxContext *aContext, gfxPattern::GraphicsFilter aFilter, const gfxMatrix & aUserSpaceToImageSpace, const gfxRect & aFill, const nsIntRect & aSubimage, const nsIntSize & aViewportSize, PRUint32 aFlags); NS_IMETHOD_(nsIFrame *) GetRootLayoutFrame(void); NS_SCRIPTABLE NS_IMETHOD RequestDecode(void); NS_SCRIPTABLE NS_IMETHOD LockImage(void); NS_SCRIPTABLE NS_IMETHOD UnlockImage(void); NS_SCRIPTABLE NS_IMETHOD RequestDiscard(void); NS_SCRIPTABLE NS_IMETHOD ResetAnimation(void); NS_IMETHOD_(void) RequestRefresh(const mozilla::TimeStamp& aTime);
--- a/js/xpconnect/src/XPCException.cpp +++ b/js/xpconnect/src/XPCException.cpp @@ -115,17 +115,17 @@ nsXPCException::nsXPCException() nsXPCException::~nsXPCException() { MOZ_COUNT_DTOR(nsXPCException); Reset(); } /* [noscript] xpcexJSVal stealJSVal (); */ NS_IMETHODIMP -nsXPCException::StealJSVal(jsval *vp NS_OUTPARAM) +nsXPCException::StealJSVal(jsval *vp) { if (mThrownJSVal.IsHeld()) { *vp = mThrownJSVal.Release(); return NS_OK; } return NS_ERROR_FAILURE; }
--- a/js/xpconnect/src/XPCQuickStubs.h +++ b/js/xpconnect/src/XPCQuickStubs.h @@ -398,17 +398,17 @@ xpc_qsUnwrapThis(JSContext *cx, MOZ_ALWAYS_INLINE nsISupports* castNativeFromWrapper(JSContext *cx, JSObject *obj, PRUint32 interfaceBit, nsISupports **pRef, jsval *pVal, XPCLazyCallContext *lccx, - nsresult *rv NS_OUTPARAM) + nsresult *rv) { XPCWrappedNative *wrapper; XPCWrappedNativeTearOff *tearoff; JSObject *cur; if (IS_WRAPPER_CLASS(js::GetObjectClass(obj))) { cur = obj; wrapper = IS_WN_WRAPPER_OBJECT(cur) ? @@ -505,17 +505,17 @@ xpc_qsUnwrapArg(JSContext *cx, jsval v, } inline nsISupports* castNativeArgFromWrapper(JSContext *cx, jsval v, PRUint32 bit, nsISupports **pArgRef, jsval *vp, - nsresult *rv NS_OUTPARAM) + nsresult *rv) { JSObject *src = xpc_qsUnwrapObj(v, pArgRef, rv); if (!src) return nsnull; return castNativeFromWrapper(cx, src, bit, pArgRef, vp, nsnull, rv); }
--- a/js/xpconnect/src/XPCWrappedJSClass.cpp +++ b/js/xpconnect/src/XPCWrappedJSClass.cpp @@ -538,46 +538,46 @@ NS_IMPL_ADDREF(SameOriginCheckedComponen NS_IMPL_RELEASE(SameOriginCheckedComponent) NS_INTERFACE_MAP_BEGIN(SameOriginCheckedComponent) NS_INTERFACE_MAP_ENTRY(nsISecurityCheckedComponent) NS_INTERFACE_MAP_END_AGGREGATED(mDelegate) NS_IMETHODIMP SameOriginCheckedComponent::CanCreateWrapper(const nsIID * iid, - char **_retval NS_OUTPARAM) + char **_retval) { // XXX This doesn't actually work because nsScriptSecurityManager doesn't // know what to do with "sameOrigin" for canCreateWrapper. *_retval = NS_strdup("sameOrigin"); return *_retval ? NS_OK : NS_ERROR_OUT_OF_MEMORY; } NS_IMETHODIMP SameOriginCheckedComponent::CanCallMethod(const nsIID * iid, const PRUnichar *methodName, - char **_retval NS_OUTPARAM) + char **_retval) { *_retval = NS_strdup("sameOrigin"); return *_retval ? NS_OK : NS_ERROR_OUT_OF_MEMORY; } NS_IMETHODIMP SameOriginCheckedComponent::CanGetProperty(const nsIID * iid, const PRUnichar *propertyName, - char **_retval NS_OUTPARAM) + char **_retval) { *_retval = NS_strdup("sameOrigin"); return *_retval ? NS_OK : NS_ERROR_OUT_OF_MEMORY; } NS_IMETHODIMP SameOriginCheckedComponent::CanSetProperty(const nsIID * iid, const PRUnichar *propertyName, - char **_retval NS_OUTPARAM) + char **_retval) { *_retval = NS_strdup("sameOrigin"); return *_retval ? NS_OK : NS_ERROR_OUT_OF_MEMORY; } NS_IMETHODIMP nsXPCWrappedJSClass::DelegatedQueryInterface(nsXPCWrappedJS* self, REFNSIID aIID,
--- a/js/xpconnect/tests/components/native/xpctest_params.cpp +++ b/js/xpconnect/tests/components/native/xpctest_params.cpp @@ -65,226 +65,226 @@ nsXPCTestParams::~nsXPCTestParams() since the caller owns it. */ \ for (unsigned i = 0; i < *bLength + padding; ++i) \ TAKE_OWNERSHIP((*b)[i]); \ \ return NS_OK; \ } /* boolean testBoolean (in boolean a, inout boolean b); */ -NS_IMETHODIMP nsXPCTestParams::TestBoolean(bool a, bool *b NS_INOUTPARAM, bool *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestBoolean(bool a, bool *b, bool *_retval) { GENERIC_METHOD_IMPL; } /* octet testOctet (in octet a, inout octet b); */ -NS_IMETHODIMP nsXPCTestParams::TestOctet(PRUint8 a, PRUint8 *b NS_INOUTPARAM, PRUint8 *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestOctet(PRUint8 a, PRUint8 *b, PRUint8 *_retval) { GENERIC_METHOD_IMPL; } /* short testShort (in short a, inout short b); */ -NS_IMETHODIMP nsXPCTestParams::TestShort(PRInt16 a, PRInt16 *b NS_INOUTPARAM, PRInt16 *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestShort(PRInt16 a, PRInt16 *b, PRInt16 *_retval) { GENERIC_METHOD_IMPL; } /* long testLong (in long a, inout long b); */ -NS_IMETHODIMP nsXPCTestParams::TestLong(PRInt32 a, PRInt32 *b NS_INOUTPARAM, PRInt32 *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestLong(PRInt32 a, PRInt32 *b, PRInt32 *_retval) { GENERIC_METHOD_IMPL; } /* long long testLongLong (in long long a, inout long long b); */ -NS_IMETHODIMP nsXPCTestParams::TestLongLong(PRInt64 a, PRInt64 *b NS_INOUTPARAM, PRInt64 *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestLongLong(PRInt64 a, PRInt64 *b, PRInt64 *_retval) { GENERIC_METHOD_IMPL; } /* unsigned short testUnsignedShort (in unsigned short a, inout unsigned short b); */ -NS_IMETHODIMP nsXPCTestParams::TestUnsignedShort(PRUint16 a, PRUint16 *b NS_INOUTPARAM, PRUint16 *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestUnsignedShort(PRUint16 a, PRUint16 *b, PRUint16 *_retval) { GENERIC_METHOD_IMPL; } /* unsigned long testUnsignedLong (in unsigned long a, inout unsigned long b); */ -NS_IMETHODIMP nsXPCTestParams::TestUnsignedLong(PRUint32 a, PRUint32 *b NS_INOUTPARAM, PRUint32 *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestUnsignedLong(PRUint32 a, PRUint32 *b, PRUint32 *_retval) { GENERIC_METHOD_IMPL; } /* unsigned long long testUnsignedLongLong (in unsigned long long a, inout unsigned long long b); */ -NS_IMETHODIMP nsXPCTestParams::TestUnsignedLongLong(PRUint64 a, PRUint64 *b NS_INOUTPARAM, PRUint64 *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestUnsignedLongLong(PRUint64 a, PRUint64 *b, PRUint64 *_retval) { GENERIC_METHOD_IMPL; } /* float testFloat (in float a, inout float b); */ -NS_IMETHODIMP nsXPCTestParams::TestFloat(float a, float *b NS_INOUTPARAM, float *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestFloat(float a, float *b, float *_retval) { GENERIC_METHOD_IMPL; } /* double testDouble (in double a, inout float b); */ -NS_IMETHODIMP nsXPCTestParams::TestDouble(double a, float *b NS_INOUTPARAM, double *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestDouble(double a, float *b, double *_retval) { GENERIC_METHOD_IMPL; } /* char testChar (in char a, inout char b); */ -NS_IMETHODIMP nsXPCTestParams::TestChar(char a, char *b NS_INOUTPARAM, char *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestChar(char a, char *b, char *_retval) { GENERIC_METHOD_IMPL; } /* string testString (in string a, inout string b); */ -NS_IMETHODIMP nsXPCTestParams::TestString(const char * a, char * *b NS_INOUTPARAM, char * *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestString(const char * a, char * *b, char * *_retval) { nsDependentCString aprime(a); nsDependentCString bprime(*b); *_retval = ToNewCString(bprime); *b = ToNewCString(aprime); // XPCOM ownership rules dictate that overwritten inout params must be callee-freed. // See https://developer.mozilla.org/en/XPIDL NS_Free(const_cast<char*>(bprime.get())); return NS_OK; } /* wchar testWchar (in wchar a, inout wchar b); */ -NS_IMETHODIMP nsXPCTestParams::TestWchar(PRUnichar a, PRUnichar *b NS_INOUTPARAM, PRUnichar *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestWchar(PRUnichar a, PRUnichar *b, PRUnichar *_retval) { GENERIC_METHOD_IMPL; } /* wstring testWstring (in wstring a, inout wstring b); */ -NS_IMETHODIMP nsXPCTestParams::TestWstring(const PRUnichar * a, PRUnichar * *b NS_INOUTPARAM, PRUnichar * *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestWstring(const PRUnichar * a, PRUnichar * *b, PRUnichar * *_retval) { nsDependentString aprime(a); nsDependentString bprime(*b); *_retval = ToNewUnicode(bprime); *b = ToNewUnicode(aprime); // XPCOM ownership rules dictate that overwritten inout params must be callee-freed. // See https://developer.mozilla.org/en/XPIDL NS_Free(const_cast<PRUnichar*>(bprime.get())); return NS_OK; } /* DOMString testDOMString (in DOMString a, inout DOMString b); */ -NS_IMETHODIMP nsXPCTestParams::TestDOMString(const nsAString & a, nsAString & b NS_INOUTPARAM, nsAString & _retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestDOMString(const nsAString & a, nsAString & b, nsAString & _retval) { STRING_METHOD_IMPL; } /* AString testAString (in AString a, inout AString b); */ -NS_IMETHODIMP nsXPCTestParams::TestAString(const nsAString & a, nsAString & b NS_INOUTPARAM, nsAString & _retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestAString(const nsAString & a, nsAString & b, nsAString & _retval) { STRING_METHOD_IMPL; } /* AUTF8String testAUTF8String (in AUTF8String a, inout AUTF8String b); */ -NS_IMETHODIMP nsXPCTestParams::TestAUTF8String(const nsACString & a, nsACString & b NS_INOUTPARAM, nsACString & _retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestAUTF8String(const nsACString & a, nsACString & b, nsACString & _retval) { STRING_METHOD_IMPL; } /* ACString testACString (in ACString a, inout ACString b); */ -NS_IMETHODIMP nsXPCTestParams::TestACString(const nsACString & a, nsACString & b NS_INOUTPARAM, nsACString & _retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestACString(const nsACString & a, nsACString & b, nsACString & _retval) { STRING_METHOD_IMPL; } /* jsval testJsval (in jsval a, inout jsval b); */ -NS_IMETHODIMP nsXPCTestParams::TestJsval(const jsval & a, jsval & b NS_INOUTPARAM, jsval *_retval NS_OUTPARAM) +NS_IMETHODIMP nsXPCTestParams::TestJsval(const jsval & a, jsval & b, jsval *_retval) { *_retval = b; b = a; return NS_OK; } /* void testShortArray (in unsigned long aLength, [array, size_is (aLength)] in short a, * inout unsigned long bLength, [array, size_is (bLength)] inout short b, * out unsigned long rvLength, [array, size_is (rvLength), retval] out short rv); */ NS_IMETHODIMP nsXPCTestParams::TestShortArray(PRUint32 aLength, PRInt16 *a, - PRUint32 *bLength NS_INOUTPARAM, PRInt16 **b NS_INOUTPARAM, - PRUint32 *rvLength NS_OUTPARAM, PRInt16 **rv NS_OUTPARAM) + PRUint32 *bLength, PRInt16 **b, + PRUint32 *rvLength, PRInt16 **rv) { BUFFER_METHOD_IMPL(PRInt16, 0, TAKE_OWNERSHIP_NOOP); } /* void testDoubleArray (in unsigned long aLength, [array, size_is (aLength)] in double a, * inout unsigned long bLength, [array, size_is (bLength)] inout double b, * out unsigned long rvLength, [array, size_is (rvLength), retval] out double rv); */ NS_IMETHODIMP nsXPCTestParams::TestDoubleArray(PRUint32 aLength, double *a, - PRUint32 *bLength NS_INOUTPARAM, double **b NS_INOUTPARAM, - PRUint32 *rvLength NS_OUTPARAM, double **rv NS_OUTPARAM) + PRUint32 *bLength, double **b, + PRUint32 *rvLength, double **rv) { BUFFER_METHOD_IMPL(double, 0, TAKE_OWNERSHIP_NOOP); } /* void testStringArray (in unsigned long aLength, [array, size_is (aLength)] in string a, * inout unsigned long bLength, [array, size_is (bLength)] inout string b, * out unsigned long rvLength, [array, size_is (rvLength), retval] out string rv); */ NS_IMETHODIMP nsXPCTestParams::TestStringArray(PRUint32 aLength, const char * *a, - PRUint32 *bLength NS_INOUTPARAM, char * **b NS_INOUTPARAM, - PRUint32 *rvLength NS_OUTPARAM, char * **rv NS_OUTPARAM) + PRUint32 *bLength, char * **b, + PRUint32 *rvLength, char * **rv) { BUFFER_METHOD_IMPL(char*, 0, TAKE_OWNERSHIP_STRING); } /* void testWstringArray (in unsigned long aLength, [array, size_is (aLength)] in wstring a, * inout unsigned long bLength, [array, size_is (bLength)] inout wstring b, * out unsigned long rvLength, [array, size_is (rvLength), retval] out wstring rv); */ NS_IMETHODIMP nsXPCTestParams::TestWstringArray(PRUint32 aLength, const PRUnichar * *a, - PRUint32 *bLength NS_INOUTPARAM, PRUnichar * **b NS_INOUTPARAM, - PRUint32 *rvLength NS_OUTPARAM, PRUnichar * **rv NS_OUTPARAM) + PRUint32 *bLength, PRUnichar * **b, + PRUint32 *rvLength, PRUnichar * **rv) { BUFFER_METHOD_IMPL(PRUnichar*, 0, TAKE_OWNERSHIP_WSTRING); } /* void testInterfaceArray (in unsigned long aLength, [array, size_is (aLength)] in nsIXPCTestInterfaceA a, * inout unsigned long bLength, [array, size_is (bLength)] inout nsIXPCTestInterfaceA b, * out unsigned long rvLength, [array, size_is (rvLength), retval] out nsIXPCTestInterfaceA rv); */ NS_IMETHODIMP nsXPCTestParams::TestInterfaceArray(PRUint32 aLength, nsIXPCTestInterfaceA **a, - PRUint32 *bLength NS_INOUTPARAM, nsIXPCTestInterfaceA * **b NS_INOUTPARAM, - PRUint32 *rvLength NS_OUTPARAM, nsIXPCTestInterfaceA * **rv NS_OUTPARAM) + PRUint32 *bLength, nsIXPCTestInterfaceA * **b, + PRUint32 *rvLength, nsIXPCTestInterfaceA * **rv) { BUFFER_METHOD_IMPL(nsIXPCTestInterfaceA*, 0, TAKE_OWNERSHIP_INTERFACE); } /* void testSizedString (in unsigned long aLength, [size_is (aLength)] in string a, * inout unsigned long bLength, [size_is (bLength)] inout string b, * out unsigned long rvLength, [size_is (rvLength), retval] out string rv); */ NS_IMETHODIMP nsXPCTestParams::TestSizedString(PRUint32 aLength, const char * a, - PRUint32 *bLength NS_INOUTPARAM, char * *b NS_INOUTPARAM, - PRUint32 *rvLength NS_OUTPARAM, char * *rv NS_OUTPARAM) + PRUint32 *bLength, char * *b, + PRUint32 *rvLength, char * *rv) { BUFFER_METHOD_IMPL(char, 1, TAKE_OWNERSHIP_NOOP); } /* void testSizedWstring (in unsigned long aLength, [size_is (aLength)] in wstring a, * inout unsigned long bLength, [size_is (bLength)] inout wstring b, * out unsigned long rvLength, [size_is (rvLength), retval] out wstring rv); */ NS_IMETHODIMP nsXPCTestParams::TestSizedWstring(PRUint32 aLength, const PRUnichar * a, - PRUint32 *bLength NS_INOUTPARAM, PRUnichar * *b NS_INOUTPARAM, - PRUint32 *rvLength NS_OUTPARAM, PRUnichar * *rv NS_OUTPARAM) + PRUint32 *bLength, PRUnichar * *b, + PRUint32 *rvLength, PRUnichar * *rv) { BUFFER_METHOD_IMPL(PRUnichar, 1, TAKE_OWNERSHIP_NOOP); } /* void testInterfaceIs (in nsIIDPtr aIID, [iid_is (aIID)] in nsQIResult a, * inout nsIIDPtr bIID, [iid_is (bIID)] inout nsQIResult b, * out nsIIDPtr rvIID, [iid_is (rvIID), retval] out nsQIResult rv); */ NS_IMETHODIMP nsXPCTestParams::TestInterfaceIs(const nsIID *aIID, void *a, - nsIID **bIID NS_INOUTPARAM, void **b NS_INOUTPARAM, - nsIID **rvIID NS_OUTPARAM, void **rv NS_OUTPARAM) + nsIID **bIID, void **b, + nsIID **rvIID, void **rv) { // // Getting the buffers and ownership right here can be a little tricky. // // The interface pointers are heap-allocated, and b has been AddRef'd // by XPConnect for the duration of the call. If we snatch it away from b // and leave no trace, XPConnect won't Release it. Since we also need to @@ -313,20 +313,20 @@ NS_IMETHODIMP nsXPCTestParams::TestInter /* void testInterfaceIsArray (in unsigned long aLength, in nsIIDPtr aIID, * [array, size_is (aLength), iid_is (aIID)] in nsQIResult a, * inout unsigned long bLength, inout nsIIDPtr bIID, * [array, size_is (bLength), iid_is (bIID)] inout nsQIResult b, * out unsigned long rvLength, out nsIIDPtr rvIID, * [retval, array, size_is (rvLength), iid_is (rvIID)] out nsQIResult rv); */ NS_IMETHODIMP nsXPCTestParams::TestInterfaceIsArray(PRUint32 aLength, const nsIID *aIID, void **a, - PRUint32 *bLength NS_INOUTPARAM, nsIID **bIID NS_INOUTPARAM, - void ***b NS_INOUTPARAM, - PRUint32 *rvLength NS_OUTPARAM, nsIID **rvIID NS_OUTPARAM, - void ***rv NS_OUTPARAM) + PRUint32 *bLength, nsIID **bIID, + void ***b, + PRUint32 *rvLength, nsIID **rvIID, + void ***rv) { // Transfer the IIDs. See the comments in TestInterfaceIs (above) for an // explanation of what we're doing. *rvIID = static_cast<nsIID*>(NS_Alloc(sizeof(nsID))); if (!*rvIID) return NS_ERROR_OUT_OF_MEMORY; **rvIID = **bIID; **bIID = *aIID;
--- a/layout/inspector/src/nsFontFaceList.cpp +++ b/layout/inspector/src/nsFontFaceList.cpp @@ -42,17 +42,17 @@ FindByIndex(gfxFontEntry* aKey, nsIDOMFo data->mResult = aData; return PL_DHASH_STOP; } data->mCurrent++; return PL_DHASH_NEXT; } NS_IMETHODIMP -nsFontFaceList::Item(PRUint32 index, nsIDOMFontFace **_retval NS_OUTPARAM) +nsFontFaceList::Item(PRUint32 index, nsIDOMFontFace **_retval) { NS_ENSURE_TRUE(index < mFontFaces.Count(), NS_ERROR_INVALID_ARG); FindByIndexData userData; userData.mTarget = index; userData.mCurrent = 0; userData.mResult = nsnull; mFontFaces.EnumerateRead(FindByIndex, &userData); NS_ASSERTION(userData.mResult != nsnull, "null entry in nsFontFaceList?");
--- a/layout/style/nsCSSRules.cpp +++ b/layout/style/nsCSSRules.cpp @@ -1256,17 +1256,17 @@ DOMCI_DATA(CSSNameSpaceRule, css::NameSp // // A src: descriptor is represented as an array value; each entry in // the array can be eCSSUnit_URL, eCSSUnit_Local_Font, or // eCSSUnit_Font_Format. Blocks of eCSSUnit_Font_Format may appear // only after one of the first two. (css3-fonts only contemplates // annotating URLs with formats, but we handle the general case.) static void -AppendSerializedFontSrc(const nsCSSValue& src, nsAString & aResult NS_OUTPARAM) +AppendSerializedFontSrc(const nsCSSValue& src, nsAString & aResult) { NS_PRECONDITION(src.GetUnit() == eCSSUnit_Array, "improper value unit for src:"); const nsCSSValue::Array& sources = *src.GetArrayValue(); size_t i = 0; while (i < sources.Count()) { @@ -1305,28 +1305,28 @@ AppendSerializedFontSrc(const nsCSSValue } aResult.AppendLiteral(", "); } aResult.Truncate(aResult.Length() - 2); // remove the last comma-space } // print all characters with at least four hex digits static void -AppendSerializedUnicodePoint(PRUint32 aCode, nsACString &aBuf NS_OUTPARAM) +AppendSerializedUnicodePoint(PRUint32 aCode, nsACString &aBuf) { aBuf.Append(nsPrintfCString("%04X", aCode)); } // A unicode-range: descriptor is represented as an array of integers, // to be interpreted as a sequence of pairs: min max min max ... // It is in source order. (Possibly it should be sorted and overlaps // consolidated, but right now we don't do that.) static void AppendSerializedUnicodeRange(nsCSSValue const & aValue, - nsAString & aResult NS_OUTPARAM) + nsAString & aResult) { NS_PRECONDITION(aValue.GetUnit() == eCSSUnit_Null || aValue.GetUnit() == eCSSUnit_Array, "improper value unit for unicode-range:"); aResult.Truncate(); if (aValue.GetUnit() != eCSSUnit_Array) return; @@ -1372,17 +1372,17 @@ NS_INTERFACE_MAP_BEGIN(nsCSSFontFaceStyl NS_INTERFACE_MAP_END NS_IMPL_ADDREF_USING_AGGREGATOR(nsCSSFontFaceStyleDecl, ContainingRule()) NS_IMPL_RELEASE_USING_AGGREGATOR(nsCSSFontFaceStyleDecl, ContainingRule()) // helper for string GetPropertyValue and RemovePropertyValue nsresult nsCSSFontFaceStyleDecl::GetPropertyValue(nsCSSFontDesc aFontDescID, - nsAString & aResult NS_OUTPARAM) const + nsAString & aResult) const { NS_ENSURE_ARG_RANGE(aFontDescID, eCSSFontDesc_UNKNOWN, eCSSFontDesc_COUNT - 1); aResult.Truncate(); if (aFontDescID == eCSSFontDesc_UNKNOWN) return NS_OK; @@ -1471,34 +1471,34 @@ NS_IMETHODIMP nsCSSFontFaceStyleDecl::SetCssText(const nsAString & aCssText) { return NS_ERROR_NOT_IMPLEMENTED; // bug 443978 } // DOMString getPropertyValue (in DOMString propertyName); NS_IMETHODIMP nsCSSFontFaceStyleDecl::GetPropertyValue(const nsAString & propertyName, - nsAString & aResult NS_OUTPARAM) + nsAString & aResult) { return GetPropertyValue(nsCSSProps::LookupFontDesc(propertyName), aResult); } // nsIDOMCSSValue getPropertyCSSValue (in DOMString propertyName); NS_IMETHODIMP nsCSSFontFaceStyleDecl::GetPropertyCSSValue(const nsAString & propertyName, - nsIDOMCSSValue **aResult NS_OUTPARAM) + nsIDOMCSSValue **aResult) { // ??? nsDOMCSSDeclaration returns null/NS_OK, but that seems wrong. return NS_ERROR_NOT_IMPLEMENTED; } // DOMString removeProperty (in DOMString propertyName) raises (DOMException); NS_IMETHODIMP nsCSSFontFaceStyleDecl::RemoveProperty(const nsAString & propertyName, - nsAString & aResult NS_OUTPARAM) + nsAString & aResult) { nsCSSFontDesc descID = nsCSSProps::LookupFontDesc(propertyName); NS_ASSERTION(descID >= eCSSFontDesc_UNKNOWN && descID < eCSSFontDesc_COUNT, "LookupFontDesc returned value out of range"); if (descID == eCSSFontDesc_UNKNOWN) { aResult.Truncate(); @@ -1508,17 +1508,17 @@ nsCSSFontFaceStyleDecl::RemoveProperty(c (this->*nsCSSFontFaceStyleDecl::Fields[descID]).Reset(); } return NS_OK; } // DOMString getPropertyPriority (in DOMString propertyName); NS_IMETHODIMP nsCSSFontFaceStyleDecl::GetPropertyPriority(const nsAString & propertyName, - nsAString & aResult NS_OUTPARAM) + nsAString & aResult) { // font descriptors do not have priorities at present aResult.Truncate(); return NS_OK; } // void setProperty (in DOMString propertyName, in DOMString value, // in DOMString priority) raises (DOMException); @@ -1542,17 +1542,17 @@ nsCSSFontFaceStyleDecl::GetLength(PRUint len++; *aLength = len; return NS_OK; } // DOMString item (in unsigned long index); NS_IMETHODIMP -nsCSSFontFaceStyleDecl::Item(PRUint32 index, nsAString & aResult NS_OUTPARAM) +nsCSSFontFaceStyleDecl::Item(PRUint32 index, nsAString & aResult) { PRInt32 nset = -1; for (nsCSSFontDesc id = nsCSSFontDesc(eCSSFontDesc_UNKNOWN + 1); id < eCSSFontDesc_COUNT; id = nsCSSFontDesc(id + 1)) { if ((this->*nsCSSFontFaceStyleDecl::Fields[id]).GetUnit() != eCSSUnit_Null) { nset++;
--- a/layout/style/nsCSSRules.h +++ b/layout/style/nsCSSRules.h @@ -157,17 +157,17 @@ protected: class nsCSSFontFaceRule; class nsCSSFontFaceStyleDecl : public nsIDOMCSSStyleDeclaration { public: NS_DECL_ISUPPORTS NS_DECL_NSIDOMCSSSTYLEDECLARATION nsresult GetPropertyValue(nsCSSFontDesc aFontDescID, - nsAString & aResult NS_OUTPARAM) const; + nsAString & aResult) const; protected: friend class nsCSSFontFaceRule; #define CSS_FONT_DESC(name_, method_) nsCSSValue m##method_; #include "nsCSSFontDescList.h" #undef CSS_FONT_DESC static nsCSSValue nsCSSFontFaceStyleDecl::* const Fields[];
--- a/modules/libjar/nsZipArchive.h +++ b/modules/libjar/nsZipArchive.h @@ -370,19 +370,19 @@ public: return ret; } }; class nsZipHandle { friend class nsZipArchive; friend class mozilla::FileLocation; public: - static nsresult Init(nsIFile *file, nsZipHandle **ret NS_OUTPARAM); + static nsresult Init(nsIFile *file, nsZipHandle **ret); static nsresult Init(nsZipArchive *zip, const char *entry, - nsZipHandle **ret NS_OUTPARAM); + nsZipHandle **ret); NS_METHOD_(nsrefcnt) AddRef(void); NS_METHOD_(nsrefcnt) Release(void); PRInt64 SizeOfMapping(); protected: const PRUint8 * mFileData; /* pointer to mmaped file */
--- a/netwerk/base/src/RedirectChannelRegistrar.cpp +++ b/netwerk/base/src/RedirectChannelRegistrar.cpp @@ -32,33 +32,33 @@ RedirectChannelRegistrar::RedirectChanne : mId(1) { mRealChannels.Init(64); mParentChannels.Init(64); } NS_IMETHODIMP RedirectChannelRegistrar::RegisterChannel(nsIChannel *channel, - PRUint32 *_retval NS_OUTPARAM) + PRUint32 *_retval) { mRealChannels.Put(mId, channel); *_retval = mId; ++mId; // Ensure we always provide positive ids if (!mId) mId = 1; return NS_OK; } NS_IMETHODIMP RedirectChannelRegistrar::GetRegisteredChannel(PRUint32 id, - nsIChannel **_retval NS_OUTPARAM) + nsIChannel **_retval) { if (!mRealChannels.Get(id, _retval)) return NS_ERROR_NOT_AVAILABLE; return NS_OK; } NS_IMETHODIMP @@ -70,17 +70,17 @@ RedirectChannelRegistrar::LinkChannels(P return NS_ERROR_NOT_AVAILABLE; mParentChannels.Put(id, channel); return NS_OK; } NS_IMETHODIMP RedirectChannelRegistrar::GetParentChannel(PRUint32 id, - nsIParentChannel **_retval NS_OUTPARAM) + nsIParentChannel **_retval) { if (!mParentChannels.Get(id, _retval)) return NS_ERROR_NOT_AVAILABLE; return NS_OK; } NS_IMETHODIMP
--- a/netwerk/base/src/nsPreloadedStream.cpp +++ b/netwerk/base/src/nsPreloadedStream.cpp @@ -36,30 +36,30 @@ NS_IMETHODIMP nsPreloadedStream::Close() { mLen = 0; return mStream->Close(); } NS_IMETHODIMP -nsPreloadedStream::Available(PRUint32 *_retval NS_OUTPARAM) +nsPreloadedStream::Available(PRUint32 *_retval) { PRUint32 avail = 0; nsresult rv = mStream->Available(&avail); if (NS_FAILED(rv)) return rv; *_retval = avail + mLen; return NS_OK; } NS_IMETHODIMP nsPreloadedStream::Read(char *aBuf, PRUint32 aCount, - PRUint32 *_retval NS_OUTPARAM) + PRUint32 *_retval) { if (!mLen) return mStream->Read(aBuf, aCount, _retval); PRUint32 toRead = NS_MIN(mLen, aCount); memcpy(aBuf, mBuf + mOffset, toRead); mOffset += toRead; mLen -= toRead; @@ -91,17 +91,17 @@ nsPreloadedStream::ReadSegments(nsWriteS mLen -= didRead; aCount -= didRead; } return NS_OK; } NS_IMETHODIMP -nsPreloadedStream::IsNonBlocking(bool *_retval NS_OUTPARAM) +nsPreloadedStream::IsNonBlocking(bool *_retval) { return mStream->IsNonBlocking(_retval); } NS_IMETHODIMP nsPreloadedStream::CloseWithStatus(nsresult aStatus) { mLen = 0;
--- a/netwerk/base/src/nsSerializationHelper.cpp +++ b/netwerk/base/src/nsSerializationHelper.cpp @@ -72,19 +72,19 @@ NS_DeserializeObject(const nsCSubstring& objstream->SetInputStream(stream); return objstream->ReadObject(true, obj); } NS_IMPL_ISUPPORTS1(nsSerializationHelper, nsISerializationHelper) NS_IMETHODIMP nsSerializationHelper::SerializeToString(nsISerializable *serializable, - nsACString & _retval NS_OUTPARAM) + nsACString & _retval) { return NS_SerializeToString(serializable, _retval); } NS_IMETHODIMP nsSerializationHelper::DeserializeObject(const nsACString & input, - nsISupports **_retval NS_OUTPARAM) + nsISupports **_retval) { return NS_DeserializeObject(input, _retval); }
--- a/netwerk/base/src/nsSocketTransport2.cpp +++ b/netwerk/base/src/nsSocketTransport2.cpp @@ -1920,33 +1920,33 @@ nsSocketTransport::GetSelfAddr(PRNetAddr ReleaseFD_Locked(fd); } return rv; } /* nsINetAddr getScriptablePeerAddr (); */ NS_IMETHODIMP -nsSocketTransport::GetScriptablePeerAddr(nsINetAddr * *addr NS_OUTPARAM) +nsSocketTransport::GetScriptablePeerAddr(nsINetAddr * *addr) { PRNetAddr rawAddr; nsresult rv; rv = GetPeerAddr(&rawAddr); if (NS_FAILED(rv)) return rv; NS_ADDREF(*addr = new nsNetAddr(&rawAddr)); return NS_OK; } /* nsINetAddr getScriptableSelfAddr (); */ NS_IMETHODIMP -nsSocketTransport::GetScriptableSelfAddr(nsINetAddr * *addr NS_OUTPARAM) +nsSocketTransport::GetScriptableSelfAddr(nsINetAddr * *addr) { PRNetAddr rawAddr; nsresult rv; rv = GetSelfAddr(&rawAddr); if (NS_FAILED(rv)) return rv;
--- a/netwerk/protocol/device/AndroidCaptureProvider.cpp +++ b/netwerk/protocol/device/AndroidCaptureProvider.cpp @@ -111,21 +111,21 @@ AndroidCameraInputStream::Available(PRUi return NS_OK; } NS_IMETHODIMP AndroidCameraInputStream::IsNonBlocking(bool *aNonBlock) { *aNonBlock = true; return NS_OK; } -NS_IMETHODIMP AndroidCameraInputStream::Read(char *aBuffer, PRUint32 aCount, PRUint32 *aRead NS_OUTPARAM) { +NS_IMETHODIMP AndroidCameraInputStream::Read(char *aBuffer, PRUint32 aCount, PRUint32 *aRead) { return ReadSegments(NS_CopySegmentToBuffer, aBuffer, aCount, aRead); } -NS_IMETHODIMP AndroidCameraInputStream::ReadSegments(nsWriteSegmentFun aWriter, void *aClosure, PRUint32 aCount, PRUint32 *aRead NS_OUTPARAM) { +NS_IMETHODIMP AndroidCameraInputStream::ReadSegments(nsWriteSegmentFun aWriter, void *aClosure, PRUint32 aCount, PRUint32 *aRead) { *aRead = 0; nsresult rv; if (mAvailable == 0) return NS_BASE_STREAM_WOULD_BLOCK; if (aCount > mAvailable)
--- a/netwerk/protocol/device/GonkCaptureProvider.cpp +++ b/netwerk/protocol/device/GonkCaptureProvider.cpp @@ -402,21 +402,21 @@ GonkCameraInputStream::Available(PRUint3 return NS_OK; } NS_IMETHODIMP GonkCameraInputStream::IsNonBlocking(bool *aNonBlock) { *aNonBlock = true; return NS_OK; } -NS_IMETHODIMP GonkCameraInputStream::Read(char *aBuffer, PRUint32 aCount, PRUint32 *aRead NS_OUTPARAM) { +NS_IMETHODIMP GonkCameraInputStream::Read(char *aBuffer, PRUint32 aCount, PRUint32 *aRead) { return ReadSegments(NS_CopySegmentToBuffer, aBuffer, aCount, aRead); } -NS_IMETHODIMP GonkCameraInputStream::ReadSegments(nsWriteSegmentFun aWriter, void *aClosure, PRUint32 aCount, PRUint32 *aRead NS_OUTPARAM) { +NS_IMETHODIMP GonkCameraInputStream::ReadSegments(nsWriteSegmentFun aWriter, void *aClosure, PRUint32 aCount, PRUint32 *aRead) { *aRead = 0; nsresult rv; if (mAvailable == 0) return NS_BASE_STREAM_WOULD_BLOCK; if (aCount > mAvailable)
--- a/netwerk/protocol/websocket/BaseWebSocketChannel.cpp +++ b/netwerk/protocol/websocket/BaseWebSocketChannel.cpp @@ -151,17 +151,17 @@ BaseWebSocketChannel::GetProtocolFlags(P *aProtocolFlags = URI_NORELATIVE | URI_NON_PERSISTABLE | ALLOWS_PROXY | ALLOWS_PROXY_HTTP | URI_DOES_NOT_RETURN_DATA | URI_DANGEROUS_TO_LOAD; return NS_OK; } NS_IMETHODIMP BaseWebSocketChannel::NewURI(const nsACString & aSpec, const char *aOriginCharset, - nsIURI *aBaseURI, nsIURI **_retval NS_OUTPARAM) + nsIURI *aBaseURI, nsIURI **_retval) { LOG(("BaseWebSocketChannel::NewURI() %p\n", this)); PRInt32 port; nsresult rv = GetDefaultPort(&port); if (NS_FAILED(rv)) return rv; @@ -170,25 +170,25 @@ BaseWebSocketChannel::NewURI(const nsACS aOriginCharset, aBaseURI); if (NS_FAILED(rv)) return rv; NS_ADDREF(*_retval = url); return NS_OK; } NS_IMETHODIMP -BaseWebSocketChannel::NewChannel(nsIURI *aURI, nsIChannel **_retval NS_OUTPARAM) +BaseWebSocketChannel::NewChannel(nsIURI *aURI, nsIChannel **_retval) { LOG(("BaseWebSocketChannel::NewChannel() %p\n", this)); return NS_ERROR_NOT_IMPLEMENTED; } NS_IMETHODIMP BaseWebSocketChannel::AllowPort(PRInt32 port, const char *scheme, - bool *_retval NS_OUTPARAM) + bool *_retval) { LOG(("BaseWebSocketChannel::AllowPort() %p\n", this)); // do not override any blacklisted ports *_retval = false; return NS_OK; }
--- a/netwerk/protocol/websocket/BaseWebSocketChannel.h +++ b/netwerk/protocol/websocket/BaseWebSocketChannel.h @@ -22,17 +22,17 @@ const static PRInt32 kDefaultWSSPort class BaseWebSocketChannel : public nsIWebSocketChannel, public nsIProtocolHandler { public: BaseWebSocketChannel(); NS_DECL_NSIPROTOCOLHANDLER - NS_IMETHOD QueryInterface(const nsIID & uuid, void **result NS_OUTPARAM) = 0; + NS_IMETHOD QueryInterface(const nsIID & uuid, void **result) = 0; NS_IMETHOD_(nsrefcnt ) AddRef(void) = 0; NS_IMETHOD_(nsrefcnt ) Release(void) = 0; // Partial implementation of nsIWebSocketChannel // NS_IMETHOD GetOriginalURI(nsIURI **aOriginalURI); NS_IMETHOD GetURI(nsIURI **aURI); NS_IMETHOD GetNotificationCallbacks(nsIInterfaceRequestor **aNotificationCallbacks);
--- a/netwerk/protocol/websocket/WebSocketChannel.cpp +++ b/netwerk/protocol/websocket/WebSocketChannel.cpp @@ -2217,17 +2217,17 @@ WebSocketChannel::OnLookupComplete(nsICa sWebSocketAdmissions->ConditionallyConnect(this); return NS_OK; } // nsIInterfaceRequestor NS_IMETHODIMP -WebSocketChannel::GetInterface(const nsIID & iid, void **result NS_OUTPARAM) +WebSocketChannel::GetInterface(const nsIID & iid, void **result) { LOG(("WebSocketChannel::GetInterface() %p\n", this)); if (iid.Equals(NS_GET_IID(nsIChannelEventSink))) return QueryInterface(iid, result); if (mCallbacks) return mCallbacks->GetInterface(iid, result);
--- a/netwerk/protocol/websocket/WebSocketChannelParent.cpp +++ b/netwerk/protocol/websocket/WebSocketChannelParent.cpp @@ -216,17 +216,17 @@ WebSocketChannelParent::ActorDestroy(Act mIPCOpen = false; } //----------------------------------------------------------------------------- // WebSocketChannelParent::nsIInterfaceRequestor //----------------------------------------------------------------------------- NS_IMETHODIMP -WebSocketChannelParent::GetInterface(const nsIID & iid, void **result NS_OUTPARAM) +WebSocketChannelParent::GetInterface(const nsIID & iid, void **result) { LOG(("WebSocketChannelParent::GetInterface() %p\n", this)); if (mAuthProvider && iid.Equals(NS_GET_IID(nsIAuthPromptProvider))) return mAuthProvider->GetAuthPrompt(nsIAuthPromptProvider::PROMPT_NORMAL, iid, result); // Only support nsILoadContext if child channel's callbacks did too if (iid.Equals(NS_GET_IID(nsILoadContext)) && !mHaveLoadContext) {
--- a/netwerk/protocol/wyciwyg/WyciwygChannelChild.cpp +++ b/netwerk/protocol/wyciwyg/WyciwygChannelChild.cpp @@ -657,17 +657,17 @@ WyciwygChannelChild::SetCharsetAndSource // TODO ensure that nsWyciwygChannel in the parent has still the cache entry SendSetCharsetAndSource(mCharsetSource, mCharset); return NS_OK; } /* ACString getCharsetAndSource (out long aSource); */ NS_IMETHODIMP -WyciwygChannelChild::GetCharsetAndSource(PRInt32 *aSource NS_OUTPARAM, nsACString & _retval) +WyciwygChannelChild::GetCharsetAndSource(PRInt32 *aSource, nsACString & _retval) { NS_ENSURE_TRUE((mState == WCC_ONSTART) || (mState == WCC_ONDATA) || (mState == WCC_ONSTOP), NS_ERROR_NOT_AVAILABLE); if (mCharsetSource == kCharsetUninitialized) return NS_ERROR_NOT_AVAILABLE;
--- a/security/manager/ssl/src/nsNSSIOLayer.cpp +++ b/security/manager/ssl/src/nsNSSIOLayer.cpp @@ -192,17 +192,17 @@ nsNSSSocketInfo::GetNegotiatedNPN(nsACSt aNegotiatedNPN = mNegotiatedNPN; return NS_OK; } NS_IMETHODIMP nsNSSSocketInfo::JoinConnection(const nsACString & npnProtocol, const nsACString & hostname, PRInt32 port, - bool *_retval NS_OUTPARAM) + bool *_retval) { *_retval = false; // Different ports may not be joined together if (port != GetPort()) return NS_OK; // Make sure NPN has been completed and matches requested npnProtocol
--- a/services/crypto/component/nsSyncJPAKE.cpp +++ b/services/crypto/component/nsSyncJPAKE.cpp @@ -120,22 +120,22 @@ static const char g[] = "4D6063D72AB7A0F08B2F49A7CC6AF335E08C4720E31476B67299E231F8BD90B3" "9AC3AE3BE0C6B6CACEF8289A2E2873D58E51E029CAFBD55E6841489AB66B5B4B" "9BA6E2F784660896AFF387D92844CCB8B69475496DE19DA2E58259B090489AC8" "E62363CDF82CFD8EF2A427ABCD65750B506F56DDE3B988567A88126B914D7828" "E2B63A6D7ED0747EC59E0E0A23CE7D8A74C1D2C2A7AFB6A29799620F00E11C33" "787F7DED3B30E1A22D09F1FBDA1ABBBFBF25CAE05A13F812E34563F99410E73B"; NS_IMETHODIMP nsSyncJPAKE::Round1(const nsACString & aSignerID, - nsACString & aGX1 NS_OUTPARAM, - nsACString & aGV1 NS_OUTPARAM, - nsACString & aR1 NS_OUTPARAM, - nsACString & aGX2 NS_OUTPARAM, - nsACString & aGV2 NS_OUTPARAM, - nsACString & aR2 NS_OUTPARAM) + nsACString & aGX1, + nsACString & aGV1, + nsACString & aR1, + nsACString & aGX2, + nsACString & aGV2, + nsACString & aR2) { NS_ENSURE_STATE(round == JPAKENotStarted); NS_ENSURE_STATE(key == NULL); static CK_MECHANISM_TYPE mechanisms[] = { CKM_NSS_JPAKE_ROUND1_SHA256, CKM_NSS_JPAKE_ROUND2_SHA256, CKM_NSS_JPAKE_FINAL_SHA256 @@ -198,19 +198,19 @@ NS_IMETHODIMP nsSyncJPAKE::Round1(const NS_IMETHODIMP nsSyncJPAKE::Round2(const nsACString & aPeerID, const nsACString & aPIN, const nsACString & aGX3, const nsACString & aGV3, const nsACString & aR3, const nsACString & aGX4, const nsACString & aGV4, const nsACString & aR4, - nsACString & aA NS_OUTPARAM, - nsACString & aGVA NS_OUTPARAM, - nsACString & aRA NS_OUTPARAM) + nsACString & aA, + nsACString & aGVA, + nsACString & aRA) { NS_ENSURE_STATE(round == JPAKEBeforeRound2); NS_ENSURE_STATE(key != NULL); NS_ENSURE_ARG(!aPeerID.IsEmpty()); /* PIN cannot be equal to zero when converted to a bignum. NSS 3.12.9 J-PAKE assumes that the caller has already done this check. Future versions of NSS J-PAKE will do this check internally. See Bug 609068 Comment 4 */ @@ -346,18 +346,18 @@ extractBase64KeyValue(PK11SymKey * keyBl return rv; } NS_IMETHODIMP nsSyncJPAKE::Final(const nsACString & aB, const nsACString & aGVB, const nsACString & aRB, const nsACString & aHKDFInfo, - nsACString & aAES256Key NS_OUTPARAM, - nsACString & aHMAC256Key NS_OUTPARAM) + nsACString & aAES256Key, + nsACString & aHMAC256Key) { static const unsigned AES256_KEY_SIZE = 256 / 8; static const unsigned HMAC_SHA256_KEY_SIZE = 256 / 8; CK_EXTRACT_PARAMS aesBitPosition = 0; CK_EXTRACT_PARAMS hmacBitPosition = aesBitPosition + (AES256_KEY_SIZE * 8); NS_ENSURE_STATE(round == JPAKEAfterRound2); NS_ENSURE_STATE(key != NULL);
--- a/toolkit/crashreporter/nsExceptionHandler.h +++ b/toolkit/crashreporter/nsExceptionHandler.h @@ -73,17 +73,17 @@ nsresult SetSubmitReports(bool aSubmitRe // before the platform-specifi notificationpipe APIs are called. void OOPInit(); // Return true if a dump was found for |childPid|, and return the // path in |dump|. The caller owns the last reference to |dump| if it // is non-NULL. The sequence parameter will be filled with an ordinal // indicating which remote process crashed first. bool TakeMinidumpForChild(PRUint32 childPid, - nsIFile** dump NS_OUTPARAM, + nsIFile** dump, PRUint32* aSequence = NULL); #if defined(XP_WIN) typedef HANDLE ProcessHandle; typedef DWORD ThreadId; #elif defined(XP_MACOSX) typedef task_t ProcessHandle; typedef mach_port_t ThreadId; @@ -104,19 +104,19 @@ ThreadId CurrentThreadId(); // process and |childPid|. Return true on success along with the // minidumps and a new UUID that can be used to correlate the dumps. // // If this function fails, it's the caller's responsibility to clean // up |childDump| and |parentDump|. Either or both can be created and // returned non-null on failure. bool CreatePairedMinidumps(ProcessHandle childPid, ThreadId childBlamedThread, - nsAString* pairGUID NS_OUTPARAM, - nsIFile** childDump NS_OUTPARAM, - nsIFile** parentDump NS_OUTPARAM); + nsAString* pairGUID, + nsIFile** childDump, + nsIFile** parentDump); # if defined(XP_WIN32) || defined(XP_MACOSX) // Parent-side API for children const char* GetChildNotificationPipe(); #ifdef MOZ_CRASHREPORTER_INJECTOR // Inject a crash report client into an arbitrary process, and inform the // callback object when it crashes. Parent process only.
--- a/toolkit/identity/IdentityCryptoService.cpp +++ b/toolkit/identity/IdentityCryptoService.cpp @@ -358,18 +358,18 @@ KeyGenRunnable::KeyGenRunnable(KeyType k : mKeyType(keyType) , mCallback(callback) , mRv(NS_ERROR_NOT_INITIALIZED) { } MOZ_WARN_UNUSED_RESULT nsresult GenerateKeyPair(PK11SlotInfo * slot, - NS_OUTPARAM SECKEYPrivateKey ** privateKey, - NS_OUTPARAM SECKEYPublicKey ** publicKey, + SECKEYPrivateKey ** privateKey, + SECKEYPublicKey ** publicKey, CK_MECHANISM_TYPE mechanism, void * params) { *publicKey = NULL; *privateKey = PK11_GenerateKeyPair(slot, mechanism, params, publicKey, PR_FALSE /*isPerm*/, PR_TRUE /*isSensitive*/, NULL /*&pwdata*/); @@ -386,32 +386,32 @@ GenerateKeyPair(PK11SlotInfo * slot, } return NS_OK; } MOZ_WARN_UNUSED_RESULT nsresult GenerateRSAKeyPair(PK11SlotInfo * slot, - NS_OUTPARAM SECKEYPrivateKey ** privateKey, - NS_OUTPARAM SECKEYPublicKey ** publicKey) + SECKEYPrivateKey ** privateKey, + SECKEYPublicKey ** publicKey) { MOZ_ASSERT(!NS_IsMainThread()); PK11RSAGenParams rsaParams; rsaParams.keySizeInBits = 2048; rsaParams.pe = 0x10001; return GenerateKeyPair(slot, privateKey, publicKey, CKM_RSA_PKCS_KEY_PAIR_GEN, &rsaParams); } MOZ_WARN_UNUSED_RESULT nsresult GenerateDSAKeyPair(PK11SlotInfo * slot, - NS_OUTPARAM SECKEYPrivateKey ** privateKey, - NS_OUTPARAM SECKEYPublicKey ** publicKey) + SECKEYPrivateKey ** privateKey, + SECKEYPublicKey ** publicKey) { MOZ_ASSERT(!NS_IsMainThread()); // XXX: These could probably be static const arrays, but this way we avoid // compiler warnings and also we avoid having to worry much about whether the // functions that take these inputs will (unexpectedly) modify them. // Using NIST parameters. Some other BrowserID components require that these
--- a/uriloader/exthandler/android/nsExternalSharingAppService.cpp +++ b/uriloader/exthandler/android/nsExternalSharingAppService.cpp @@ -36,18 +36,18 @@ nsExternalSharingAppService::ShareWithDe OpenUriExternal(NS_ConvertUTF16toUTF8(data), NS_ConvertUTF16toUTF8(mime), emptyString,emptyString, sendAction, title) ? NS_OK : NS_ERROR_FAILURE; return NS_ERROR_FAILURE; } NS_IMETHODIMP nsExternalSharingAppService::GetSharingApps(const nsAString & aMIMEType, - PRUint32 *aLen NS_OUTPARAM, - nsISharingHandlerApp ***aHandlers NS_OUTPARAM) + PRUint32 *aLen, + nsISharingHandlerApp ***aHandlers) { nsresult rv; NS_NAMED_LITERAL_STRING(sendAction, "android.intent.action.SEND"); nsCOMPtr<nsIMutableArray> array = do_CreateInstance(NS_ARRAY_CONTRACTID, &rv); NS_ENSURE_SUCCESS(rv, rv); NS_ConvertUTF16toUTF8 nMimeType(aMIMEType); if (!AndroidBridge::Bridge()) return NS_OK;
--- a/uriloader/exthandler/unix/nsMeegoExternalSharingAppService.cpp +++ b/uriloader/exthandler/unix/nsMeegoExternalSharingAppService.cpp @@ -39,13 +39,13 @@ nsExternalSharingAppService::ShareWithDe mShareUi->share(QStringList(uri.toString())); return NS_OK; } NS_IMETHODIMP nsExternalSharingAppService::GetSharingApps(const nsAString & aMIMEType, - PRUint32 *aLen NS_OUTPARAM, - nsISharingHandlerApp ***aHandlers NS_OUTPARAM) + PRUint32 *aLen, + nsISharingHandlerApp ***aHandlers) { return NS_ERROR_NOT_IMPLEMENTED; }
--- a/widget/android/AndroidBridge.cpp +++ b/widget/android/AndroidBridge.cpp @@ -2162,17 +2162,17 @@ nsAndroidBridge::nsAndroidBridge() { } nsAndroidBridge::~nsAndroidBridge() { } /* void handleGeckoEvent (in AString message); */ -NS_IMETHODIMP nsAndroidBridge::HandleGeckoMessage(const nsAString & message, nsAString &aRet NS_OUTPARAM) +NS_IMETHODIMP nsAndroidBridge::HandleGeckoMessage(const nsAString & message, nsAString &aRet) { AndroidBridge::Bridge()->HandleGeckoMessage(message, aRet); return NS_OK; } void AndroidBridge::NotifyDefaultPrevented(bool aDefaultPrevented) {
--- a/widget/android/nsClipboard.cpp +++ b/widget/android/nsClipboard.cpp @@ -105,29 +105,29 @@ nsClipboard::EmptyClipboard(PRInt32 aWhi } return NS_OK; } NS_IMETHODIMP nsClipboard::HasDataMatchingFlavors(const char **aFlavorList, PRUint32 aLength, PRInt32 aWhichClipboard, - bool *aHasText NS_OUTPARAM) + bool *aHasText) { *aHasText = false; if (aWhichClipboard != kGlobalClipboard) return NS_ERROR_NOT_IMPLEMENTED; if (XRE_GetProcessType() == GeckoProcessType_Default) { if (AndroidBridge::Bridge()) *aHasText = AndroidBridge::Bridge()->ClipboardHasText(); } else { ContentChild::GetSingleton()->SendClipboardHasText(aHasText); } return NS_OK; } NS_IMETHODIMP -nsClipboard::SupportsSelectionClipboard(bool *aIsSupported NS_OUTPARAM) +nsClipboard::SupportsSelectionClipboard(bool *aIsSupported) { *aIsSupported = false; return NS_OK; }
--- a/widget/android/nsFilePicker.cpp +++ b/widget/android/nsFilePicker.cpp @@ -108,17 +108,17 @@ NS_IMETHODIMP nsFilePicker::GetFileURL(n nsCOMPtr<nsIURI> uri; NS_NewFileURI(getter_AddRefs(uri), file); NS_ENSURE_TRUE(uri, NS_ERROR_FAILURE); return CallQueryInterface(uri, aFileURL); } -NS_IMETHODIMP nsFilePicker::Show(PRInt16 *_retval NS_OUTPARAM) +NS_IMETHODIMP nsFilePicker::Show(PRInt16 *_retval) { if (!mozilla::AndroidBridge::Bridge()) return NS_ERROR_NOT_IMPLEMENTED; nsAutoString filePath; if (mExtensionsFilter.IsEmpty() == mMimeTypeFilter.IsEmpty()) { // Both filters or none of them are set. We want to show anything we can. mozilla::AndroidBridge::Bridge()->ShowFilePickerForMimeType(filePath, NS_LITERAL_STRING("*/*"));
--- a/widget/xpwidgets/GfxInfoBase.cpp +++ b/widget/xpwidgets/GfxInfoBase.cpp @@ -506,17 +506,17 @@ GfxInfoBase::Init() if (os) { os->AddObserver(this, "blocklist-data-gfxItems", true); } return NS_OK; } NS_IMETHODIMP -GfxInfoBase::GetFeatureStatus(PRInt32 aFeature, PRInt32* aStatus NS_OUTPARAM) +GfxInfoBase::GetFeatureStatus(PRInt32 aFeature, PRInt32* aStatus) { if (GetPrefValueForFeature(aFeature, *aStatus)) return NS_OK; nsString version; nsTArray<GfxDriverInfo> driverInfo; return GetFeatureStatusImpl(aFeature, aStatus, version, driverInfo); } @@ -698,33 +698,33 @@ GfxInfoBase::GetFeatureStatusImpl(PRInt3 *aStatus = status; } return NS_OK; } NS_IMETHODIMP GfxInfoBase::GetFeatureSuggestedDriverVersion(PRInt32 aFeature, - nsAString& aVersion NS_OUTPARAM) + nsAString& aVersion) { nsCString version; if (GetPrefValueForDriverVersion(version)) { aVersion = NS_ConvertASCIItoUTF16(version); return NS_OK; } PRInt32 status; nsTArray<GfxDriverInfo> driverInfo; return GetFeatureStatusImpl(aFeature, &status, aVersion, driverInfo); } NS_IMETHODIMP GfxInfoBase::GetWebGLParameter(const nsAString& aParam, - nsAString& aResult NS_OUTPARAM) + nsAString& aResult) { return GfxInfoWebGL::GetWebGLParameter(aParam, aResult); } void GfxInfoBase::EvaluateDownloadedBlacklist(nsTArray<GfxDriverInfo>& aDriverInfo) { PRInt32 features[] = { @@ -788,17 +788,17 @@ GfxInfoBase::LogFailure(const nsACString CrashReporter::AppendAppNotesToCrashReport(failure); #endif } } /* void getFailures ([optional] out unsigned long failureCount, [array, size_is (failureCount), retval] out string failures); */ /* XPConnect method of returning arrays is very ugly. Would not recommend. Fallable nsMemory::Alloc makes things worse */ -NS_IMETHODIMP GfxInfoBase::GetFailures(PRUint32 *failureCount NS_OUTPARAM, char ***failures NS_OUTPARAM) +NS_IMETHODIMP GfxInfoBase::GetFailures(PRUint32 *failureCount, char ***failures) { NS_ENSURE_ARG_POINTER(failureCount); NS_ENSURE_ARG_POINTER(failures); *failures = nsnull; *failureCount = mFailureCount;
--- a/widget/xpwidgets/GfxInfoBase.h +++ b/widget/xpwidgets/GfxInfoBase.h @@ -37,21 +37,21 @@ public: // We only declare a subset of the nsIGfxInfo interface. It's up to derived // classes to implement the rest of the interface. // Derived classes need to use // using GfxInfoBase::GetFeatureStatus; // using GfxInfoBase::GetFeatureSuggestedDriverVersion; // using GfxInfoBase::GetWebGLParameter; // to import the relevant methods into their namespace. - NS_SCRIPTABLE NS_IMETHOD GetFeatureStatus(PRInt32 aFeature, PRInt32 *_retval NS_OUTPARAM); - NS_SCRIPTABLE NS_IMETHOD GetFeatureSuggestedDriverVersion(PRInt32 aFeature, nsAString & _retval NS_OUTPARAM); - NS_SCRIPTABLE NS_IMETHOD GetWebGLParameter(const nsAString & aParam, nsAString & _retval NS_OUTPARAM); + NS_SCRIPTABLE NS_IMETHOD GetFeatureStatus(PRInt32 aFeature, PRInt32 *_retval); + NS_SCRIPTABLE NS_IMETHOD GetFeatureSuggestedDriverVersion(PRInt32 aFeature, nsAString & _retval); + NS_SCRIPTABLE NS_IMETHOD GetWebGLParameter(const nsAString & aParam, nsAString & _retval); - NS_SCRIPTABLE NS_IMETHOD GetFailures(PRUint32 *failureCount NS_OUTPARAM, char ***failures NS_OUTPARAM); + NS_SCRIPTABLE NS_IMETHOD GetFailures(PRUint32 *failureCount, char ***failures); NS_IMETHOD_(void) LogFailure(const nsACString &failure); NS_SCRIPTABLE NS_IMETHOD GetInfo(JSContext*, jsval*); // Initialization function. If you override this, you must call this class's // version of Init first. // We need Init to be called separately from the constructor so we can // register as an observer after all derived classes have been constructed // and we know we have a non-zero refcount.
--- a/xpcom/base/nscore.h +++ b/xpcom/base/nscore.h @@ -442,24 +442,18 @@ typedef PRUint32 nsrefcnt; #define NS_MUST_OVERRIDE #endif /** * Attributes defined to help Dehydra GCC analysis. */ #ifdef NS_STATIC_CHECKING # define NS_SCRIPTABLE __attribute__((user("NS_script"))) -# define NS_INPARAM __attribute__((user("NS_inparam"))) -# define NS_OUTPARAM __attribute__((user("NS_outparam"))) -# define NS_INOUTPARAM __attribute__((user("NS_inoutparam"))) #else # define NS_SCRIPTABLE -# define NS_INPARAM -# define NS_OUTPARAM -# define NS_INOUTPARAM #endif /* * SEH exception macros. */ #ifdef HAVE_SEH_EXCEPTIONS #define MOZ_SEH_TRY __try #define MOZ_SEH_EXCEPT(expr) __except(expr)
--- a/xpcom/ds/nsISupportsArray.idl +++ b/xpcom/ds/nsISupportsArray.idl @@ -31,17 +31,17 @@ class nsISupportsArray; } #define NS_SUPPORTSARRAY_CONTRACTID "@mozilla.org/supports-array;1" #define NS_SUPPORTSARRAY_CLASSNAME "Supports Array" // Enumerator callback function. Return PR_FALSE to stop typedef bool (*nsISupportsArrayEnumFunc)(nsISupports* aElement, void *aData); nsresult -NS_NewArrayEnumerator(nsISimpleEnumerator* *result NS_OUTPARAM, +NS_NewArrayEnumerator(nsISimpleEnumerator* *result, nsISupportsArray* array); %} [scriptable, uuid(791eafa0-b9e6-11d1-8031-006008159b5a)] interface nsISupportsArray : nsICollection { [notxpcom] boolean Equals([const] in nsISupportsArray other);
--- a/xpcom/ds/nsStringEnumerator.cpp +++ b/xpcom/ds/nsStringEnumerator.cpp @@ -142,17 +142,17 @@ nsStringEnumerator::GetNext(nsACString& else aResult = mCArray->ElementAt(mIndex++); return NS_OK; } template<class T> static inline nsresult -StringEnumeratorTail(T** aResult NS_INPARAM) +StringEnumeratorTail(T** aResult) { if (!*aResult) return NS_ERROR_OUT_OF_MEMORY; NS_ADDREF(*aResult); return NS_OK; } //
--- a/xpcom/ds/nsStringEnumerator.h +++ b/xpcom/ds/nsStringEnumerator.h @@ -38,53 +38,53 @@ // array.AppendCString("def"); // NS_NewStringEnumerator(&enumerator, &array, true); // // // call some internal method which iterates the enumerator // InternalMethod(enumerator); // NS_RELEASE(enumerator); // nsresult -NS_NewStringEnumerator(nsIStringEnumerator** aResult NS_OUTPARAM, +NS_NewStringEnumerator(nsIStringEnumerator** aResult, const nsTArray<nsString>* aArray, nsISupports* aOwner); nsresult -NS_NewUTF8StringEnumerator(nsIUTF8StringEnumerator** aResult NS_OUTPARAM, +NS_NewUTF8StringEnumerator(nsIUTF8StringEnumerator** aResult, const nsTArray<nsCString>* aArray); nsresult -NS_NewStringEnumerator(nsIStringEnumerator** aResult NS_OUTPARAM, +NS_NewStringEnumerator(nsIStringEnumerator** aResult, const nsTArray<nsString>* aArray); // Adopting string enumerators assume ownership of the array and will // call |operator delete| on the array when the enumerator is destroyed // this is useful when the provider creates an array solely for the // purpose of creating the enumerator. // For example: // // nsTArray<nsCString>* array = new nsTArray<nsCString>; // array->AppendString("abcd"); // NS_NewAdoptingStringEnumerator(&result, array); nsresult -NS_NewAdoptingStringEnumerator(nsIStringEnumerator** aResult NS_OUTPARAM, +NS_NewAdoptingStringEnumerator(nsIStringEnumerator** aResult, nsTArray<nsString>* aArray); nsresult -NS_NewAdoptingUTF8StringEnumerator(nsIUTF8StringEnumerator** aResult NS_OUTPARAM, +NS_NewAdoptingUTF8StringEnumerator(nsIUTF8StringEnumerator** aResult, nsTArray<nsCString>* aArray); // these versions take a refcounted "owner" which will be addreffed // when the enumerator is created, and destroyed when the enumerator // is released. This allows providers to give non-owning pointers to // ns*StringArray member variables without worrying about lifetime // issues // For example: // // nsresult MyClass::Enumerate(nsIUTF8StringEnumerator** aResult) { // mCategoryList->AppendString("abcd"); // return NS_NewStringEnumerator(aResult, mCategoryList, this); // } // nsresult -NS_NewUTF8StringEnumerator(nsIUTF8StringEnumerator** aResult NS_OUTPARAM, +NS_NewUTF8StringEnumerator(nsIUTF8StringEnumerator** aResult, const nsTArray<nsCString>* aArray, nsISupports* aOwner);
--- a/xpcom/ds/nsVariant.cpp +++ b/xpcom/ds/nsVariant.cpp @@ -223,19 +223,19 @@ static void FreeArray(nsDiscriminatedUni nsMemory::Free((char*)data->u.array.mArrayValue); #undef CASE__FREE_ARRAY_PTR #undef CASE__FREE_ARRAY_IFACE } static nsresult CloneArray(PRUint16 inType, const nsIID* inIID, PRUint32 inCount, void* inValue, - PRUint16* outType NS_OUTPARAM, - nsIID* outIID NS_OUTPARAM, - PRUint32* outCount NS_OUTPARAM, + PRUint16* outType, + nsIID* outIID, + PRUint32* outCount, void** outValue) { NS_ASSERTION(inCount, "bad param"); NS_ASSERTION(inValue, "bad param"); NS_ASSERTION(outType, "bad param"); NS_ASSERTION(outCount, "bad param"); NS_ASSERTION(outValue, "bad param");
--- a/xpcom/ds/nsVariant.h +++ b/xpcom/ds/nsVariant.h @@ -102,29 +102,29 @@ public: static nsresult ConvertToInt64(const nsDiscriminatedUnion& data, PRInt64 *_retval); static nsresult ConvertToUint8(const nsDiscriminatedUnion& data, PRUint8 *_retval); static nsresult ConvertToUint16(const nsDiscriminatedUnion& data, PRUint16 *_retval); static nsresult ConvertToUint32(const nsDiscriminatedUnion& data, PRUint32 *_retval); static nsresult ConvertToUint64(const nsDiscriminatedUnion& data, PRUint64 *_retval); static nsresult ConvertToFloat(const nsDiscriminatedUnion& data, float *_retval); static nsresult ConvertToDouble(const nsDiscriminatedUnion& data, double *_retval); static nsresult ConvertToBool(const nsDiscriminatedUnion& data, bool *_retval); - static nsresult ConvertToChar(const nsDiscriminatedUnion& data, char *_retval NS_OUTPARAM); - static nsresult ConvertToWChar(const nsDiscriminatedUnion& data, PRUnichar *_retval NS_OUTPARAM); - static nsresult ConvertToID(const nsDiscriminatedUnion& data, nsID * _retval NS_OUTPARAM); - static nsresult ConvertToAString(const nsDiscriminatedUnion& data, nsAString & _retval NS_OUTPARAM); + static nsresult ConvertToChar(const nsDiscriminatedUnion& data, char *_retval); + static nsresult ConvertToWChar(const nsDiscriminatedUnion& data, PRUnichar *_retval); + static nsresult ConvertToID(const nsDiscriminatedUnion& data, nsID * _retval); + static nsresult ConvertToAString(const nsDiscriminatedUnion& data, nsAString & _retval); static nsresult ConvertToAUTF8String(const nsDiscriminatedUnion& data, nsAUTF8String & _retval); static nsresult ConvertToACString(const nsDiscriminatedUnion& data, nsACString & _retval); static nsresult ConvertToString(const nsDiscriminatedUnion& data, char **_retval); static nsresult ConvertToWString(const nsDiscriminatedUnion& data, PRUnichar **_retval); static nsresult ConvertToISupports(const nsDiscriminatedUnion& data, nsISupports **_retval); - static nsresult ConvertToInterface(const nsDiscriminatedUnion& data, nsIID * *iid NS_OUTPARAM, void * *iface NS_OUTPARAM); - static nsresult ConvertToArray(const nsDiscriminatedUnion& data, PRUint16 *type NS_OUTPARAM, nsIID* iid NS_OUTPARAM, PRUint32 *count NS_OUTPARAM, void * *ptr); - static nsresult ConvertToStringWithSize(const nsDiscriminatedUnion& data, PRUint32 *size NS_OUTPARAM, char **str); - static nsresult ConvertToWStringWithSize(const nsDiscriminatedUnion& data, PRUint32 *size NS_OUTPARAM, PRUnichar **str); + static nsresult ConvertToInterface(const nsDiscriminatedUnion& data, nsIID * *iid, void * *iface); + static nsresult ConvertToArray(const nsDiscriminatedUnion& data, PRUint16 *type, nsIID* iid, PRUint32 *count, void * *ptr); + static nsresult ConvertToStringWithSize(const nsDiscriminatedUnion& data, PRUint32 *size, char **str); + static nsresult ConvertToWStringWithSize(const nsDiscriminatedUnion& data, PRUint32 *size, PRUnichar **str); static nsresult SetFromVariant(nsDiscriminatedUnion* data, nsIVariant* aValue); static nsresult SetFromInt8(nsDiscriminatedUnion* data, PRUint8 aValue); static nsresult SetFromInt16(nsDiscriminatedUnion* data, PRInt16 aValue); static nsresult SetFromInt32(nsDiscriminatedUnion* data, PRInt32 aValue); static nsresult SetFromInt64(nsDiscriminatedUnion* data, PRInt64 aValue); static nsresult SetFromUint8(nsDiscriminatedUnion* data, PRUint8 aValue);
--- a/xpcom/glue/nsArrayEnumerator.h +++ b/xpcom/glue/nsArrayEnumerator.h @@ -12,20 +12,20 @@ class nsISimpleEnumerator; class nsIArray; class nsCOMArray_base; // Create an enumerator for an existing nsIArray implementation // The enumerator holds an owning reference to the array. NS_COM_GLUE nsresult -NS_NewArrayEnumerator(nsISimpleEnumerator* *result NS_OUTPARAM, +NS_NewArrayEnumerator(nsISimpleEnumerator* *result, nsIArray* array); // create an enumerator for an existing nsCOMArray<T> implementation // The enumerator will hold an owning reference to each ELEMENT in // the array. This means that the nsCOMArray<T> can safely go away // without its objects going away. NS_COM_GLUE nsresult -NS_NewArrayEnumerator(nsISimpleEnumerator* *aResult NS_OUTPARAM, +NS_NewArrayEnumerator(nsISimpleEnumerator* *aResult, const nsCOMArray_base& aArray); #endif
--- a/xpcom/glue/nsBaseHashtable.h +++ b/xpcom/glue/nsBaseHashtable.h @@ -94,17 +94,17 @@ public: * retrieve the value for a key. * @param aKey the key to retreive * @param pData data associated with this key will be placed at this * pointer. If you only need to check if the key exists, pData * may be null. * @return true if the key exists. If key does not exist, pData is not * modified. */ - bool Get(KeyType aKey, UserDataType* pData NS_OUTPARAM) const + bool Get(KeyType aKey, UserDataType* pData) const { EntryType* ent = this->GetEntry(aKey); if (!ent) return false; if (pData) *pData = ent->mData;
--- a/xpcom/glue/nsCOMPtr.h +++ b/xpcom/glue/nsCOMPtr.h @@ -735,17 +735,17 @@ class nsCOMPtr MOZ_FINAL { T* temp = 0; swap(temp); return temp; } template <typename I> void - forget( I** rhs NS_OUTPARAM ) + forget( I** rhs ) // Set the target of rhs to the value of mRawPtr and null out mRawPtr. // Useful to avoid unnecessary AddRef/Release pairs with "out" // parameters where rhs bay be a T** or an I** where I is a base class // of T. { NS_ASSERTION(rhs, "Null pointer passed to forget!"); NSCAP_LOG_RELEASE(this, mRawPtr); *rhs = get(); @@ -1041,17 +1041,17 @@ class nsCOMPtr<nsISupports> // already_AddRefed return values. { nsISupports* temp = 0; swap(temp); return temp; } void - forget( nsISupports** rhs NS_OUTPARAM ) + forget( nsISupports** rhs ) // Set the target of rhs to the value of mRawPtr and null out mRawPtr. // Useful to avoid unnecessary AddRef/Release pairs with "out" // parameters. { NS_ASSERTION(rhs, "Null pointer passed to forget!"); *rhs = 0; swap(*rhs); }
--- a/xpcom/glue/nsIClassInfoImpl.h +++ b/xpcom/glue/nsIClassInfoImpl.h @@ -78,18 +78,18 @@ * as a singleton. */ class NS_COM_GLUE GenericClassInfo : public nsIClassInfo { public: struct ClassInfoData { - typedef NS_CALLBACK(GetInterfacesProc)(PRUint32* NS_OUTPARAM countp, - nsIID*** NS_OUTPARAM array); + typedef NS_CALLBACK(GetInterfacesProc)(PRUint32* countp, + nsIID*** array); typedef NS_CALLBACK(GetLanguageHelperProc)(PRUint32 language, nsISupports** helper); GetInterfacesProc getinterfaces; GetLanguageHelperProc getlanguagehelper; PRUint32 flags; nsCID cid; }; @@ -104,17 +104,17 @@ public: private: const ClassInfoData* mData; }; #define NS_CLASSINFO_NAME(_class) g##_class##_classInfoGlobal #define NS_CI_INTERFACE_GETTER_NAME(_class) _class##_GetInterfacesHelper #define NS_DECL_CI_INTERFACE_GETTER(_class) \ extern NS_IMETHODIMP NS_CI_INTERFACE_GETTER_NAME(_class) \ - (PRUint32 * NS_OUTPARAM, nsIID *** NS_OUTPARAM); + (PRUint32 *, nsIID ***); #define NS_IMPL_CLASSINFO(_class, _getlanguagehelper, _flags, _cid) \ NS_DECL_CI_INTERFACE_GETTER(_class) \ static const GenericClassInfo::ClassInfoData k##_class##ClassInfoData = { \ NS_CI_INTERFACE_GETTER_NAME(_class), \ _getlanguagehelper, \ _flags | nsIClassInfo::SINGLETON_CLASSINFO, \ _cid, \ @@ -127,18 +127,17 @@ private: if (!NS_CLASSINFO_NAME(_class)) \ NS_CLASSINFO_NAME(_class) = new (k##_class##ClassInfoDataPlace) \ GenericClassInfo(&k##_class##ClassInfoData); \ foundInterface = NS_CLASSINFO_NAME(_class); \ } else #define NS_CLASSINFO_HELPER_BEGIN(_class, _c) \ NS_IMETHODIMP \ -NS_CI_INTERFACE_GETTER_NAME(_class)(PRUint32 *count NS_OUTPARAM, \ - nsIID ***array NS_OUTPARAM) \ +NS_CI_INTERFACE_GETTER_NAME(_class)(PRUint32 *count, nsIID ***array) \ { \ *count = _c; \ *array = (nsIID **)nsMemory::Alloc(sizeof (nsIID *) * _c); #define NS_CLASSINFO_HELPER_ENTRY(_i, _interface) \ (*array)[_i] = (nsIID *)nsMemory::Clone(&NS_GET_IID(_interface), \ sizeof(nsIID));
--- a/xpcom/glue/nsInterfaceHashtable.h +++ b/xpcom/glue/nsInterfaceHashtable.h @@ -28,17 +28,17 @@ public: typedef nsBaseHashtable< KeyClass, nsCOMPtr<Interface> , Interface* > base_type; /** * @copydoc nsBaseHashtable::Get * @param pData This is an XPCOM getter, so pData is already_addrefed. * If the key doesn't exist, pData will be set to nsnull. */ - bool Get(KeyType aKey, UserDataType* pData NS_OUTPARAM) const; + bool Get(KeyType aKey, UserDataType* pData) const; /** * @copydoc nsBaseHashtable::Get */ already_AddRefed<Interface> Get(KeyType aKey) const; /** * Gets a weak reference to the hashtable entry. @@ -65,17 +65,17 @@ public: typedef nsBaseHashtableMT< KeyClass, nsCOMPtr<Interface> , Interface* > base_type; /** * @copydoc nsBaseHashtable::Get * @param pData This is an XPCOM getter, so pData is already_addrefed. * If the key doesn't exist, pData will be set to nsnull. */ - bool Get(KeyType aKey, UserDataType* pData NS_OUTPARAM) const; + bool Get(KeyType aKey, UserDataType* pData) const; // GetWeak does not make sense on a multi-threaded hashtable, where another // thread may remove the entry (and hence release it) as soon as GetWeak // returns }; //
--- a/xpcom/glue/nsTArray.h +++ b/xpcom/glue/nsTArray.h @@ -785,17 +785,17 @@ public: // @param comp The Comparator used. // @outparam idx The index of greatest element <= to |item| // @return True iff |item == array[*idx]|. // @precondition The array is sorted template<class Item, class Comparator> bool GreatestIndexLtEq(const Item& item, const Comparator& comp, - index_type* idx NS_OUTPARAM) const { + index_type* idx) const { // Nb: we could replace all the uses of "BinaryIndexOf" with this // function, but BinaryIndexOf will be oh-so-slightly faster so // it's not strictly desired to do. // invariant: low <= [idx] < high index_type low = 0, high = Length(); while (high > low) { index_type mid = (high + low) >> 1;
--- a/xpcom/glue/standalone/nsGlueLinking.h +++ b/xpcom/glue/standalone/nsGlueLinking.h @@ -5,17 +5,17 @@ #ifndef nsGlueLinking_h__ #define nsGlueLinking_h__ #include "nsXPCOMPrivate.h" #define XPCOM_DEPENDENT_LIBS_LIST "dependentlibs.list" NS_HIDDEN_(nsresult) -XPCOMGlueLoad(const char *xpcomFile, GetFrozenFunctionsFunc *func NS_OUTPARAM); +XPCOMGlueLoad(const char *xpcomFile, GetFrozenFunctionsFunc *func); NS_HIDDEN_(void) XPCOMGlueUnload(); typedef void (*DependentLibsCallback)(const char *aDependentLib, bool do_preload); NS_HIDDEN_(void) XPCOMGlueLoadDependentLibs(const char *xpcomDir, DependentLibsCallback cb);
--- a/xpcom/idl-parser/header.py +++ b/xpcom/idl-parser/header.py @@ -46,24 +46,22 @@ def attributeParamlist(a, getter): l = ["%s%s" % (a.realtype.nativeType(getter and 'out' or 'in'), attributeParamName(a))] if a.implicit_jscontext: l.insert(0, "JSContext* cx") return ", ".join(l) def attributeAsNative(a, getter): - scriptable = a.isScriptable() and "NS_SCRIPTABLE " or "" deprecated = a.deprecated and "NS_DEPRECATED " or "" - params = {'scriptable': scriptable, - 'deprecated': deprecated, + params = {'deprecated': deprecated, 'returntype': attributeReturnType(a, 'NS_IMETHOD'), 'binaryname': attributeNativeName(a, getter), 'paramlist': attributeParamlist(a, getter)} - return "%(deprecated)s%(scriptable)s%(returntype)s %(binaryname)s(%(paramlist)s)" % params + return "%(deprecated)s%(returntype)s %(binaryname)s(%(paramlist)s)" % params def methodNativeName(m): return m.binaryname is not None and m.binaryname or firstCap(m.name) def methodReturnType(m, macro): """macro should be NS_IMETHOD or NS_IMETHODIMP""" if m.nostdcall and m.notxpcom: return "%s%s" % (macro == "NS_IMETHOD" and "virtual " or "", @@ -101,24 +99,18 @@ def paramlistAsNative(m, empty='void'): realtype=m.realtype))) if len(l) == 0: return empty return ", ".join(l) def paramAsNative(p): - if p.paramtype == 'in': - typeannotate = '' - else: - typeannotate = ' NS_%sPARAM' % p.paramtype.upper() - - return "%s%s%s" % (p.nativeType(), - p.name, - typeannotate) + return "%s%s" % (p.nativeType(), + p.name) def paramlistNames(m): names = [p.name for p in m.params] if m.implicit_jscontext: names.append('cx') if m.optional_argc:
--- a/xpcom/string/public/nsReadableUtils.h +++ b/xpcom/string/public/nsReadableUtils.h @@ -20,27 +20,27 @@ inline size_t Distance( const nsReadingI { return end.get() - start.get(); } inline size_t Distance( const nsReadingIterator<char>& start, const nsReadingIterator<char>& end ) { return end.get() - start.get(); } -void LossyCopyUTF16toASCII( const nsAString& aSource, nsACString& aDest NS_OUTPARAM ); -void CopyASCIItoUTF16( const nsACString& aSource, nsAString& aDest NS_OUTPARAM ); +void LossyCopyUTF16toASCII( const nsAString& aSource, nsACString& aDest ); +void CopyASCIItoUTF16( const nsACString& aSource, nsAString& aDest ); -void LossyCopyUTF16toASCII( const PRUnichar* aSource, nsACString& aDest NS_OUTPARAM ); -void CopyASCIItoUTF16( const char* aSource, nsAString& aDest NS_OUTPARAM ); +void LossyCopyUTF16toASCII( const PRUnichar* aSource, nsACString& aDest ); +void CopyASCIItoUTF16( const char* aSource, nsAString& aDest ); -void CopyUTF16toUTF8( const nsAString& aSource, nsACString& aDest NS_OUTPARAM ); -void CopyUTF8toUTF16( const nsACString& aSource, nsAString& aDest NS_OUTPARAM ); +void CopyUTF16toUTF8( const nsAString& aSource, nsACString& aDest ); +void CopyUTF8toUTF16( const nsACString& aSource, nsAString& aDest ); -void CopyUTF16toUTF8( const PRUnichar* aSource, nsACString& aDest NS_OUTPARAM ); -void CopyUTF8toUTF16( const char* aSource, nsAString& aDest NS_OUTPARAM ); +void CopyUTF16toUTF8( const PRUnichar* aSource, nsACString& aDest ); +void CopyUTF8toUTF16( const char* aSource, nsAString& aDest ); void LossyAppendUTF16toASCII( const nsAString& aSource, nsACString& aDest ); void AppendASCIItoUTF16( const nsACString& aSource, nsAString& aDest ); void LossyAppendUTF16toASCII( const PRUnichar* aSource, nsACString& aDest ); void AppendASCIItoUTF16( const char* aSource, nsAString& aDest ); void AppendUTF16toUTF8( const nsAString& aSource, nsACString& aDest );
deleted file mode 100644 --- a/xpcom/tests/static-checker/e1.cpp +++ /dev/null @@ -1,9 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult foo(__attribute__((user("outparam"))) int *a) { - int k = 0; - return k; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/e10.cpp +++ /dev/null @@ -1,15 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; -typedef short PRUnichar; - -class nsACString; - -nsresult bar(nsACString &a); -nsresult baz(); - -nsresult foo(nsACString &a) { - bar(a); - return baz(); -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/e11.cpp +++ /dev/null @@ -1,11 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; -typedef short PRUnichar; - -nsresult bar(PRUnichar **a, int q); - -nsresult foo(PRUnichar **a) { - return bar(a, 0); -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/e12.cpp +++ /dev/null @@ -1,10 +0,0 @@ -typedef int bool; -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; -typedef short PRUnichar; - -bool bar(int *p __attribute__((user("NS_outparam")))) { - return 1; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/e13.cpp +++ /dev/null @@ -1,9 +0,0 @@ -typedef int bool; -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; -typedef short PRUnichar; - -void bar(int *p __attribute__((user("NS_outparam")))) { -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/e2.cpp +++ /dev/null @@ -1,9 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult foo(__attribute__((user("outparam"))) int *a) { - *a = 9; - return 1; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/e4.cpp +++ /dev/null @@ -1,11 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult bar(int *a); - -nsresult foo(__attribute__((user("outparam"))) int *a) { - bar(a); - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/e5.cpp +++ /dev/null @@ -1,9 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult foo(__attribute__((user("inoutparam"))) int *a) { - *a = 9; - return 1; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/e6.cpp +++ /dev/null @@ -1,14 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -class A { -}; - -nsresult bar(__attribute__((user("outparam"))) void **a); - -nsresult foo(__attribute__((user("outparam"))) A **a) { - nsresult rv = bar((void **) a); - return 1; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/e7.cpp +++ /dev/null @@ -1,11 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult bar(char **a, int q); - -nsresult foo(char **a) { - bar(a, 0); - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/e8.cpp +++ /dev/null @@ -1,8 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult foo(char **a) { - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/e9.cpp +++ /dev/null @@ -1,9 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; -typedef short PRUnichar; - -nsresult foo(PRUnichar **a) { - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o1.cpp +++ /dev/null @@ -1,9 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult foo(__attribute__((user("outparam"))) int *a) { - *a = 1; - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o10.cpp +++ /dev/null @@ -1,22 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; -typedef short PRUnichar; - -class nsAString { -public: - void Read() const; - void Mutate(); -}; - -nsresult bar(); - -nsresult foo(nsAString &s) { - nsresult rv = bar(); - s.Read(); - if (rv == 0) { - s.Mutate(); - } - return rv; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o11.cpp +++ /dev/null @@ -1,9 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; -typedef short PRUnichar; - -nsresult foo(int *p __attribute__((user("NS_inparam")))) { - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o12.cpp +++ /dev/null @@ -1,22 +0,0 @@ -typedef int bool; -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; -typedef short PRUnichar; - -#define NS_OUTPARAM __attribute__((user("NS_outparam"))) - -bool baz(int *p NS_OUTPARAM); - -bool bar(int *p NS_OUTPARAM) { - return baz(p); -} - -nsresult foo(int *p) { - if (bar(p)) { - return 0; - } else { - return 1; - } -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o13.cpp +++ /dev/null @@ -1,14 +0,0 @@ -typedef int bool; -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; -typedef short PRUnichar; - -nsresult baz(int *p); - -void bar(int *p __attribute__((user("NS_outparam")))) { - if (baz(p) != 0) { - *p = 0; - } -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o14.cpp +++ /dev/null @@ -1,24 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -inline int NS_FAILED(nsresult _nsresult) { - return _nsresult & 0x80000000; -} - -inline int NS_SUCCEEDED(nsresult _nsresult) { - return !(_nsresult & 0x80000000); -} - -int SomeFunc(nsresult *rv); - -nsresult foo(__attribute__((user("NS_outparam"))) int *a) { - nsresult rv; - int i = SomeFunc(&rv); - if (NS_FAILED(rv)) - return rv; - - *a = i; - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o15.cpp +++ /dev/null @@ -1,20 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; -typedef PRUint32 nsresult; - -typedef nsresult (*xpcomFunc)(PRInt32 * __attribute__((user("NS_outparam"))) a, - PRInt32 ** __attribute__((user("NS_outparam"))) b); - -struct A { - virtual nsresult TestMethod(PRInt32 *a __attribute__((user("NS_outparam"))), - PRInt32 **b __attribute__((user("NS_outparam")))); - - struct FuncTable { - xpcomFunc mFunc; - } *mTable; -}; - -nsresult A::TestMethod(PRInt32 *a, PRInt32 **b) -{ - return mTable->mFunc(a, b); -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o16.cpp +++ /dev/null @@ -1,14 +0,0 @@ -typedef int PRInt32; -typedef int nsresult; - -void -OutFunc(PRInt32 *out __attribute__((user("NS_outparam")))) -{ - *out = 0; -} - -nsresult TestFunc(PRInt32 *a __attribute__((user("NS_outparam")))) -{ - OutFunc(a); - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o2.cpp +++ /dev/null @@ -1,15 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -int x; - -nsresult foo(__attribute__((user("outparam"))) int *a) { - if (x) { - *a = 1; - return 0; - } else { - return 1; - } -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o3.cpp +++ /dev/null @@ -1,11 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult foo(nsresult x, __attribute__((user("outparam"))) int *a) { - if (x == 0) { - *a = 1; - } - return x; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o4.cpp +++ /dev/null @@ -1,21 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult bar(__attribute__((user("outparam"))) int q); - -inline int NS_FAILED(nsresult _nsresult) { - return _nsresult & 0x80000000; -} - -inline int NS_SUCCEEDED(nsresult _nsresult) { - return !(_nsresult & 0x80000000); -} - -nsresult foo(__attribute__((user("outparam"))) int *a) { - nsresult rv = bar(4); - if (NS_FAILED(rv)) return rv; - *a = 1; - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o5.cpp +++ /dev/null @@ -1,11 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult bar(__attribute__((user("outparam"))) int *a); - -nsresult foo(__attribute__((user("outparam"))) int *a) { - int rv = bar(a); - return rv; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o6.cpp +++ /dev/null @@ -1,11 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult foo(__attribute__((user("outparam"))) int *a) { - if (a) { - *a = 1; - } - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o7.cpp +++ /dev/null @@ -1,8 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult foo(__attribute__((user("NS_inoutparam"))) int *a) { - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o8.cpp +++ /dev/null @@ -1,8 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult foo(char *a) { - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/o9.cpp +++ /dev/null @@ -1,9 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; -typedef short PRUnichar; - -nsresult foo(PRUnichar *a) { - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/onull.cpp +++ /dev/null @@ -1,15 +0,0 @@ -typedef int PRUint32; -typedef PRUint32 nsresult; - -char *pseudomalloc(); - -nsresult foo(char **result) -{ - *result = pseudomalloc(); - if (!*result) - return 1; - - // fill in *result - - return 0; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/onull2.cpp +++ /dev/null @@ -1,9 +0,0 @@ -typedef int PRUint32; -typedef int PRInt32; - -typedef PRUint32 nsresult; - -nsresult foo(__attribute__((user("outparam"))) int *a) { - *a = 0; - return 1; -}
deleted file mode 100644 --- a/xpcom/tests/static-checker/opmember.cpp +++ /dev/null @@ -1,21 +0,0 @@ -/** - * Make sure treehydra/outparams don't choke on pointer-to-members. - */ - -typedef int PRUint32; -typedef PRUint32 nsresult; - -class A -{ - int i; - int j; -}; - -nsresult -TestMethod(int A::* member, - __attribute__((user("outparam"))) int *out) { - *out = 1; - return 0; -} - -