From c4cbd4cb83b7be6259a15af1abe70e5d6ca1b325 Mon Sep 17 00:00:00 2001 From: Hiroyuki Komatsu Date: Thu, 9 Jan 2025 04:24:08 +0000 Subject: [PATCH] Small code refactoring * Removed an unused declaration. * Swapped the argument order of DCHECK_EQ #codehealth PiperOrigin-RevId: 713512608 --- src/converter/converter.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/converter/converter.cc b/src/converter/converter.cc index 527fd2a34..77003b8d7 100644 --- a/src/converter/converter.cc +++ b/src/converter/converter.cc @@ -67,7 +67,6 @@ namespace mozc { namespace { -using ::mozc::prediction::PredictorInterface; using ::mozc::usage_stats::UsageStats; constexpr size_t kErrorIndex = static_cast(-1); @@ -240,8 +239,8 @@ bool Converter::StartPrediction(const ConversionRequest &request, if (ShouldSetKeyForPrediction(key, *segments)) { SetKey(segments, key); } - DCHECK_EQ(1, segments->conversion_segments_size()); - DCHECK_EQ(key, segments->conversion_segment(0).key()); + DCHECK_EQ(segments->conversion_segments_size(), 1); + DCHECK_EQ(segments->conversion_segment(0).key(), key); if (!predictor_->PredictForRequest(request, segments)) { // Prediction can fail for keys like "12". Even in such cases, rewriters