mirror of
https://github.com/servo/servo.git
synced 2025-07-24 07:40:27 +01:00
Generate 'pub' before 'unsafe extern', if both are used.
This commit is contained in:
parent
b5412f3840
commit
1dcdc2859c
1 changed files with 3 additions and 3 deletions
|
@ -2178,13 +2178,13 @@ class CGAbstractMethod(CGThing):
|
||||||
if self.alwaysInline:
|
if self.alwaysInline:
|
||||||
decorators.append('#[inline]')
|
decorators.append('#[inline]')
|
||||||
|
|
||||||
|
if self.pub:
|
||||||
|
decorators.append('pub')
|
||||||
|
|
||||||
if self.extern:
|
if self.extern:
|
||||||
decorators.append('unsafe')
|
decorators.append('unsafe')
|
||||||
decorators.append('extern')
|
decorators.append('extern')
|
||||||
|
|
||||||
if self.pub:
|
|
||||||
decorators.append('pub')
|
|
||||||
|
|
||||||
if not decorators:
|
if not decorators:
|
||||||
return ''
|
return ''
|
||||||
return ' '.join(decorators) + ' '
|
return ' '.join(decorators) + ' '
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue