skip -rfu, have to escape backlashes even inside quotes

Kim Kuparinen via Gdb <[email protected]>
Newsgroups gmane.comp.gdb.devel
Message-ID <CABD-7MwAy-q_3QagCE=DD-11D+T6tbHnPVjXO0oBaSn28Yo6og@mail.gmail.com>
Hi, first time using a mailing list, sorry if I mess something up.

I noticed that when trying to use skip -rfu REGEX, I had to escape
backslashes even if I quoted the regex. So

skip -rfu '\('

errors out with

regexp: umatched ( or \(

I dug around a bit and found out that the issue seems to be in
libiberty/argv.c, in the function buildargv(). The function seems to always
strip backslashes, because in the if/else if/else chain, the backslash
character is checked(and as such, removed) before squote or dquote. I got
gdb to do what I wanted to by moving the check for a backslash behind the
checks for squote and dquote.

That being said, is this intended behaviour? Seems sort of counter
intuitive.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.