Skip to content

Commit ea4dc39

Browse files
authored
fix: Use built-in bitwise operations under lua 5.4 (#112) (#113)
1 parent a82a9c1 commit ea4dc39

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/luacheck/vendor/sha1/init.lua

+1-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.]]
3939
sha1.version = "0.6.0"
4040

4141
local function choose_ops()
42-
if _VERSION:find("5%.3") then
42+
if tonumber(_VERSION:match"%d+%.%d+") >= 5.3 then
4343
return "lua53_ops"
4444
elseif pcall(require, "bit") then
4545
return "bit_ops"

0 commit comments

Comments
 (0)