[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/drupal-mode bdf3709e10 253/308: Fix bug in drupal/etags-ge
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/drupal-mode bdf3709e10 253/308: Fix bug in drupal/etags-get-function-args |
Date: |
Tue, 25 Jan 2022 10:59:52 -0500 (EST) |
branch: elpa/drupal-mode
commit bdf3709e105d0c97e4b516f52d96c9eb70b665de
Author: joddie <jonxfield@gmail.com>
Commit: joddie <jonxfield@gmail.com>
Fix bug in drupal/etags-get-function-args
With eldoc enabled, this function could move point unexpectedly to the
end of line when point was on the *definition* of anything listed in the
TAGS file. (This is due to the `find-tag-noselect`, which can return the
already-open buffer for a given tag's file, if one exists).
Adding a `save-excursion` around the `with-current-buffer` fixes this bug.
---
drupal/etags.el | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/drupal/etags.el b/drupal/etags.el
index 6c23a7e216..d502b4596c 100644
--- a/drupal/etags.el
+++ b/drupal/etags.el
@@ -47,12 +47,13 @@
"Get function arguments from etags TAGS."
(when (and (boundp 'drupal/etags-rootdir)
(file-exists-p (concat drupal/etags-rootdir "TAGS")))
- (with-current-buffer (find-tag-noselect symbol nil nil)
- (goto-char (point-min))
- (when (re-search-forward
- (format "function\\s-+%s\\s-*(\\([^{]*\\))" symbol)
- nil t)
- (match-string-no-properties 1)))))
+ (save-excursion
+ (with-current-buffer (find-tag-noselect symbol nil nil)
+ (goto-char (point-min))
+ (when (re-search-forward
+ (format "function\\s-+%s\\s-*(\\([^{]*\\))" symbol)
+ nil t)
+ (match-string-no-properties 1))))))
(add-hook 'drupal-mode-hook #'drupal/etags-enable)
- [nongnu] elpa/drupal-mode 5ac9531321 177/308: Added default to run flymake in place., (continued)
- [nongnu] elpa/drupal-mode 5ac9531321 177/308: Added default to run flymake in place., ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode b2ba37e71a 180/308: Bumped version to 0.4.0., ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode 65efa5b78a 186/308: Removed usage of directory local variables., ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode 13b2fff6ef 196/308: Use flycheck-add-next-checker., ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode 507da75f31 212/308: Use `special-mode` for drush php-eval output., ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode 11bfbda293 217/308: Added drupal-mode to dired buffers., ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode ce9d3a564f 215/308: Fixed regexp., ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode 75e1d2dccc 230/308: Require dependency., ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode 20c4d561bc 245/308: Merge branch 'release/0.6.0' into develop, ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode d03a71c891 247/308: Bump version number to 0.6.1., ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode bdf3709e10 253/308: Fix bug in drupal/etags-get-function-args,
ELPA Syncer <=
- [nongnu] elpa/drupal-mode 708f318b12 254/308: Merge pull request #64 from joddie/fix/etags-moves-point, ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode b59ad24b6e 258/308: Merge pull request #66 from joddie/fix/etags-hook-skeleton, ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode 72c533c619 256/308: Remove redundant `require` calls, ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode de52d2757c 260/308: Added Travis CU config., ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode b4a66092bd 263/308: Removed git snapshot from travis ci., ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode e47d7697e6 264/308: Fix drupal-phpcs checker predicate, ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode 9ee19e25a8 269/308: Add autoinsert skeleton for Variable module support, ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode c3f2427b4a 270/308: Fix phpcs output parsing, ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode 2ed0a81398 273/308: Merge branch 'release/0.7.0' into develop, ELPA Syncer, 2022/01/25
- [nongnu] elpa/drupal-mode f604acedb1 272/308: Bump version to 0.7.0, ELPA Syncer, 2022/01/25