[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Sending multiple patches
From: |
Michal Nazarewicz |
Subject: |
Re: Sending multiple patches |
Date: |
Tue, 03 Jun 2014 08:28:13 +0200 |
User-agent: |
Notmuch/0.17+15~gb65ca8e (http://notmuchmail.org) Emacs/24.4.50.1 (x86_64-unknown-linux-gnu) |
>> The simplest would probably be to change the entity to numeric one even
>> in HTML, but I'm not sure if users would like it.
On Mon, Jun 02 2014, Stefan Monnier wrote:
> Indeed, I for one would be very disappointed to see   instead of
> there. Of course, I'd even prefer seeing " ".
Agreed, but that could create encoding issues for some users, therefore
I think it's better to leave it as entity reference and let users change
it to the non-break space character themselves.
>> I started implementing this which is when I realised that "end-\\1"
>> won't cut it because contents of the matched capture group must be
>> escaped with `regexp-quote'. For example, if we had:
On Mon, Jun 02 2014, Stefan Monnier wrote:
> AFAICT, you can regexp-quote the whole result.
Unfortunately that is not the case. For example, imagine a hypothetical
language where comments can be written as “<!-- … -->” or “<!== … ==>”
with optional spaces like in HTML. Regex pair to match it would be:
("<! *\\(--\\|==\\)" . (1 " *>"))
If the code was changed so that the whole end-pattern is regexp-quote'd,
the asterisk would get escaped.
>> Good idea. Do you think it'd be acceptable to completely drop support
>> for “("end-" 1)” and change the meaning of strings to be processed by
>> `replace-mach'?
> For the major-mode-set buffer-local variable, there'd be no backward
> compatibility issue, of course.
Let's leave it as is for now then, and bundle both changes together in
some way.
Do you think that adding Perl's \Q…\E support to `replace-match' would
make sense? For instance, we could than have:
("verb\\(.\\)" . "\\E\\1\\Q")
Or is tildify.el to small of a user to justify fiddling with
`replace-match'?
--
Best regards, _ _
.o. | Liege of Serenely Enlightened Majesty of o' \,=./ `o
..o | Computer Science, Michał “mina86” Nazarewicz (o o)
ooo +--<address@hidden>--<xmpp:address@hidden>--ooO--(_)--Ooo--
Re: Sending multiple patches, Michal Nazarewicz, 2014/06/02