[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/phps-mode e0389c235f 6/8: Using separate error catching
From: |
Christian Johansson |
Subject: |
[elpa] externals/phps-mode e0389c235f 6/8: Using separate error catching for imenu and bookkeeping generation |
Date: |
Wed, 23 Mar 2022 12:27:10 -0400 (EDT) |
branch: externals/phps-mode
commit e0389c235f78ab0e02162b1b222688c5da936616
Author: Christian Johansson <christian@cvj.se>
Commit: Christian Johansson <christian@cvj.se>
Using separate error catching for imenu and bookkeeping generation
---
phps-mode-lex-analyzer.el | 62 ++++++++++++++++++++++++++++++-----------------
1 file changed, 40 insertions(+), 22 deletions(-)
diff --git a/phps-mode-lex-analyzer.el b/phps-mode-lex-analyzer.el
index 6b424677e9..010d4b2098 100644
--- a/phps-mode-lex-analyzer.el
+++ b/phps-mode-lex-analyzer.el
@@ -251,21 +251,30 @@
(setq phps-mode-lex-analyzer--parse-error (nth 8 lex-result))
(setq phps-mode-lex-analyzer--ast (nth 9 lex-result))
- ;; Catch errors in bookkeeping or imenu generation
+ ;; Catch errors in bookkeeping generation
(condition-case conditions
- (progn
- (phps-mode-ast-bookkeeping--generate
- phps-mode-lex-analyzer--ast)
- (phps-mode-ast-imenu--generate
- phps-mode-lex-analyzer--ast))
+ (phps-mode-ast-bookkeeping--generate
+ phps-mode-lex-analyzer--ast)
(error
(display-warning
- 'phps-mode
- (format "Failed to generate bookkeeping or imenu: %S" conditions)
- :warning
- "*PHPs Parser Errors*")))
+ 'phps-mode
+ (format "Failed to generate bookkeeping: %S" conditions)
+ :warning
+ "*PHPs Bookkeeping Generation Errors*")))
+ (setq phps-mode-lex-analyzer--bookkeeping
+ phps-mode-ast-bookkeeping--index)
+
+ ;; Catch errors in imenu generation
+ (condition-case conditions
+ (phps-mode-ast-imenu--generate
+ phps-mode-lex-analyzer--ast)
+ (error
+ (display-warning
+ 'phps-mode
+ (format "Failed to generate imenu: %S" conditions)
+ :warning
+ "*PHPs Imenu Generation Errors*")))
(setq phps-mode-lex-analyzer--imenu phps-mode-ast-imenu--index)
- (setq phps-mode-lex-analyzer--bookkeeping
phps-mode-ast-bookkeeping--index)
(setq phps-mode-lex-analyzer--processed-buffer-p t)
(phps-mode-lex-analyzer--reset-imenu)
@@ -404,21 +413,30 @@
(setq phps-mode-lex-analyzer--parse-error (nth 8 lex-result))
(setq phps-mode-lex-analyzer--ast (nth 9 lex-result))
- ;; Catch errors in bookkeeping or imenu generation
+ ;; Catch errors in bookkeeping generation
(condition-case conditions
- (progn
- (phps-mode-ast-bookkeeping--generate
- phps-mode-lex-analyzer--ast)
- (phps-mode-ast-imenu--generate
- phps-mode-lex-analyzer--ast))
+ (phps-mode-ast-bookkeeping--generate
+ phps-mode-lex-analyzer--ast)
(error
(display-warning
- 'phps-mode
- (format "Failed to generate bookkeeping or imenu: %S" conditions)
- :warning
- "*PHPs Parser Errors*")))
+ 'phps-mode
+ (format "Failed to generate bookkeeping: %S" conditions)
+ :warning
+ "*PHPs Bookkeeping Generation Errors*")))
+ (setq phps-mode-lex-analyzer--bookkeeping
+ phps-mode-ast-bookkeeping--index)
+
+ ;; Catch errors in imenu generation
+ (condition-case conditions
+ (phps-mode-ast-imenu--generate
+ phps-mode-lex-analyzer--ast)
+ (error
+ (display-warning
+ 'phps-mode
+ (format "Failed to generate imenu: %S" conditions)
+ :warning
+ "*PHPs Imenu Generation Errors*")))
(setq phps-mode-lex-analyzer--imenu phps-mode-ast-imenu--index)
- (setq phps-mode-lex-analyzer--bookkeeping
phps-mode-ast-bookkeeping--index)
(phps-mode-debug-message
(message "Incremental tokens: %s" phps-mode-lex-analyzer--tokens))
- [elpa] externals/phps-mode updated (246bcc6967 -> 3a09d15aa1), Christian Johansson, 2022/03/23
- [elpa] externals/phps-mode 3a09d15aa1 8/8: Updated version and changelog, Christian Johansson, 2022/03/23
- [elpa] externals/phps-mode d45658d99c 1/8: Starting experimenting with using two threads for serial commands, Christian Johansson, 2022/03/23
- [elpa] externals/phps-mode 9498a7ae53 7/8: Updated TODOs, Christian Johansson, 2022/03/23
- [elpa] externals/phps-mode b13cf27bf0 5/8: Removed unused variables, Christian Johansson, 2022/03/23
- [elpa] externals/phps-mode fd61209f54 3/8: Got serial multi-threading working with 2 separate threads instead of 1, Christian Johansson, 2022/03/23
- [elpa] externals/phps-mode 2e249e5c24 4/8: Moved bookkeeping and imenu generation to separate thread, Christian Johansson, 2022/03/23
- [elpa] externals/phps-mode e0389c235f 6/8: Using separate error catching for imenu and bookkeeping generation,
Christian Johansson <=
- [elpa] externals/phps-mode d6323a5548 2/8: Moved imenu and bookkeeping to main thread, Christian Johansson, 2022/03/23