summaryrefslogtreecommitdiff
path: root/helm-dabbrev.el
diff options
context:
space:
mode:
authorThierry Volpiatto <thierry.volpiatto@gmail.com>2017-08-18 19:03:05 +0200
committerThierry Volpiatto <thierry.volpiatto@gmail.com>2017-08-18 19:03:05 +0200
commitd79d46776eb9efafde0285c8418ff117f74ea117 (patch)
tree722bd98af0de9655a4e3be67fcf662be8580532c /helm-dabbrev.el
parent5a6b47c86ee6706311b4bd5a119c283177830487 (diff)
Use second arg of thing-at-point
* helm-dabbrev.el (helm-dabbrev--collect): Do it.
Diffstat (limited to 'helm-dabbrev.el')
-rw-r--r--helm-dabbrev.el10
1 files changed, 4 insertions, 6 deletions
diff --git a/helm-dabbrev.el b/helm-dabbrev.el
index 49b80759..bad50e96 100644
--- a/helm-dabbrev.el
+++ b/helm-dabbrev.el
@@ -154,7 +154,7 @@ but the initial search for all candidates in buffer(s)."
(setq pos-before pos)
(search-backward pattern pos t))))
(let* ((replace-regexp (concat "\\(" helm-dabbrev--regexp "\\)\\'"))
- (match-1 (helm-aif (thing-at-point 'symbol)
+ (match-1 (helm-aif (thing-at-point 'symbol t)
;; `thing-at-point' returns
;; the quote outside of e-lisp mode,
;; e.g in message mode,
@@ -163,13 +163,11 @@ but the initial search for all candidates in buffer(s)."
;; `foo' => foo
;; so remove it [1].
(replace-regexp-in-string
- replace-regexp
- "" (substring-no-properties it))))
- (match-2 (helm-aif (thing-at-point 'filename)
+ replace-regexp "" it)))
+ (match-2 (helm-aif (thing-at-point 'filename t)
;; Same as in [1].
(replace-regexp-in-string
- replace-regexp
- "" (substring-no-properties it))))
+ replace-regexp "" it)))
(lst (if (string= match-1 match-2)
(list match-1)
(list match-1 match-2))))