Skip to content

Commit 555181e

Browse files
committed
Don't mix 'any' and 'interface{}'. Fixes #2726.
1 parent 55ad921 commit 555181e

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed

src/os/types_unix.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ type fileStat struct {
2424
func (fs *fileStat) Size() int64 { return fs.size }
2525
func (fs *fileStat) Mode() FileMode { return fs.mode }
2626
func (fs *fileStat) ModTime() time.Time { return fs.modTime }
27-
func (fs *fileStat) Sys() interface{} { return &fs.sys }
2827

2928
func sameFile(fs1, fs2 *fileStat) bool {
3029
return fs1.sys.Dev == fs2.sys.Dev && fs1.sys.Ino == fs2.sys.Ino

src/os/types_unix_go_118.go

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
//go:build (darwin && go1.18) || (linux && !baremetal && go1.18)
2+
// +build darwin,go1.18 linux,!baremetal,go1.18
3+
4+
// Copyright 2009 The Go Authors. All rights reserved.
5+
// Use of this source code is governed by a BSD-style
6+
// license that can be found in the LICENSE file.
7+
8+
package os
9+
10+
func (fs *fileStat) Sys() interface{} { return &fs.sys }

src/os/types_unix_go_other.go

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
//go:build (darwin && !go1.18) || (linux && !baremetal && !go1.18)
2+
// +build darwin,!go1.18 linux,!baremetal,!go1.18
3+
4+
// Copyright 2009 The Go Authors. All rights reserved.
5+
// Use of this source code is governed by a BSD-style
6+
// license that can be found in the LICENSE file.
7+
8+
package os
9+
10+
func (fs *fileStat) Sys() interface{} { return &fs.sys }

0 commit comments

Comments
 (0)