mirror of
https://github.com/servo/servo.git
synced 2025-06-10 01:23:13 +00:00
More progress in the &JSRef -> JSRef conversion
Change all of the <Class>Methods traits to take `self` instead of `&self`.
This commit is contained in:
parent
2adc594e5d
commit
2c8d51a37c
66 changed files with 812 additions and 815 deletions
|
@ -2186,7 +2186,7 @@ class CGCallGenerator(CGThing):
|
|||
if static:
|
||||
call = CGWrapper(call, pre="%s::" % descriptorProvider.interface.identifier.name)
|
||||
else:
|
||||
call = CGWrapper(call, pre="(*%s)." % object)
|
||||
call = CGWrapper(call, pre="%s." % object)
|
||||
call = CGList([call, CGWrapper(args, pre="(", post=")")])
|
||||
|
||||
self.cgRoot.append(CGList([
|
||||
|
@ -4064,7 +4064,7 @@ class CGInterfaceTrait(CGThing):
|
|||
return "".join(", %s: %s" % argument for argument in arguments)
|
||||
|
||||
methods = CGList([
|
||||
CGGeneric("fn %s(&self%s) -> %s;\n" % (name, fmt(arguments), rettype))
|
||||
CGGeneric("fn %s(self%s) -> %s;\n" % (name, fmt(arguments), rettype))
|
||||
for name, arguments, rettype in members()
|
||||
], "")
|
||||
self.cgRoot = CGWrapper(CGIndenter(methods),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue