Skip to content

Commit f91f770

Browse files
stop using StringsCache in the PathRewritePlugin
1 parent e67e55b commit f91f770

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/main/java/com/worksap/nlp/sudachi/PathRewritePlugin.java

+4-5
Original file line numberDiff line numberDiff line change
@@ -109,13 +109,12 @@ public LatticeNode concatenate(List<LatticeNodeImpl> path, int begin, int end, L
109109
StringBuilder readingForm = new StringBuilder();
110110
for (int i = begin; i < end; i++) {
111111
LatticeNodeImpl node = path.get(i);
112-
StringsCache sc = node.getStrings();
113-
surface.append(sc.getSurface());
112+
surface.append(node.getSurface());
114113
if (normalizedForm == null) {
115-
normalizedFormBuilder.append(sc.getNormalizedForm());
114+
normalizedFormBuilder.append(node.getNormalizedForm());
116115
}
117-
dictionaryForm.append(sc.getDictionaryForm());
118-
readingForm.append(sc.getReading());
116+
dictionaryForm.append(node.getDictionaryForm());
117+
readingForm.append(node.getReading());
119118
}
120119

121120
LatticeNodeImpl node = LatticeNodeImpl.makeOov(b, e, posId, surface.toString(),

0 commit comments

Comments
 (0)