Oid revamp #68

Merged
carlosmn merged 5 commits from cmn/oid-revamp into master 2014-03-19 01:20:45 -05:00
1 changed files with 1 additions and 5 deletions
Showing only changes of commit c243c31f7d - Show all commits

6
git.go
View File

@ -28,7 +28,7 @@ func init() {
C.git_threads_init() C.git_threads_init()
} }
// Oid // Oid represents the id for a Git object.
type Oid [20]byte type Oid [20]byte
func newOidFromC(coid *C.git_oid) *Oid { func newOidFromC(coid *C.git_oid) *Oid {
@ -72,10 +72,6 @@ func (oid *Oid) String() string {
return string(buf) return string(buf)
} }
func (oid *Oid) Bytes() []byte {
return oid[0:]
}
func (oid *Oid) Cmp(oid2 *Oid) int { func (oid *Oid) Cmp(oid2 *Oid) int {
return bytes.Compare(oid[:], oid2[:]) return bytes.Compare(oid[:], oid2[:])
} }