From 942c805b8427e3b4b9586e27702eeceacf967549 Mon Sep 17 00:00:00 2001 From: Folke Lemaitre Date: Wed, 15 Mar 2023 08:53:19 +0100 Subject: [PATCH] fix(cache): remove dependency on jit --- lua/lazy/core/cache.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lua/lazy/core/cache.lua b/lua/lazy/core/cache.lua index 522b2ac..fac7262 100644 --- a/lua/lazy/core/cache.lua +++ b/lua/lazy/core/cache.lua @@ -170,7 +170,8 @@ end ---@private function Cache.loader_lib(modname) local start = uv.hrtime() - local modpath = M.find(modname, { patterns = jit.os:find("Windows") and { ".dll" } or { ".so" } }) + local is_win = uv.os_uname().sysname:lower():find("win", 1, true) + local modpath = M.find(modname, { patterns = is_win and { ".dll" } or { ".so" } }) ---@type function?, string? if modpath then -- Making function name in Lua 5.1 (see src/loadlib.c:mkfuncname) is