Re: [PATCH 2/5] streaming.c: remove enum/function/vtbl indirection
- From
Junio C Hamano <gitster@pobox.com>
- Date
- May 6, 2021, 00:14 UTC
- Message-ID
- <xmqqmtt83ehm.fsf@gitster.g>
- In-Reply-To
- <YJKgsfJXMsR47CkW@coredump.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 7 quoted lines
>> We can thus remove the entire enum, and the "open_istream_tbl" virtual >> table that (indirectly) referenced it. > > Yeah, I think this is simpler. The value of the vtable was that we might > have added more functions to it, but we haven't done so over the course > of the last 10 years. And I have trouble imagining for what purpose we > would. So it seems like unnecessary complexity.
The code hasn't changed all that much since it was written, so another equally plausible way forward is not to touch it at all ;-), but I am fine with this simplification, too.