[Mesa-dev] [PATCH 08/27] glapi: gl_enums.py: use main() function for if __name__ == "__main__"
Dylan Baker
baker.dylan.c at gmail.com
Wed May 20 18:03:05 PDT 2015
Signed-off-by: Dylan Baker <dylanx.c.baker at intel.com>
---
src/mapi/glapi/gen/gl_enums.py | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/src/mapi/glapi/gen/gl_enums.py b/src/mapi/glapi/gen/gl_enums.py
index 927a68b..955f27d 100644
--- a/src/mapi/glapi/gen/gl_enums.py
+++ b/src/mapi/glapi/gen/gl_enums.py
@@ -211,9 +211,13 @@ def _parser():
return parser.parse_args()
-if __name__ == '__main__':
+def main():
args = _parser()
api_list = [gl_XML.parse_GL_API(args.input_file)]
printer = PrintGlEnums()
printer.Print(api_list)
+
+
+if __name__ == '__main__':
+ main()
--
2.4.1
More information about the mesa-dev
mailing list