mirror of
https://github.com/golang/go.git
synced 2025-05-05 23:53:05 +00:00
go.tools/godoc: move Throttle to package godoc/util
R=bradfitz CC=golang-dev https://golang.org/cl/11417043
This commit is contained in:
parent
8901caa2b3
commit
2392be72c2
@ -762,7 +762,7 @@ func canonical(w string) string { return strings.ToLower(w) }
|
|||||||
//
|
//
|
||||||
func NewIndex(dirnames <-chan string, fulltextIndex bool, throttle float64) *Index {
|
func NewIndex(dirnames <-chan string, fulltextIndex bool, throttle float64) *Index {
|
||||||
var x Indexer
|
var x Indexer
|
||||||
th := NewThrottle(throttle, 100*time.Millisecond) // run at least 0.1s at a time
|
th := util.NewThrottle(throttle, 100*time.Millisecond) // run at least 0.1s at a time
|
||||||
|
|
||||||
// initialize Indexer
|
// initialize Indexer
|
||||||
// (use some reasonably sized maps to start)
|
// (use some reasonably sized maps to start)
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
// Use of this source code is governed by a BSD-style
|
// Use of this source code is governed by a BSD-style
|
||||||
// license that can be found in the LICENSE file.
|
// license that can be found in the LICENSE file.
|
||||||
|
|
||||||
package main
|
package util
|
||||||
|
|
||||||
import "time"
|
import "time"
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user