view util/xpcall.lua @ 10847:42c8dce6e765

net.server_epoll: Fix typo in internal method name
author Kim Alvefur <zash@zash.se>
date Fri, 22 May 2020 15:36:03 +0200
parents cfc7b2f7251e
children d10957394a3c
line wrap: on
line source

local xpcall = xpcall;

if select(2, xpcall(function (x) return x end, function () end,  "test")) ~= "test" then
	xpcall = require"util.compat".xpcall;
end

return {
	xpcall = xpcall;
};