码迷,mamicode.com
首页 > 其他好文 > 详细

go 格言

时间:2015-11-27 17:09:21      阅读:266      评论:0      收藏:0      [点我收藏+]

标签:

转自: http://go-proverbs.github.io/

 

Simple, Poetic, Pithy

Don‘t communicate by sharing memory, share memory by communicating.

Concurrency is not parallelism.

Channels orchestrate; mutexes serialize.

The bigger the interface, the weaker the abstraction.

Make the zero value useful.

interface{} says nothing.

Gofmt‘s style is no one‘s favorite, yet gofmt is everyone‘s favorite.

A little copying is better than a little dependency.

Syscall must always be guarded with build tags.

Cgo must always be guarded with build tags.

Cgo is not Go.

With the unsafe package there are no guarantees.

Clear is better than clever.

Reflection is never clear.

Errors are values.

Don‘t just check errors, handle them gracefully.

Design the architecture, name the components, document the details.

Documentation is for users.

Don‘t panic.

 

 

go 格言

标签:

原文地址:http://www.cnblogs.com/leoncfor/p/5000657.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!