Skip to content

Commit 8ab23ac

Browse files
committed
use hyperlinks in go docs
1 parent 316ba86 commit 8ab23ac

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

handlers.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import (
77
"github.com/lainio/err2/internal/handler"
88
)
99

10-
// Stderr is a built-in helper to use with Handle and Catch. It prints the
10+
// Stderr is a built-in helper to use with [Handle] and [Catch]. It prints the
1111
// error to stderr and it resets the current error value. It's a handy Catch
1212
// handler in main function.
1313
//
@@ -51,10 +51,10 @@ func Noop(err error) error { return err }
5151
// defer err2.Handle(&err, err2.Reset)
5252
func Reset(error) error { return nil }
5353

54-
// Err is a built-in helper to use with Handle and Catch. It offers simplifier
54+
// Err is a built-in helper to use with [Handle] and [Catch]. It offers simplifier
5555
// for error handling function for cases where you don't need to change the
5656
// current error value. For instance, if you want to just write error to stdout,
57-
// and don't want to use SetLogTracer and keep it to write to your logs.
57+
// and don't want to use [SetLogTracer] and keep it to write to your logs.
5858
//
5959
// defer err2.Catch(err2.Err(func(err error) {
6060
// fmt.Println("ERROR:", err)
@@ -73,7 +73,7 @@ func Err(f func(err error)) Handler {
7373

7474
const lvl = 10
7575

76-
// Log prints error string to the current log that is set by SetLogTracer.
76+
// Log prints error string to the current log that is set by [SetLogTracer].
7777
func Log(err error) error {
7878
if err == nil {
7979
return nil
@@ -82,7 +82,7 @@ func Log(err error) error {
8282
return err
8383
}
8484

85-
// StderrNoReset is a built-in helper to use with Handle and Catch. It prints
85+
// StderrNoReset is a built-in helper to use with [Handle] and [Catch]. It prints
8686
// the error to stderr. If you need to reset err value use Stderr instead.
8787
//
8888
// You can use it like this:
@@ -97,7 +97,7 @@ func StderrNoReset(err error) error {
9797
return err
9898
}
9999

100-
// StdoutNoReset is a built-in helper to use with Handle and Catch. It prints
100+
// StdoutNoReset is a built-in helper to use with [Handle] and [Catch]. It prints
101101
// the error to stdout.
102102
//
103103
// You can use it like this:

0 commit comments

Comments
 (0)