diff options
| author | 2026-03-29 11:13:33 +0000 | |
|---|---|---|
| committer | 2026-03-29 11:13:33 +0000 | |
| commit | 301bb73dcad265af9c4b1028d7f33863c7b607d0 (patch) | |
| tree | a4ad4af2ca7689e1f5cfbec90c05988d61154a7c /object/type/objecttype.go | |
| parent | object/type, format/packfile: API cleanups (diff) | |
| signature | No signature | |
object/type: Use table structure v0.1.143
Diffstat (limited to 'object/type/objecttype.go')
| -rw-r--r-- | object/type/objecttype.go | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/object/type/objecttype.go b/object/type/objecttype.go deleted file mode 100644 index d803cadf..00000000 --- a/object/type/objecttype.go +++ /dev/null @@ -1,29 +0,0 @@ -// Package objecttype provides Git object type tags and names. -package objecttype - -// Type mirrors Git object type tags in packfiles. -type Type uint8 - -const ( - TypeInvalid Type = 0 - TypeCommit Type = 1 - TypeTree Type = 2 - TypeBlob Type = 3 - TypeTag Type = 4 - TypeFuture Type = 5 - TypeOfsDelta Type = 6 - TypeRefDelta Type = 7 -) - -// IsBaseObject reports whether ty is one of the four canonical Git object -// types encoded directly in pack entries. -func (ty Type) IsBaseObject() bool { - switch ty { - case TypeCommit, TypeTree, TypeBlob, TypeTag: - return true - case TypeInvalid, TypeFuture, TypeOfsDelta, TypeRefDelta: - return false - default: - return false - } -} |
