-
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathstdlib_go21.go
More file actions
24 lines (21 loc) · 760 Bytes
/
stdlib_go21.go
File metadata and controls
24 lines (21 loc) · 760 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
//go:build go1.21
package errors
import (
stderrors "errors"
)
// ErrUnsupported indicates that a requested operation cannot be performed,
// because it is unsupported. For example, a call to [os.Link] when using a
// file system that does not support hard links.
//
// Functions and methods should not return this error but should instead
// return an error including appropriate context that satisfies
//
// errors.Is(err, errors.ErrUnsupported)
//
// either by directly wrapping ErrUnsupported or by implementing an [Is] method.
//
// Functions and methods should document the cases in which an error
// wrapping this will be returned.
//
// This variable is the same as the standard errors.ErrUnsupported.
var ErrUnsupported = stderrors.ErrUnsupported