diff options
author | David Aspinall <da@inf.ed.ac.uk> | 2010-08-03 23:20:15 +0000 |
---|---|---|
committer | David Aspinall <da@inf.ed.ac.uk> | 2010-08-03 23:20:15 +0000 |
commit | 6c0e1ea185777f40a141231c11bef1dfc272c387 (patch) | |
tree | 1d4e198d75dfe465a8fe57c1166db75f6778aed2 /generic/proof-script.el | |
parent | 35f05f9f85e02ff7f03f73d884983289c5f4bebb (diff) |
proof-assert-electric-terminator: fix logic for inserting at buffer end
Diffstat (limited to 'generic/proof-script.el')
-rw-r--r-- | generic/proof-script.el | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/generic/proof-script.el b/generic/proof-script.el index ff205826..3db7bfde 100644 --- a/generic/proof-script.el +++ b/generic/proof-script.el @@ -1877,11 +1877,11 @@ comment, and insert or skip to the next semi)." (if (proof-only-whitespace-to-locked-region-p) (error "There's nothing to do!")) (skip-chars-backward " \t\n") - (if (and (char-after (point)) - (not (= (char-after (point)) proof-terminal-char))) - (unless proof-electric-terminator-noterminator - (insert proof-terminal-string) - (setq ins t))) + (unless (or proof-electric-terminator-noterminator + (and (char-after (point)) + (= (char-after (point)) proof-terminal-char))) + (insert proof-terminal-string) + (setq ins t)) (let* ((pos (if proof-electric-terminator-noterminator (1- (point)) (point))) (semis |