branch: elpa/lua-mode
commit d6c8419543263d157e34dfcd29e1fdeb63027655
Author: immerrr <[email protected]>
Commit: immerrr <[email protected]>

    Fix incorrect error highlighting in 'for x = ...' statements
---
 lua-mode.el | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lua-mode.el b/lua-mode.el
index 050d7e2..1c2f5b5 100644
--- a/lua-mode.el
+++ b/lua-mode.el
@@ -537,7 +537,8 @@ Groups 6-9 can be used in any of argument regexps."
        . font-lock-constant-face)
 
     ("^[ \t]*\\_<for\\_>"
-     (,(lua-make-delimited-matcher "\\_<[[:alpha:]_][[:alnum:]_]*\\_>" "," 
"\\_<in\\_>")
+     (,(lua-make-delimited-matcher "\\_<[[:alpha:]_][[:alnum:]_]*\\_>" ","
+                                   "\\(?:\\_<in\\_>\\|=\\(?:[^=]\\)\\)")
       nil nil
       (1 font-lock-variable-name-face nil noerror)
       (2 font-lock-warning-face t noerror)

Reply via email to