回答編集履歴
1
正規表現の表記ミス\(マイナスを先頭へ\)
test
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
```java
|
4
4
|
|
5
|
-
String str = "(?=[\\\\*+.?{}()\\[\\]^&
|
5
|
+
String str = "(?=[-\\\\*+.?{}()\\[\\]^&|\"])";
|
6
6
|
|
7
7
|
i = i.replaceAll(str, "\\\\");
|
8
8
|
|