mirror of
https://github.com/git/git.git
synced 2026-01-10 01:56:42 +00:00
reftable: add print functions to the record types
This isn't used per se, but it is useful for debugging, especially Windows CI failures. Signed-off-by: Han-Wen Nienhuys <hanwen@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
66c0dabab5
commit
01033de49f
@@ -61,6 +61,9 @@ struct reftable_record_vtable {
|
||||
|
||||
/* Are two records equal? This assumes they have the same type. Returns 0 for non-equal. */
|
||||
int (*equal)(const void *a, const void *b, int hash_size);
|
||||
|
||||
/* Print on stdout, for debugging. */
|
||||
void (*print)(const void *rec, int hash_size);
|
||||
};
|
||||
|
||||
/* returns true for recognized block types. Block start with the block type. */
|
||||
@@ -112,6 +115,7 @@ struct reftable_record {
|
||||
|
||||
/* see struct record_vtable */
|
||||
int reftable_record_equal(struct reftable_record *a, struct reftable_record *b, int hash_size);
|
||||
void reftable_record_print(struct reftable_record *rec, int hash_size);
|
||||
void reftable_record_key(struct reftable_record *rec, struct strbuf *dest);
|
||||
uint8_t reftable_record_type(struct reftable_record *rec);
|
||||
void reftable_record_copy_from(struct reftable_record *rec,
|
||||
|
||||
Reference in New Issue
Block a user