Thread (1 message) 1 message, 1 author, 2025-11-19

Re: [PATCH 01/18] streaming: rename `git_istream` into `odb_read_stream`

From: Junio C Hamano <hidden>
Date: 2025-11-19 20:04:59

Justin Tobler [off-list ref] writes:
On 25/11/19 08:47AM, Patrick Steinhardt wrote:
quoted
In the following patches we are about to make the `git_istream` more
generic so that it becomes fully controlled by the specific object
source that wants to create it. As part of these refactorings we'll
fully move the structure into the object database subsystem.
Ok, so looking at the current implementation of `git_istream`, it does
appear to be already defined in a somewhat generic manner as it supports
reading loose/packed objects. What sources are supported are all
centrally defined in "streaming.c" though. It sounds like we eventually
want each source to fully control this interface without having to go
through "streaming.c" to setup each source stream type which makes
sense.
As the original inventor of git_istream abstraction, I fully agree
with this direction.

Thanks for cleaning up, and thanks for reviewing.
quoted
Prepare for this change by renaming the structure from `git_istream`
to `odb_read_stream`. This mirrors the `odb_write_stream` structure that
we already have.

Signed-off-by: Patrick Steinhardt <redacted>
---
diff --git a/streaming.h b/streaming.h
index bd27f59e57..acf4c84338 100644
--- a/streaming.h
+++ b/streaming.h
@@ -7,14 +7,14 @@
 #include "object.h"
 
 /* opaque */
-struct git_istream;
+struct odb_read_stream;
The name change here makes sense. While we are here, it might be nice to
leave a comment annotating it's purpose in a bit more detail.

-Justin
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help