[Mod] improve code quality

This commit is contained in:
vn.py 2019-07-16 12:34:29 +08:00
parent cf7b89365a
commit d1df651b40
2 changed files with 4 additions and 9 deletions

View File

@ -28,13 +28,7 @@ class StructGenerator:
self.f_struct = open(f"{self.prefix}_struct.py", "w")
for line in self.f_cpp:
try:
self.process_line(line)
except:
print("--------------------------")
print(line)
import traceback
traceback.print_exc()
self.f_cpp.close()
self.f_struct.close()
@ -86,5 +80,6 @@ class StructGenerator:
if __name__ == "__main__":
generator = StructGenerator("../include/mini/ThostFtdcUserApiStruct.h", "mini")
generator = StructGenerator(
"../include/mini/ThostFtdcUserApiStruct.h", "mini")
generator.run()