branch: externals/phps-mode commit 777c88da24ccbbced7cd56263e8aac30453765f2 Author: Christian Johansson <christ...@cvj.se> Commit: Christian Johansson <christ...@cvj.se>
Fixed byte-compilation warning --- phps-mode-lexer.el | 53 ++++++++++++++++++++++++++--------------------------- 1 file changed, 26 insertions(+), 27 deletions(-) diff --git a/phps-mode-lexer.el b/phps-mode-lexer.el index 5d79de85fc..3abaa189f7 100644 --- a/phps-mode-lexer.el +++ b/phps-mode-lexer.el @@ -2043,33 +2043,32 @@ (while (< lambda-i lambda-length) (let ((lambd (nth lambda-i lambdas))) - (let ((old-match-length phps-mode-lexer--match-length)) - - (let ((lambda-result - (funcall (nth 0 lambd)))) - (when lambda-result - (let ((match-end (match-end 0)) - (match-beginning (match-beginning 0))) - (let ((matching-length (- match-end match-beginning))) - (when (> matching-length 0) - (when (or - (not phps-mode-lexer--match-length) - (> matching-length phps-mode-lexer--match-length)) - (setq - phps-mode-lexer--match-length matching-length) - (setq - phps-mode-lexer--match-body (nth 1 lambd)) - (setq - phps-mode-lexer--match-data (match-data)) - ;; Debug new matches - (phps-mode-debug-message - (message - "Found new match (%d) %s" - phps-mode-lexer--match-length - phps-mode-lexer--match-body)))))))) - - (when (fboundp 'thread-yield) - (thread-yield)))) + + (let ((lambda-result + (funcall (nth 0 lambd)))) + (when lambda-result + (let ((match-end (match-end 0)) + (match-beginning (match-beginning 0))) + (let ((matching-length (- match-end match-beginning))) + (when (> matching-length 0) + (when (or + (not phps-mode-lexer--match-length) + (> matching-length phps-mode-lexer--match-length)) + (setq + phps-mode-lexer--match-length matching-length) + (setq + phps-mode-lexer--match-body (nth 1 lambd)) + (setq + phps-mode-lexer--match-data (match-data)) + ;; Debug new matches + (phps-mode-debug-message + (message + "Found new match (%d) %s" + phps-mode-lexer--match-length + phps-mode-lexer--match-body)))))))) + + (when (fboundp 'thread-yield) + (thread-yield))) (setq lambda-i (1+ lambda-i))))) ;; Did we find a match?