mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-05 03:27:48 +00:00
os: add Perm stub on Go 1.15
This adds a stub for Perm on Go 1.15, which allows the OS package to compile again.
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
//go:build !go1.16
|
||||
// +build !go1.16
|
||||
|
||||
package os
|
||||
@@ -49,3 +50,8 @@ func (m FileMode) IsDir() bool {
|
||||
func (m FileMode) IsRegular() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
// Perm is a stub, always returning 0.
|
||||
func (m FileMode) Perm() FileMode {
|
||||
return 0
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user