1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 10:42:39 +01:00

[gn build] use PEP-8 indents in symbol_exports.py

This commit is contained in:
Nico Weber 2021-05-20 15:00:24 -04:00
parent 56a414f103
commit 8f7f747cf3

View File

@ -25,17 +25,17 @@ def main():
symbols = open(args.source).readlines() symbols = open(args.source).readlines()
if args.format == 'linux': if args.format == 'linux':
output_lines = ['FOO {\n'] output_lines = ['FOO {\n']
if symbols: if symbols:
output_lines += ([' global:\n',] + output_lines += ([' global:\n',] +
[' %s;\n' % s.rstrip() for s in symbols]) [' %s;\n' % s.rstrip() for s in symbols])
output_lines += [' local: *;\n', output_lines += [' local: *;\n',
'}\n'] '}\n']
elif args.format == 'mac': elif args.format == 'mac':
output_lines = ['_' + s for s in symbols] output_lines = ['_' + s for s in symbols]
else: else:
assert args.format == 'win' assert args.format == 'win'
output_lines = ['EXPORTS\n'] + [' ' + s for s in symbols] output_lines = ['EXPORTS\n'] + [' ' + s for s in symbols]
open(args.output, 'w').writelines(output_lines) open(args.output, 'w').writelines(output_lines)