[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: About backslash in regexp
From: |
Eli Zaretskii |
Subject: |
Re: About backslash in regexp |
Date: |
Sat, 16 Mar 2013 10:28:04 +0200 |
> Date: Sat, 16 Mar 2013 10:50:16 +0800
> From: Xue Fuqiao <xfq.free@gmail.com>
>
> I understand that the usual regexp special characters are not special
> inside a character alternative. But in the definition of the function
> `command-line-normalize-file-name':
>
> (defun command-line-normalize-file-name (file)
> [...]
> (string-match "^[A-Za-z]:\\(\\\\[\\\\/]\\)" file) ; C:\/ or C:\\
> [...]
>
> There four backslashes in the `[ ... ]' construct here, why? Aren't
> they duplicated?
It's a bug, now fixed in the development sources. (That entire
function was dead wrong wrt DOS/Windows file names.) Thanks for
catching it.