Remove trailing whitespace

With `sed -i $(rg -l '[[:blank:]]*$' -g'!thirdparty') -e 's/[[:blank:]]*$//g'`
(+ manual revert of some thirdparty code under `platform/android`).
This commit is contained in:
Rémi Verschelde
2018-11-20 11:14:07 +01:00
parent 5c3422873f
commit 173b342ca7
29 changed files with 124 additions and 124 deletions

View File

@ -87,20 +87,20 @@ def _build_gdnative_api_struct_header(api):
ret_val = []
if core['next']:
ret_val += generate_core_extension_struct(core['next'])
ret_val += [
'typedef struct godot_gdnative_core_' + ('{0}_{1}'.format(core['version']['major'], core['version']['minor'])) + '_api_struct {',
'\tunsigned int type;',
'\tgodot_gdnative_api_version version;',
'\tconst godot_gdnative_api_struct *next;',
]
for funcdef in core['api']:
args = ', '.join(['%s%s' % (_spaced(t), n) for t, n in funcdef['arguments']])
ret_val.append('\t%s(*%s)(%s);' % (_spaced(funcdef['return_type']), funcdef['name'], args))
ret_val += ['} godot_gdnative_core_' + '{0}_{1}'.format(core['version']['major'], core['version']['minor']) + '_api_struct;', '']
return ret_val
@ -171,26 +171,26 @@ def _build_gdnative_api_struct_source(api):
ret_val += ['};\n']
return ret_val
def get_core_struct_definition(core):
ret_val = []
if core['next']:
ret_val += get_core_struct_definition(core['next'])
ret_val += [
'extern const godot_gdnative_core_' + ('{0}_{1}_api_struct api_{0}_{1}'.format(core['version']['major'], core['version']['minor'])) + ' = {',
'\tGDNATIVE_' + core['type'] + ',',
'\t{' + str(core['version']['major']) + ', ' + str(core['version']['minor']) + '},',
'\t' + ('NULL' if not core['next'] else ('(const godot_gdnative_api_struct *)& api_{0}_{1}'.format(core['version']['major'], core['version']['minor']))) + ','
]
for funcdef in core['api']:
ret_val.append('\t%s,' % funcdef['name'])
ret_val += ['};\n']
return ret_val
for ext in api['extensions']:
@ -204,7 +204,7 @@ def _build_gdnative_api_struct_source(api):
out += ['\t(godot_gdnative_api_struct *)&api_extension_' + name + '_struct,']
out += ['};\n']
if api['core']['next']:
out += get_core_struct_definition(api['core']['next'])