1
0
mirror of https://github.com/mgechev/revive.git synced 2025-11-23 22:04:49 +02:00

refactor: rename files to follow Go convention

This commit is contained in:
Oleksandr Redko
2024-11-11 13:39:10 +02:00
committed by chavacava
parent c0d4d07ab6
commit be95bfa705
299 changed files with 181 additions and 178 deletions

30
testdata/string_of_int.go vendored Normal file
View File

@@ -0,0 +1,30 @@
// Copyright 2020 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package fixtures
type A string
type B = string
type C int
type D = uintptr
func StringTest() {
var (
i int
j rune
k byte
l C
m D
n = []int{0, 1, 2}
o struct{ x int }
)
const p = 0
_ = string(i) // MATCH /dubious conversion of an integer into a string, use strconv.Itoa/
_ = string(j)
_ = string(k)
_ = string(p) // MATCH /dubious conversion of an integer into a string, use strconv.Itoa/
_ = A(l) // MATCH /dubious conversion of an integer into a string, use strconv.Itoa/
_ = B(m) // MATCH /dubious conversion of an integer into a string, use strconv.Itoa/
_ = string(n[1]) // MATCH /dubious conversion of an integer into a string, use strconv.Itoa/
_ = string(o.x) // MATCH /dubious conversion of an integer into a string, use strconv.Itoa/
}