英文文档: compile(source, filename, mode, flags=0, dont_inherit=False, optimize=-1) Compile the source into a code or AST object. Code objects can be executed by exec() or eval(). source can either be a normal string, a byte string, or an AST object. Ref…