{
int substart = -1;
int subend;
+ int delbackslash = 0;
c = XSTRING (newtext)->data[pos];
if (c == '\\')
subend = search_regs.end[c - '0'];
}
}
+ else if (c == '\\')
+ delbackslash = 1;
}
if (substart >= 0)
{
if (pos - 1 != lastpos + 1)
- middle = Fsubstring (newtext, lastpos + 1, pos - 1);
+ middle = Fsubstring (newtext,
+ make_number (lastpos + 1),
+ make_number (pos - 1));
else
middle = Qnil;
accum = concat3 (accum, middle,
make_number (subend)));
lastpos = pos;
}
+ else if (delbackslash)
+ {
+ middle = Fsubstring (newtext, make_number (lastpos + 1),
+ make_number (pos));
+ accum = concat2 (accum, middle);
+ lastpos = pos;
+ }
}
if (pos != lastpos + 1)
- middle = Fsubstring (newtext, lastpos + 1, pos);
+ middle = Fsubstring (newtext, make_number (lastpos + 1),
+ make_number (pos));
else
middle = Qnil;