blueloveTH 2023-09-21 21:59:56 +08:00
parent c58672dd23
commit ef6b3db24e
2 changed files with 3 additions and 3 deletions

View File

@ -169,7 +169,7 @@ public:
PyObject* find_name_in_mro(PyObject* cls, StrName name);
bool isinstance(PyObject* obj, Type cls_t);
PyObject* exec(Str source, Str filename, CompileMode mode, PyObject* _module=nullptr);
void exec(Str source);
PyObject* exec(Str source);
PyObject* eval(Str source);
template<typename ...Args>

View File

@ -114,8 +114,8 @@ namespace pkpy{
return nullptr;
}
void VM::exec(Str source){
exec(source, "main.py", EXEC_MODE);
PyObject* VM::exec(Str source){
return exec(source, "main.py", EXEC_MODE);
}
PyObject* VM::eval(Str source){