diff options
author | Ian Lance Taylor <ian@gcc.gnu.org> | 2012-03-29 03:53:13 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@gcc.gnu.org> | 2012-03-29 03:53:13 +0000 |
commit | a0c8ad3bdfe2b84c35388bf9937fa9296fe50278 (patch) | |
tree | a4e8c7e8ea099b688e9c92980ae88d0d055a99b9 /libgo | |
parent | 917c1602aa2bf8905890ee6c19a1624f80b1c8c3 (diff) | |
download | gcc-a0c8ad3bdfe2b84c35388bf9937fa9296fe50278.zip gcc-a0c8ad3bdfe2b84c35388bf9937fa9296fe50278.tar.gz gcc-a0c8ad3bdfe2b84c35388bf9937fa9296fe50278.tar.bz2 |
compiler, libgo: unsafe.{Sizeof,Alignof,Offsetof} return uintptr.
From-SVN: r185946
Diffstat (limited to 'libgo')
-rw-r--r-- | libgo/go/os/dir.go | 2 | ||||
-rw-r--r-- | libgo/go/syscall/libcall_posix.go | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/libgo/go/os/dir.go b/libgo/go/os/dir.go index f119a21..c693aeb 100644 --- a/libgo/go/os/dir.go +++ b/libgo/go/os/dir.go @@ -34,7 +34,7 @@ var elen int func (file *File) readdirnames(n int) (names []string, err error) { if elen == 0 { var dummy syscall.Dirent - elen = (unsafe.Offsetof(dummy.Name) + + elen = (int(unsafe.Offsetof(dummy.Name)) + libc_pathconf(syscall.StringBytePtr(file.name), syscall.PC_NAME_MAX) + 1) } diff --git a/libgo/go/syscall/libcall_posix.go b/libgo/go/syscall/libcall_posix.go index 92feae0..9961ba8 100644 --- a/libgo/go/syscall/libcall_posix.go +++ b/libgo/go/syscall/libcall_posix.go @@ -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 int, r *FdSet, w *FdSet, e *FdSet, timeout *Timeval) int -const nfdbits = unsafe.Sizeof(fds_bits_type) * 8 +const nfdbits = int(unsafe.Sizeof(fds_bits_type) * 8) type FdSet struct { Bits [(FD_SETSIZE + nfdbits - 1) / nfdbits]fds_bits_type |