Generate 'pub' before 'unsafe extern', if both are used.

This commit is contained in:
Ms2ger 2016-07-08 15:15:09 +02:00
parent b5412f3840
commit 1dcdc2859c

View file

@ -2178,13 +2178,13 @@ class CGAbstractMethod(CGThing):
if self.alwaysInline:
decorators.append('#[inline]')
if self.pub:
decorators.append('pub')
if self.extern:
decorators.append('unsafe')
decorators.append('extern')
if self.pub:
decorators.append('pub')
if not decorators:
return ''
return ' '.join(decorators) + ' '