(size int)
| 68 | }() |
| 69 | |
| 70 | func randomString(size int) string { |
| 71 | |
| 72 | buf := bytes.NewBuffer(make([]byte, 0, size)) |
| 73 | for _ = range iter.N(size) { |
| 74 | buf.WriteRune(alphabet[rand.Intn(len(alphabet))]) |
| 75 | } |
| 76 | return buf.String() |
| 77 | } |
| 78 | |
| 79 | ///////////////// |
| 80 | // From lua to Go |