finish translation for start enums at one

This commit is contained in:
TangoEnSkai 2019-10-18 00:55:35 +09:00
parent c12847f83d
commit 74c1d3f2d8
1 changed files with 7 additions and 8 deletions

View File

@ -70,7 +70,7 @@ row before the </tbody></table> line.
- [슬라이스(Slices)와 맵(Maps)의 리턴](#%ec%8a%ac%eb%9d%bc%ec%9d%b4%ec%8a%a4slices%ec%99%80-%eb%a7%b5maps%ec%9d%98-%eb%a6%ac%ed%84%b4) - [슬라이스(Slices)와 맵(Maps)의 리턴](#%ec%8a%ac%eb%9d%bc%ec%9d%b4%ec%8a%a4slices%ec%99%80-%eb%a7%b5maps%ec%9d%98-%eb%a6%ac%ed%84%b4)
- [Defer에서 Clean Up까지](#defer%ec%97%90%ec%84%9c-clean-up%ea%b9%8c%ec%a7%80) - [Defer에서 Clean Up까지](#defer%ec%97%90%ec%84%9c-clean-up%ea%b9%8c%ec%a7%80)
- [채널의 크기(Channel Size)는 하나(One) 혹은 제로(None)](#%ec%b1%84%eb%84%90%ec%9d%98-%ed%81%ac%ea%b8%b0channel-size%eb%8a%94-%ed%95%98%eb%82%98one-%ed%98%b9%ec%9d%80-%ec%a0%9c%eb%a1%9cnone) - [채널의 크기(Channel Size)는 하나(One) 혹은 제로(None)](#%ec%b1%84%eb%84%90%ec%9d%98-%ed%81%ac%ea%b8%b0channel-size%eb%8a%94-%ed%95%98%eb%82%98one-%ed%98%b9%ec%9d%80-%ec%a0%9c%eb%a1%9cnone)
- [Start Enums at One](#start-enums-at-one) - [Enums은 1에서부터 시작하라](#enums%ec%9d%80-1%ec%97%90%ec%84%9c%eb%b6%80%ed%84%b0-%ec%8b%9c%ec%9e%91%ed%95%98%eb%9d%bc)
- [Error Types](#error-types) - [Error Types](#error-types)
- [Error Wrapping](#error-wrapping) - [Error Wrapping](#error-wrapping)
- [Handle Type Assertion Failures](#handle-type-assertion-failures) - [Handle Type Assertion Failures](#handle-type-assertion-failures)
@ -462,17 +462,17 @@ c := make(chan int, 64)
// 사이즈 1 // 사이즈 1
c := make(chan int, 1) // 혹은 c := make(chan int, 1) // 혹은
// 버퍼링 되지 않는 채널, 사이즈 0 // 버퍼링 되지 않는 채널, 사이즈 0
c :=make(chan int) c := make(chan int)
``` ```
</td></tr> </td></tr>
</tbody></table> </tbody></table>
### Start Enums at One ### Enums은 1에서부터 시작하라
The standard way of introducing enumerations in Go is to declare a custom type Go에서 열거형(enumerations)을 도입하는 일반적 방식(standard way)은 사용자정의형(a custom type) 그리고 `const`그룹을 `iota`와 함께 을 선언(declare)하는 것이다.
and a `const` group with `iota`. Since variables have a 0 default value, you
should usually start your enums on a non-zero value. 변수의 기본값(default value)는 0이기 때문에, 여러분들은 일반적으로 열거형을 0이 아닌 값(non-zero value)로 시작해야 한다.
<table> <table>
<thead><tr><th>Bad</th><th>Good</th></tr></thead> <thead><tr><th>Bad</th><th>Good</th></tr></thead>
@ -508,8 +508,7 @@ const (
</td></tr> </td></tr>
</tbody></table> </tbody></table>
There are cases where using the zero value makes sense, for example when the 제로 값(zero value)를 사용하는 것이 적절할 때도 있다. 예를 들면, 제로 값이 0인 경우 바람직한 기본 동작(default behaviour)이다.
zero value case is the desirable default behavior.
```go ```go
type LogOutput int type LogOutput int