[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/lua-mode 32b5639 210/468: Fix wrong imenu generic expressi
From: |
Philip Kaludercic |
Subject: |
[nongnu] elpa/lua-mode 32b5639 210/468: Fix wrong imenu generic expression, add one more regexp to match 'x = function(...)' definitions |
Date: |
Thu, 5 Aug 2021 04:58:38 -0400 (EDT) |
branch: elpa/lua-mode
commit 32b56399c82c240c59fbc9a81bf64324fcafad71
Author: immerrr <immerrr+lua@gmail.com>
Commit: immerrr <immerrr+lua@gmail.com>
Fix wrong imenu generic expression, add one more regexp to match 'x =
function(...)' definitions
---
lua-mode.el | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/lua-mode.el b/lua-mode.el
index c97a7f7..4c1a7ff 100644
--- a/lua-mode.el
+++ b/lua-mode.el
@@ -580,9 +580,12 @@ Groups 6-9 can be used in any of argument regexps."
"Default expressions to highlight in Lua mode.")
(defvar lua-imenu-generic-expression
- ;; Very rough expression, but probably it's for the best, since it's used for
- ;; navigation. --immerrr
- '((nil "^[ \t]*\\(?:local[ \t]+\\)?function[ \t]+[[:alnum:]_:.]" 1))
+ ;; This regexp matches expressions which look like function
+ ;; definitions, but are not necessarily allowed by Lua syntax. This
+ ;; is done on purpose to avoid frustration when making a small error
+ ;; might cause a function get hidden from imenu index. --immerrr
+ '((nil "^[ \t]*\\(?:local[ \t]+\\)?function[ \t]+\\([[:alnum:]_:.]+\\)" 1)
+ (nil "^[ \t]*\\(?:local[ \t]+\\)?\\(\\_<[[:alnum:]_:.]+\\_>\\)[ \t]*=\[
\t]*\\_<function\\_>" 1))
"Imenu generic expression for lua-mode. See `imenu-generic-expression'.")
(defvar lua-sexp-alist '(("then" . "end")
- [nongnu] elpa/lua-mode 1c37d0d 114/468: Bump version, (continued)
- [nongnu] elpa/lua-mode 1c37d0d 114/468: Bump version, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode e17a48c 126/468: Give credit to people participated recently, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode dcf5fc1 138/468: Indentation fixes and tidy up., Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 3c8cfe6 160/468: Add credit, reformat new code to fit into 77 cols, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 6b48a94 165/468: Second part of the fix for #34, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 7a3a5f6 169/468: Add script to facilitate indentation testing, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 7f8e519 178/468: Add backward compatibility aliases for cl-assert & cl-labels functions, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode e6a46ee 182/468: Update README.md, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 4b407cc 203/468: Print 'Prefix key set to ...' only when setting via interactive function, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 88b0ec3 209/468: Fix indentation for blocks starting on continued lines, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 32b5639 210/468: Fix wrong imenu generic expression, add one more regexp to match 'x = function(...)' definitions,
Philip Kaludercic <=
- [nongnu] elpa/lua-mode 57d3e46 212/468: lua-mode.el: bump "Version:" field, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode c7c8d0c 179/468: Fix bug with lua-mode-syntax-table initialization, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 0b4ae97 184/468: Merge branch 'fix-36' of git://github.com/vhallac/lua-mode, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 562540e 073/468: Fix lua-calculate-indentation: indent to 0 when inside string literal, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 0f6048d 082/468: Implement lua-mark-all-multiline-literals function, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 96eba74 085/468: lua-(comment/string)-p: add optional pos parameter, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode aef55a6 091/468: Update contact info in README; bump version, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 8c28ed5 095/468: Add utility funcs lua-inside-multiline-p and lua-get-multiline-start, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 79ff5d0 110/468: lua-postprocess-output-buffer: replace save-excursion/set-buffer with with-current-buffer, Philip Kaludercic, 2021/08/05
- [nongnu] elpa/lua-mode 9b929d4 115/468: Reorder operations in release target so that no pushing/sending is done if master differs from remotes/origin/master, Philip Kaludercic, 2021/08/05