This commit is contained in:
Unknown
2013-04-20 22:37:57 -04:00
parent d635e0e159
commit cc923f2375

View File

@@ -61,8 +61,6 @@
c = iota
)
The first use of iota gives 0, whenever iota is used again on a new line, its value is incremented by 1; so a=0, b=1, c=2. This can be shortened to:
第一个 `iota` 等于 0每当 `iota` 在新的一行被使用时,它的值都会自动加 1所以 `a=0, b=1, c=2` 可以简写为如下形式:
const (
@@ -102,8 +100,6 @@ The first use of iota gives 0, whenever iota is used again on a new line, its va
VIOLET // 6
)
Remark: There is a convention to name constant identifiers with all uppercase letters, like: `const INCHTOwCM = 2.54`; this improves readability and can be used as long as it is not in conflict with the Visibility Rule of §4.2
**注意事项** 作为约定,常量的标识符主要使用大写字母,标识符中各个部分的连接字符可用小写字母以便区分,如:`const INCHTOwCM = 2.54`;这样不仅增强了可读性,而且不会与第 4.2 节中描述的可见性规则冲突。
##链接