Subject: bug#6073: 23.1.50; delete-selection-mode

From: "Drew Adams" <[email-masked]>
Date: Sat, 1 May 2010 13:07:05 -0700

> I found a reproducible test case for the painful result I mentioned
> before with C-u C-y in Delete Selection mode.
> 
> This Emacs is somewhat old; I have not built a newer one.
> I will try to do so soon.
> 
> I visit the text between the ---- lines (not including them)
> in Fundamental mode, do M-x delete-selection-mode RET to enable it,
> then I go to the blank line after the first paragraph and type
> C-SPC C-u C-n M-w C-x C-x C-u C-y
> and the text does not change.  Apparently C-u C-y deletes
> the region before yanking.
> 
> ----------------------------------------------------------------------
> 
> * ACTA must respect sharing and cooperation: it must do nothing that
>   would hinder the unremunerated noncommercial making, copying,
>   giving, lending, owning, using, transporting, importing or exporting
>   of any objects or works.
> 
> * ACTA must not weasel about what is commercial: no labeling of any
>   noncommercial activities as somehow commercial-like or treating them
>   as if they were commercial.
> 
> * ACTA must not tighten digital handcuffs: it must not hinder any
>   activity in regard to any product on account of its capacity to
>   circumvent technical measures that restrict use of copies of works
>   of authorship.
> ----------------------------------------------------------------------

You probably already know this, but in case you do not: C-x C-x activates the
region. Since it is active, your yank replaces the region text.

If you do C-g after C-x C-x I think you will get the behavior you expected.