From de2c4beaf50552647273b5eaa33095e90a6d00a0 Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Sun, 24 Apr 2022 15:12:03 +0800 Subject: [PATCH] fix: make escape sequences compatible with Lua 5.1 (#663) Escape sequences starting with `\x` are supported by Lua 5.2 and LuaJIT, but not by Lua 5.1 --- lua/lualine/utils/mode.lua | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lua/lualine/utils/mode.lua b/lua/lualine/utils/mode.lua index e17bdae..60f04a0 100644 --- a/lua/lualine/utils/mode.lua +++ b/lua/lualine/utils/mode.lua @@ -8,7 +8,7 @@ Mode.map = { ['no'] = 'O-PENDING', ['nov'] = 'O-PENDING', ['noV'] = 'O-PENDING', - ['no\x16'] = 'O-PENDING', + ['no\22'] = 'O-PENDING', ['niI'] = 'NORMAL', ['niR'] = 'NORMAL', ['niV'] = 'NORMAL', @@ -17,11 +17,11 @@ Mode.map = { ['vs'] = 'VISUAL', ['V'] = 'V-LINE', ['Vs'] = 'V-LINE', - ['\x16'] = 'V-BLOCK', - ['\x16s'] = 'V-BLOCK', + ['\22'] = 'V-BLOCK', + ['\22s'] = 'V-BLOCK', ['s'] = 'SELECT', ['S'] = 'S-LINE', - ['\x13'] = 'S-BLOCK', + ['\19'] = 'S-BLOCK', ['i'] = 'INSERT', ['ic'] = 'INSERT', ['ix'] = 'INSERT',