Merge pull request #857 from liuml07/patch-1

error() -> Error()
This commit is contained in:
astaxie
2017-06-11 13:27:44 +08:00
committed by GitHub

View File

@@ -226,7 +226,7 @@ Looking back to the example of Box, you will find that Color implements interfac
fmt.Println("The biggest one is", boxes.BiggestsColor().String())
fmt.Println("The biggest one is", boxes.BiggestsColor())
```
Attention: If the type implemented the interface `error`, fmt will call `error()`, so you don't have to implement Stringer at this point.
Attention: If the type implemented the interface `error`, fmt will call `Error()`, so you don't have to implement Stringer at this point.
### Type of variable in an interface