[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/phps-mode e50ecb53be 09/17: More debugging byte-compila
From: |
Christian Johansson |
Subject: |
[elpa] externals/phps-mode e50ecb53be 09/17: More debugging byte-compilation issue |
Date: |
Tue, 26 Jul 2022 08:44:19 -0400 (EDT) |
branch: externals/phps-mode
commit e50ecb53bed4dc3f6a419b1e930130f8a1d41d65
Author: Christian Johansson <christian@cvj.se>
Commit: Christian Johansson <christian@cvj.se>
More debugging byte-compilation issue
---
phps-mode-lexer.el | 29 +++++++++++++++++++++++------
phps-mode-macros.el | 2 +-
2 files changed, 24 insertions(+), 7 deletions(-)
diff --git a/phps-mode-lexer.el b/phps-mode-lexer.el
index 918fcd30d9..a5d2184729 100644
--- a/phps-mode-lexer.el
+++ b/phps-mode-lexer.el
@@ -2056,18 +2056,35 @@
(gethash
phps-mode-lexer--state
phps-mode-lexer--lambdas-by-state)))
- (dolist (lambd lambdas)
- (funcall lambd)))
-
- (when (fboundp 'thread-yield)
- (thread-yield))
+ (let ((lambda-i 0)
+ (lambda-length (length lambdas)))
+ (phps-mode-debug-message
+ (message "Found %d lexer rules in state" lambda-length))
+ (while (< lambda-i lambda-length)
+ (let ((lambd (nth lambda-i lambdas)))
+ (let ((old-match-length phps-mode-lexer--match-length))
+ (funcall lambd)
+
+ ;; Debug new matches
+ (phps-mode-debug-message
+ (when (and
+ old-match-length
+ (> phps-mode-lexer--match-length old-match-length))
+ (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?
(if phps-mode-lexer--match-length
(progn
(phps-mode-debug-message
(message
- "Found match %s"
+ "Found final match %s"
phps-mode-lexer--match-body))
(phps-mode-lexer--re2c-execute)
diff --git a/phps-mode-macros.el b/phps-mode-macros.el
index bad8a8a2ca..721401aeda 100644
--- a/phps-mode-macros.el
+++ b/phps-mode-macros.el
@@ -9,7 +9,7 @@
(defconst
phps-mode-macrotime-debug
- nil
+ t
"Debug messages during macro expansion time, default nil.")
(defmacro phps-mode-debug-message (&rest code)
- [elpa] externals/phps-mode updated (69d4de374b -> a56b01bd3f), Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode dd4e6c134f 07/17: Added another unit-test for T_READONLY, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode dbd63046ef 14/17: Fixed T_ENUM token length, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode d766293a8d 04/17: Added support for underscores, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode 585bc28fa5 01/17: Added T_ENUM and T_READONLY, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode 534c766344 03/17: Fixed number constants, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode 3a59ef2141 05/17: Added tests for new lexer tokens, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode b9f74656ad 02/17: Added ONUM regex, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode 4f936cd5cd 06/17: Fixed byte-compilation issue with new lexer rules, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode 3d4576eac6 08/17: Another fix for readonly, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode e50ecb53be 09/17: More debugging byte-compilation issue,
Christian Johansson <=
- [elpa] externals/phps-mode 3f9898cd2a 11/17: Added instructions of how to update lexer rules, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode f070d688a4 13/17: Added TODO items, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode e84ba21c7d 15/17: Updated TODO, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode a56b01bd3f 17/17: Updated version and date, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode e5fda9efb3 10/17: New lexer tokens working after byte-compilation, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode 777c88da24 12/17: Fixed byte-compilation warning, Christian Johansson, 2022/07/26
- [elpa] externals/phps-mode a682f890c1 16/17: Fixed indentation for enumerations, Christian Johansson, 2022/07/26