From 52bfb0c4a3885c165bf62bd0e4023f4a14b6624b Mon Sep 17 00:00:00 2001 From: Martin Huschenbett Date: Wed, 20 Dec 2023 16:40:26 +0100 Subject: [PATCH] Fix a comment in the protobuf example (#1604) In https://github.com/google/comprehensive-rust/pull/1591, I changed the implementation of the protobuf example significantly. However, I forgot to update a comment which is referred to the old style of implementation. I'll this slip here. --- src/slices-and-lifetimes/exercise.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/slices-and-lifetimes/exercise.rs b/src/slices-and-lifetimes/exercise.rs index 6a59f8c5..8f9165f0 100644 --- a/src/slices-and-lifetimes/exercise.rs +++ b/src/slices-and-lifetimes/exercise.rs @@ -172,7 +172,8 @@ fn parse_field(data: &[u8]) -> Result<(Field, &[u8]), Error> { } // ANCHOR: parse_message -/// Parse a message in the given data, calling `field_callback` for each field in the message. +/// Parse a message in the given data, calling `T::add_field` for each field in +/// the message. /// /// The entire input is consumed. fn parse_message<'a, T: ProtoMessage<'a>>(mut data: &'a [u8]) -> Result {