Additional fix for kill-region-dwim (bug#69097)

* lisp/simple.el (kill-region): Restore the original logic of
raising the error unless both 'beg' and 'end' are non-nil
since 'end' is always non-nil.
This commit is contained in:
Juri Linkov 2024-09-18 20:37:44 +03:00
parent 9026bfb571
commit 03a9919318

View file

@ -5870,7 +5870,7 @@ Supply two arguments, character positions BEG and END indicating the
(cond (cond
((and kill-region-dwim (not (use-region-p))) ((and kill-region-dwim (not (use-region-p)))
(list beg end kill-region-dwim)) (list beg end kill-region-dwim))
((not (or beg end)) ((not (and beg end))
(user-error "The mark is not set now, so there is no region")) (user-error "The mark is not set now, so there is no region"))
((list beg end 'region)))))) ((list beg end 'region))))))