*highlight: Fix lack of (#m) flag (for $MATCH), result of regex->pattern

This commit is contained in:
Sebastian Gniazdowski 2016-10-15 12:53:02 +02:00
parent 6c9e1f83cc
commit a051f6a6cb

View file

@ -399,7 +399,7 @@ typeset -gA HSMW_HIGHLIGHT_STYLES
local -a match mbegin mend
local MATCH; integer MBEGIN MEND
if [[ $res == none ]] && (( ${+parameters} )) &&
[[ ${arg[1]} == \$ ]] && [[ ${arg:1} = ([[:alpha:]_][[:alnum:]_]#|[[:digit:]]##) ]] &&
[[ ${arg[1]} == \$ ]] && [[ ${arg:1} = (#m)([[:alpha:]_][[:alnum:]_]#|[[:digit:]]##) ]] &&
(( ${+parameters[${MATCH}]} ))
then
-hsmw-highlight-main-type ${(P)MATCH}