summaryrefslogtreecommitdiffstats
path: root/src/map.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2020-04-01 19:22:12 +0200
committerBram Moolenaar <Bram@vim.org>2020-04-01 19:22:12 +0200
commit2da0f0c445da3c9b35b2a0cd595d10e81ad2a6f9 (patch)
treede42f08bbd29bad7e82f85da46d4fa546e0304df /src/map.c
parent0afdcf8601792ee751984265b49fc2ca6f8ea858 (diff)
patch 8.2.0491: cannot recognize a <script> mapping using maparg()v8.2.0491
Problem: Cannot recognize a <script> mapping using maparg(). Solution: Add the "script" key. (closes #5873)
Diffstat (limited to 'src/map.c')
-rw-r--r--src/map.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/map.c b/src/map.c
index 948b32cc6c..9bc9abca3a 100644
--- a/src/map.c
+++ b/src/map.c
@@ -2200,6 +2200,8 @@ get_maparg(typval_T *argvars, typval_T *rettv, int exact)
dict_add_string(dict, "lhs", lhs);
dict_add_string(dict, "rhs", mp->m_orig_str);
dict_add_number(dict, "noremap", mp->m_noremap ? 1L : 0L);
+ dict_add_number(dict, "script", mp->m_noremap == REMAP_SCRIPT
+ ? 1L : 0L);
dict_add_number(dict, "expr", mp->m_expr ? 1L : 0L);
dict_add_number(dict, "silent", mp->m_silent ? 1L : 0L);
dict_add_number(dict, "sid", (long)mp->m_script_ctx.sc_sid);