Yes... by the time the regex compiler sees the pattern you've given it, it sees only a single backslash (since Java's lexer has turned the double backwhack into a single one). You need to replace "\\\\"
with "\\\\"
, believe it or not! Java really needs a good raw string syntax.