Bug 1293117 (part 6) - Fix a comment and return type in XPCComponents.cpp. r=froydnj.
authorNicholas Nethercote <nnethercote@mozilla.com>
Tue, 09 Aug 2016 14:03:12 +1000
changeset 309169 05133363f4edf4633ce9ee0dff1ce31f56908c9d
parent 309168 2605dceca7b26e11f3a2c546cf5aaea7d0fb9385
child 309170 32e07e32891d070cdba97e2872cd30265278c0bf
push id31321
push userkwierso@gmail.com
push dateFri, 12 Aug 2016 23:30:18 +0000
treeherderautoland@c385cb6a0838 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersfroydnj
bugs1293117
milestone51.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
Bug 1293117 (part 6) - Fix a comment and return type in XPCComponents.cpp. r=froydnj. The comment is wrong. NS_METHOD is the appropriate thing to use here.
js/xpconnect/src/XPCComponents.cpp
--- a/js/xpconnect/src/XPCComponents.cpp
+++ b/js/xpconnect/src/XPCComponents.cpp
@@ -3498,20 +3498,19 @@ public:
     {
     }
 
     // We don't actually inherit any ref counting infrastructure, but we don't
     // need an nsAutoRefCnt member, so the _INHERITED macro is a hack to avoid
     // having one.
     NS_DECL_ISUPPORTS_INHERITED
     NS_DECL_NSIXPCSCRIPTABLE
-    // The NS_IMETHODIMP isn't really accurate here, but NS_CALLBACK requires
-    // the referent to be declared __stdcall on Windows, and this is the only
-    // macro that does that.
-    static NS_IMETHODIMP Get(nsIXPCScriptable** helper)
+    // This is NS_METHOD because NS_CALLBACK requires the referent to be
+    // declared __stdcall on Windows, and NS_METHOD does that.
+    static NS_METHOD Get(nsIXPCScriptable** helper)
     {
         *helper = &singleton;
         return NS_OK;
     }
 
 private:
     static ComponentsSH singleton;
 };