-
Notifications
You must be signed in to change notification settings - Fork 18.8k
Open
Labels
NeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.compiler/runtimeIssues related to the Go compiler and/or runtime.Issues related to the Go compiler and/or runtime.
Milestone
Description
What version of Go are you using (go version)?
$ go version go version go1.18 linux/amd64
What did you do?
func isBtrfs(info *unix.Statfs_t) bool { return info.Type == unix.BTRFS_SUPER_MAGIC }
What did you expect to see?
Code compiles on all platforms.
What did you see instead?
The code compiles on amd64 and arm64, but on 386 and arm it fails:
./fstype.go:7:62: unix.BTRFS_SUPER_MAGIC (untyped int constant 2435016766) overflows int32
Statfs_t.Type is an int32 or int64, depending on the platform. Maybe the constant should be typed accordingly?
Ref restic/restic#3687.
Metadata
Metadata
Assignees
Labels
NeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.compiler/runtimeIssues related to the Go compiler and/or runtime.Issues related to the Go compiler and/or runtime.
Type
Projects
Status
Todo