chore: fix function names in comment

Signed-off-by: goodfirm <fanyishang@yeah.net>
This commit is contained in:
goodfirm 2024-04-10 14:08:31 +08:00 committed by Qi Xiao
parent 14380bc74d
commit e3bf7189dd
4 changed files with 5 additions and 5 deletions

View File

@ -54,7 +54,7 @@ var bufferBuilderWritesTests = []struct {
Line{Cell{" ", ""}, Cell{" ", ""}}}}},
}
// TestBufferWrites tests BufferBuilder.Writes by calling Writes on a
// TestBufferBuilderWrites tests BufferBuilder.Writes by calling Writes on a
// BufferBuilder and see if the built Buffer matches what is expected.
func TestBufferBuilderWrites(t *testing.T) {
for _, test := range bufferBuilderWritesTests {

View File

@ -73,7 +73,7 @@ type Fn struct {
Usage string
}
// ExtractFS extracts elvdocs of all modules found under fsys, and returns a map
// ExtractAllFromFS extracts elvdocs of all modules found under fsys, and returns a map
// from the symbol prefix of a module ("" for builtin, "$mod:" for any other $mod).
//
// See [ExtractFromFS] for how modules correspond to files.

View File

@ -318,7 +318,7 @@ func BenchmarkSequentialConjNative1(b *testing.B) { nativeSequentialAdd(b.N, N1)
func BenchmarkSequentialConjNative2(b *testing.B) { nativeSequentialAdd(b.N, N2) }
func BenchmarkSequentialConjNative3(b *testing.B) { nativeSequentialAdd(b.N, N3) }
// nativeSequntialAdd starts with an empty native map and adds elements 0...n-1
// nativeSequentialAdd starts with an empty native map and adds elements 0...n-1
// to the map, using the same value as the key, repeating for N times.
func nativeSequentialAdd(N int, n uint32) {
for r := 0; r < N; r++ {
@ -348,7 +348,7 @@ func BenchmarkRandomStringsConjNative1(b *testing.B) { nativeRandomStringsAdd(b,
func BenchmarkRandomStringsConjNative2(b *testing.B) { nativeRandomStringsAdd(b, N2) }
func BenchmarkRandomStringsConjNative3(b *testing.B) { nativeRandomStringsAdd(b, N3) }
// nativeSequntialAdd starts with an empty native map and adds n random strings
// nativeRandomStringsAdd starts with an empty native map and adds n random strings
// to the map, using the same value as the key, repeating for b.N times.
func nativeRandomStringsAdd(b *testing.B, n int) {
ss := getRandomStrings(b)

View File

@ -106,7 +106,7 @@ func (ra *recentArticles) insert(a article) {
ra.articles[i] = a
}
// decodeFile decodes the named file in TOML into a pointer.
// decodeTOML decodes the named file in TOML into a pointer.
func decodeTOML(fname string, v any) {
_, err := toml.DecodeFile(fname, v)
if err != nil {