mirror of
https://github.com/vale981/emacs-jupyter
synced 2025-03-05 07:41:37 -05:00
jupyter-completion-symbol-beginning: Allow operator completions
This commit is contained in:
parent
7d824f4915
commit
6c836bd3d8
1 changed files with 7 additions and 1 deletions
|
@ -1595,7 +1595,13 @@ If POS is non-nil return the position of the symbol before POS
|
|||
otherwise return the position of the symbol before point."
|
||||
(save-excursion
|
||||
(and pos (goto-char pos))
|
||||
(+ (point) (skip-syntax-backward "w_."))))
|
||||
(if (and (eq (char-syntax (char-before)) ?.)
|
||||
(not (eq (char-before) ?.)))
|
||||
;; Complete operators, but not the field/attribute
|
||||
;; accessor .
|
||||
(skip-syntax-backward ".")
|
||||
(skip-syntax-backward "w_"))
|
||||
(point)))
|
||||
|
||||
;; Adapted from `company-grab-symbol-cons'
|
||||
(defun jupyter-completion-grab-symbol-cons (re &optional max-len)
|
||||
|
|
Loading…
Add table
Reference in a new issue