Re: [PATCH v2 13/22] hash-ll.h: split out of hash.h to remove dependency on repository.h

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



"Elijah Newren via GitGitGadget" <gitgitgadget@xxxxxxxxx> writes:

>                                 Move the parts of hash.h that do not
> depend upon repository.h into a new file hash-ll.h (the "low level"
> parts of hash.h), and adjust other files to use this new header where
> the convenience inline functions aren't needed.

Suggestion: To maintain this property, it might be helpful to capture
the rules of hash-ll.h vs hash.h in a top-level comment.

> diff --git a/hash-ll.h b/hash-ll.h
> new file mode 100644
> index 00000000000..80509251370
> --- /dev/null
> +++ b/hash-ll.h
> +const struct object_id *null_oid(void);
> [...]
> +const char *empty_tree_oid_hex(void);
> +const char *empty_blob_oid_hex(void);

hash-ll.h doesn't depend on repository.h, but these functions' bodies
use the_hash_algo. Does it matter?

Moving the functions to hash.h requires changing 8 files to #include
"hash.h", all of which seem to be because they were getting hash-ll.h
indirectly via object-name.h.



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux