Bug 1582567. Stop emitting 'virtual' in codegen if we're already emitting 'override'. r=edgar
authorBoris Zbarsky <bzbarsky@mit.edu>
Fri, 20 Sep 2019 11:05:57 +0000
changeset 494274 63c45794f766d33351e8421241906b053aed5940
parent 494273 4495ef2bbb0cc8ef69ad71620484beee2b5a4582
child 494275 ac5fc1e491a2bb5481d47247bea3c2b22318001c
push id114114
push userdluca@mozilla.com
push dateFri, 20 Sep 2019 22:00:08 +0000
treeherdermozilla-inbound@56e11fddf939 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersedgar
bugs1582567
milestone71.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 1582567. Stop emitting 'virtual' in codegen if we're already emitting 'override'. r=edgar Differential Revision: https://phabricator.services.mozilla.com/D46527
dom/bindings/Codegen.py
--- a/dom/bindings/Codegen.py
+++ b/dom/bindings/Codegen.py
@@ -10829,17 +10829,17 @@ class ClassMethod(ClassItem):
         decorators = []
         if self.canRunScript:
             decorators.append('MOZ_CAN_RUN_SCRIPT')
         if self.inline:
             decorators.append('inline')
         if declaring:
             if self.static:
                 decorators.append('static')
-            if self.virtual:
+            if self.virtual and not self.override:
                 decorators.append('virtual')
         if decorators:
             return ' '.join(decorators) + ' '
         return ''
 
     def getBody(self):
         # Override me or pass a string to constructor
         assert self.body is not None