Skip to content

Commit 72cf9b2

Browse files
Merge pull request #366 from google:fix_clippy
PiperOrigin-RevId: 606173177
2 parents bbeb3e4 + 9b262fd commit 72cf9b2

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

googletest/src/matcher_support/summarize_diff.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -105,11 +105,11 @@ struct BufferedSummary<'a> {
105105
impl<'a> BufferedSummary<'a> {
106106
// Appends a new line which is common to both actual and expected.
107107
fn feed_common_lines(&mut self, common_line: &'a str) {
108-
if let Buffer::CommonLineBuffer(ref mut common_lines) = self.buffer {
108+
if let Buffer::CommonLines(ref mut common_lines) = self.buffer {
109109
common_lines.push(common_line);
110110
} else {
111111
self.flush_buffer();
112-
self.buffer = Buffer::CommonLineBuffer(vec![common_line]);
112+
self.buffer = Buffer::CommonLines(vec![common_line]);
113113
}
114114
}
115115

@@ -229,7 +229,7 @@ impl<'a> Display for BufferedSummary<'a> {
229229

230230
enum Buffer<'a> {
231231
Empty,
232-
CommonLineBuffer(Vec<&'a str>),
232+
CommonLines(Vec<&'a str>),
233233
ExtraActualLineChunk(&'a str),
234234
ExtraExpectedLineChunk(&'a str),
235235
}
@@ -238,7 +238,7 @@ impl<'a> Buffer<'a> {
238238
fn flush(&mut self, summary: &mut SummaryBuilder) {
239239
match self {
240240
Buffer::Empty => {}
241-
Buffer::CommonLineBuffer(common_lines) => {
241+
Buffer::CommonLines(common_lines) => {
242242
Self::flush_common_lines(std::mem::take(common_lines), summary);
243243
}
244244
Buffer::ExtraActualLineChunk(extra_actual) => {

0 commit comments

Comments
 (0)