NewDynamic creates a new error with a dynamic error message and an errno translation. NewDynamic should only be used sparingly and not be used for static error messages. Errors with static error messages should be declared with New as global variables.
(message string, linuxTranslation errno.Errno)
| 71 | // messages. Errors with static error messages should be declared with New as |
| 72 | // global variables. |
| 73 | func NewDynamic(message string, linuxTranslation errno.Errno) *Error { |
| 74 | return &Error{message: message, errno: linuxTranslation} |
| 75 | } |
| 76 | |
| 77 | func newWithHost(message string, linuxTranslation errno.Errno, hostErrno unix.Errno) *Error { |
| 78 | e := New(message, linuxTranslation) |
no outgoing calls
no test coverage detected
searching dependent graphs…