From 137c05e802d5e11a5ab54809bc8be8f61ccece21 Mon Sep 17 00:00:00 2001 From: lhchavez Date: Sat, 5 Dec 2020 07:23:44 -0800 Subject: Mark some symbols to be deprecated #minor (#698) This change introduces the file deprecated.go, which contains any constants, functions, and types that are slated to be deprecated in the next major release. These symbols are deprecated because they refer to old spellings in pre-1.0 libgit2. This also makes the build be done with the `-DDEPRECATE_HARD` flag to avoid regressions. This, together with [gorelease](https://godoc.org/golang.org/x/exp/cmd/gorelease)[1] should make releases safer going forward. 1: More information about how that works at https://go.googlesource.com/exp/+/refs/heads/master/apidiff/README.md --- object.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'object.go') diff --git a/object.go b/object.go index 2d75b06..762ad3d 100644 --- a/object.go +++ b/object.go @@ -201,13 +201,13 @@ func (o *Object) Free() { // Peel recursively peels an object until an object of the specified type is met. // -// If the query cannot be satisfied due to the object model, ErrInvalidSpec +// If the query cannot be satisfied due to the object model, ErrorCodeInvalidSpec // will be returned (e.g. trying to peel a blob to a tree). // // If you pass ObjectAny as the target type, then the object will be peeled // until the type changes. A tag will be peeled until the referenced object // is no longer a tag, and a commit will be peeled to a tree. Any other object -// type will return ErrInvalidSpec. +// type will return ErrorCodeInvalidSpec. // // If peeling a tag we discover an object which cannot be peeled to the target // type due to the object model, an error will be returned. -- cgit v1.2.3