Skip to content

Commit

Permalink
Bug 1419455, part 3 - Remove the unused return value for the upgrade(…
Browse files Browse the repository at this point in the history
…) methods. r=kanru

Also ensure we're more consistent about having two blank lines after these methods.

MozReview-Commit-ID: 2SXXjDuMW4u

--HG--
extra : rebase_source : 05279ceab3aa32d1e577ea02ccd113180bb55792
  • Loading branch information
amccreight committed Nov 21, 2017
1 parent 6501543 commit f69cf04
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions ipc/ipdl/ipdl/lower.py
Original file line number Diff line number Diff line change
Expand Up @@ -738,7 +738,6 @@ class StructDecl(ipdl.ast.StructDecl, HasFQName):
def upgrade(structDecl):
assert isinstance(structDecl, ipdl.ast.StructDecl)
structDecl.__class__ = StructDecl
return structDecl

class _StructField(_CompoundTypeComponent):
def __init__(self, ipdltype, name, sd, side=None):
Expand Down Expand Up @@ -815,7 +814,6 @@ def callType(self, var=None):
def upgrade(unionDecl):
assert isinstance(unionDecl, ipdl.ast.UnionDecl)
unionDecl.__class__ = UnionDecl
return unionDecl


class _UnionMember(_CompoundTypeComponent):
Expand Down Expand Up @@ -1110,7 +1108,7 @@ def upgrade(messageDecl):
messageDecl.decl.type.constructedType()),
'actor'))
messageDecl.__class__ = MessageDecl
return messageDecl


##--------------------------------------------------
def _usesShmem(p):
Expand Down Expand Up @@ -1300,15 +1298,14 @@ def subtreeUsesShmem(self):
def upgrade(protocol):
assert isinstance(protocol, ipdl.ast.Protocol)
protocol.__class__ = Protocol
return protocol


class TranslationUnit(ipdl.ast.TranslationUnit):
@staticmethod
def upgrade(tu):
assert isinstance(tu, ipdl.ast.TranslationUnit)
tu.__class__ = TranslationUnit
return tu


##-----------------------------------------------------------------------------

Expand Down

0 comments on commit f69cf04

Please sign in to comment.