Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(693)

Side by Side Diff: 2013/distsys/addr1.go

Issue 87910043: code review 87910043: go.talks: fix build; add "// +build OMIT" to many samples (Closed)
Patch Set: diff -r 64c0764808ba https://code.google.com/p/go.talks Created 9 years, 11 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | 2013/distsys/addr2.go » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // +build OMIT
2
1 package main 3 package main
2 4
3 import ( 5 import (
4 "fmt" 6 "fmt"
5 "math/rand" 7 "math/rand"
6 "time" 8 "time"
7 ) 9 )
8 10
9 func lookup() { 11 func lookup() {
10 for _, w := range worklist { 12 for _, w := range worklist {
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 func delay(d time.Duration, f resolver) resolver { 74 func delay(d time.Duration, f resolver) resolver {
73 return func(name string) ([]string, error) { 75 return func(name string) ([]string, error) {
74 time.Sleep(d/2 + time.Duration(rand.Int63n(int64(d/2)))) 76 time.Sleep(d/2 + time.Duration(rand.Int63n(int64(d/2))))
75 return f(name) 77 return f(name)
76 } 78 }
77 } 79 }
78 80
79 func failure(name string) ([]string, error) { 81 func failure(name string) ([]string, error) {
80 return nil, fmt.Errorf("unknown host %v", name) 82 return nil, fmt.Errorf("unknown host %v", name)
81 } 83 }
OLDNEW
« no previous file with comments | « no previous file | 2013/distsys/addr2.go » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b