按照上面的討論,我們定義一個類型: type MyError struct{ errno int msg string } func (e *MyError)Error() string{ return e.msg }.
確定! 回上一頁