From 655eb65d48bec60d24baf66bf19de394eb2e6aea Mon Sep 17 00:00:00 2001 From: Linus Arver Date: Thu, 2 May 2024 04:54:22 +0000 Subject: interpret-trailers: access trailer_info with new helpers Instead of directly accessing trailer_info members, access them indirectly through new helper functions exposed by the trailer API. This is the first of two preparatory commits which will allow us to use the so-called "pimpl" (pointer to implementation) idiom for the trailer API, by making the trailer_info struct private to the trailer implementation (and thus hidden from the API). Helped-by: Christian Couder Signed-off-by: Linus Arver Signed-off-by: Junio C Hamano --- trailer.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'trailer.h') diff --git a/trailer.h b/trailer.h index 7e36da7d13..9ba9672139 100644 --- a/trailer.h +++ b/trailer.h @@ -97,6 +97,10 @@ void parse_trailers(const struct process_trailer_options *, void trailer_info_get(const struct process_trailer_options *, const char *str, struct trailer_info *); +size_t trailer_block_start(struct trailer_info *); +size_t trailer_block_end(struct trailer_info *); +int blank_line_before_trailer_block(struct trailer_info *); +struct trailer_info *trailer_info_new(void); void trailer_info_release(struct trailer_info *info); -- cgit v1.3-5-g9baa