diff options
author | Alex Orlenko <zxteam@protonmail.com> | 2023-06-04 02:31:29 +0100 |
---|---|---|
committer | Alex Orlenko <zxteam@protonmail.com> | 2023-06-04 02:31:29 +0100 |
commit | 8ab0ccf11cfbc4bd6e052fc1ff49e73ee4bd1f4c (patch) | |
tree | cb94d04b84e4a01f653d0c94e3f9f7c24df24fe8 /src/lua.rs | |
parent | 9596f2e9ee66d8f11c599d1465d92a6695c69bd3 (diff) | |
download | mlua-8ab0ccf11cfbc4bd6e052fc1ff49e73ee4bd1f4c.zip |
Don't keep poll function in environment globals when polling async functions.
This is redundant after deprecating scoped async.
Closes #281
Diffstat (limited to 'src/lua.rs')
-rw-r--r-- | src/lua.rs | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -2845,11 +2845,10 @@ impl Lua { LightUserData(&ASYNC_POLL_PENDING as *const u8 as *mut c_void) })?; - // We set `poll` variable in the env table to be able to destroy upvalues self.load( r#" - poll = get_poll(...) - local poll, pending, yield, unpack = poll, pending, yield, unpack + local poll = get_poll(...) + local pending, yield, unpack = pending, yield, unpack while true do local ready, res, nres = poll() if ready then |