[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/sweeprolog 0b545cc192 114/166: ADDED: (sweep-indent-line-e
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/sweeprolog 0b545cc192 114/166: ADDED: (sweep-indent-line-ends-with-prefix-operator): New function |
Date: |
Fri, 30 Sep 2022 04:59:30 -0400 (EDT) |
branch: elpa/sweeprolog
commit 0b545cc1920332cf6ad31f49314eabf38e699e23
Author: Eshel Yaron <me@eshelyaron.com>
Commit: Eshel Yaron <me@eshelyaron.com>
ADDED: (sweep-indent-line-ends-with-prefix-operator): New function
(sweep-indent-line-indentation): use it
---
sweep.el | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/sweep.el b/sweep.el
index 914155704f..f3b192942c 100644
--- a/sweep.el
+++ b/sweep.el
@@ -1110,7 +1110,7 @@ Interactively, a prefix arg means to prompt for BUFFER."
((sweep-indent-line-ends-with-else point))
((sweep-indent-line-ends-with-arg point))
((sweep-indent-line-ends-with-neck-p) 4)
- ;; ((sweep-indent-line-ends-with-prefix-operator))
+ ((sweep-indent-line-ends-with-prefix-operator))
(t (sweep-indent-line-fallback))))))
(defun sweep-indent-line-fallback ()
@@ -1120,6 +1120,15 @@ Interactively, a prefix arg means to prompt for BUFFER."
(back-to-indentation)
(current-column)))
+(defun sweep-indent-line-ends-with-prefix-operator ()
+ (save-excursion
+ (end-of-line)
+ (skip-syntax-backward " ")
+ (when-let ((symbol (symbol-at-point)))
+ (when (member (symbol-name symbol) (sweep-prefix-operators))
+ (skip-syntax-backward "w_")
+ (+ (current-column) 4)))))
+
(defun sweep-indent-line-ends-with-if ()
(save-excursion
(end-of-line)
- [nongnu] elpa/sweeprolog 0b054bac88 072/166: ENHANCED: better detection of the identifier at point, (continued)
- [nongnu] elpa/sweeprolog 0b054bac88 072/166: ENHANCED: better detection of the identifier at point, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog c59ead20f7 075/166: ENHANCED: redirect Prolog messages to Emacs message function, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 031c07ac93 076/166: DOC: document the Prolog messages buffer, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 8ac0e7afb9 065/166: ENHANCED: also complete predicate names from xref, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 85ca3a5dc2 067/166: FIXED: bind SourceId in xref based completions, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 21a4475306 112/166: Makefile: Allow specifying the path to emacs, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog ec01154a41 102/166: PORT: sweep.el: require Emacs version 28 for RTLD_GLOBAL, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog e991b1a92c 097/166: ENHANCED: (sweep-load-buffer): use read-buffer to choose a buffer, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog c69c6bad3c 084/166: FIXED: correctly identify the predicate defined at start of clause, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 586521712e 110/166: DOC: README.org: add ^:{} option, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 0b545cc192 114/166: ADDED: (sweep-indent-line-ends-with-prefix-operator): New function,
ELPA Syncer <=
- [nongnu] elpa/sweeprolog c60df8e7e3 101/166: DOC: Loading buffers: new section, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 4c1e510bbf 125/166: FIXED: handle some more color terms, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 588cfb0f63 130/166: BUILD: Inline sweep.h in sweep.c, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 12bddb3f75 117/166: ENHANCED: don't record one-character inputs in the top level history, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog f82827fdb0 093/166: ENHANCED: Display message if unable to find predicate location, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 0f1119fb75 118/166: FIXED: indentation after with inline comments, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog f9218dc461 123/166: PORT: use (eql sweep) instead of (eql 'sweep) in cl-defmethods..., ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 0db900634f 120/166: DOC: update commentary section in sweep.el, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 6f7aa88050 100/166: ENHANCED: (sweep-load-buffer): report results, ELPA Syncer, 2022/09/30
- [nongnu] elpa/sweeprolog 12fbadf13b 137/166: sweep.el: remove outdated sweep--compile-module function, ELPA Syncer, 2022/09/30