mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-06 03:53:42 +00:00
Lint: lint and fix src/{os,reflect} (#4228)
* lint: expand to src/{os,reflect}, fix or suppress what it found
* internal/tools/tools.go: the tools idiom requires a build tag guard to avoid go test complaints
This commit is contained in:
@@ -489,7 +489,7 @@ func TestTinyStruct(t *testing.T) {
|
||||
|
||||
func TestTinyZero(t *testing.T) {
|
||||
s := "hello, world"
|
||||
var sptr *string = &s
|
||||
sptr := &s
|
||||
v := ValueOf(&sptr).Elem()
|
||||
v.Set(Zero(v.Type()))
|
||||
|
||||
@@ -535,7 +535,7 @@ func TestTinyAddr(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestTinyNilType(t *testing.T) {
|
||||
var a any = nil
|
||||
var a any
|
||||
typ := TypeOf(a)
|
||||
if typ != nil {
|
||||
t.Errorf("Type of any{nil} is not nil")
|
||||
|
||||
Reference in New Issue
Block a user