mirror of
https://gitee.com/johng/gf.git
synced 2024-12-04 13:18:01 +08:00
23 lines
274 B
Go
23 lines
274 B
Go
package main
|
|
|
|
import (
|
|
"errors"
|
|
|
|
"github.com/gogf/gf/os/glog"
|
|
|
|
"github.com/gogf/gf/errors/gerror"
|
|
)
|
|
|
|
func Error1() error {
|
|
return errors.New("test1")
|
|
}
|
|
|
|
func Error2() error {
|
|
return gerror.New("test2")
|
|
}
|
|
|
|
func main() {
|
|
glog.Println(Error1())
|
|
glog.Println(Error2())
|
|
}
|