mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-03-26 02:30:30 +08:00
gofrontend: avoid use of unsafe.Sizeof extension
Avoid the use of a gccgo language extension which allows unsafe.Sizeof to accept a type by passing an expression of the relevant type. From-SVN: r209503
This commit is contained in:
parent
342e787344
commit
e315e8a5b9
@ -138,7 +138,7 @@ func (w WaitStatus) TrapCause() int
|
||||
//sys Select(nfd int, r *FdSet, w *FdSet, e *FdSet, timeout *Timeval) (n int, err error)
|
||||
//select(nfd _C_int, r *FdSet, w *FdSet, e *FdSet, timeout *Timeval) _C_int
|
||||
|
||||
const nfdbits = int(unsafe.Sizeof(fds_bits_type) * 8)
|
||||
const nfdbits = int(unsafe.Sizeof(fds_bits_type(0)) * 8)
|
||||
|
||||
type FdSet struct {
|
||||
Bits [(FD_SETSIZE + nfdbits - 1) / nfdbits]fds_bits_type
|
||||
|
Loading…
x
Reference in New Issue
Block a user