projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9bf9f69
)
* lisp/simple.el (goto-line-read-args): More relevant default line number.
author
Juri Linkov
<juri@linkov.net>
Thu, 24 Sep 2020 18:52:22 +0000
(21:52 +0300)
committer
Juri Linkov
<juri@linkov.net>
Thu, 24 Sep 2020 18:52:22 +0000
(21:52 +0300)
lisp/simple.el
patch
|
blob
|
history
diff --git
a/lisp/simple.el
b/lisp/simple.el
index 7cb71530b36a4711696e6a79ff2933bfdd0b550b..6bc41961eba543be9b10f4059bac9f96bc6294b5 100644
(file)
--- a/
lisp/simple.el
+++ b/
lisp/simple.el
@@
-1259,7
+1259,11
@@
that uses or sets the mark."
;; In a narrowed buffer.
(if relative " relative" " absolute"))
buffer-prompt)
- (list default (line-number-at-pos))
+ (list default (if (or relative (= (point-min) 1))
+ (line-number-at-pos)
+ (save-restriction
+ (widen)
+ (line-number-at-pos))))
'goto-line-history)
buffer))))