[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Regular expression grouping not working?

From: Teemu Likonen
Subject: Re: Regular expression grouping not working?
Date: Sat, 08 Feb 2020 21:30:15 +0200

Douglas Lewan [2020-02-08T14:17:54-05] wrote:

> I'm writing some code that includes the regular expression \\([^/]+/\\), 
> (looking for a path on GNU/Linux) which doesn't match what I expect it 
> should.

Maybe your backslash escaping is wrong. In regular expressions the
grouping is made with \( \) but within Lisp strings backslash has a
special meaning too and those must be escaped "\\( \\)".

> Is there something I'm missing?

I think we need more information about your code and input data.

///  OpenPGP key: 4E1055DC84E9DFF613D78557719D69D324539450

Attachment: signature.asc
Description: PGP signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]