1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
*** roctracer-rocm-3.8.0/script/gen_ostream_ops.py.bak 2020-09-26 12:24:46.948120160 +0200
--- roctracer-rocm-3.8.0/script/gen_ostream_ops.py 2020-09-26 12:26:07.037244830 +0200
***************
*** 176,184 ****
process_struct(f, c, cppHeader, "", apiname)
global_str = "\n".join(global_str.split("\n")[0:-2])
if structs_depth != -1: #reindent
! global_str = string.split(global_str, '\n')
! global_str = [' ' + string.lstrip(line) for line in global_str]
! global_str = string.join(global_str, '\n')
f.write(global_str+"\n")
if structs_depth != -1:
f.write(" };\n")
--- 176,184 ----
process_struct(f, c, cppHeader, "", apiname)
global_str = "\n".join(global_str.split("\n")[0:-2])
if structs_depth != -1: #reindent
! global_str = global_str.split('\n')
! global_str = [' ' + line.lstrip() for line in global_str]
! global_str = '\n'.join(global_str)
f.write(global_str+"\n")
if structs_depth != -1:
f.write(" };\n")
***************
*** 199,207 ****
process_struct(f, c, cppHeader, "", apiname)
global_str = "\n".join(global_str.split("\n")[0:-2])
if structs_depth != -1: #reindent
! global_str = string.split(global_str, '\n')
! global_str = [' ' + string.lstrip(line) for line in global_str]
! global_str = string.join(global_str, '\n')
f.write(global_str+"\n")
if structs_depth != -1:
f.write(" };\n")
--- 199,207 ----
process_struct(f, c, cppHeader, "", apiname)
global_str = "\n".join(global_str.split("\n")[0:-2])
if structs_depth != -1: #reindent
! global_str = global_str.split('\n')
! global_str = [' ' + line.lstrip() for line in global_str]
! global_str = '\n'.join(global_str)
f.write(global_str+"\n")
if structs_depth != -1:
f.write(" };\n")
|