1
0
mirror of https://github.com/golang/go synced 2024-11-12 06:30:21 -07:00
The Go programming language
Go to file
Giles Lean ad73de2f5f syscall: Create syscall_bsd.go for code used by Darwin and other *BSDs
In this change I'd like to combine the common code that is
present in syscall_darwin.go and syscall_freebsd.go.  I
have three reasons for wanting to do this now:

1. reducing code duplication is nearly always good :-)
2. the duplication will get worse if I duplicate this code
   a third time for the NetBSD port I'm working on, which
   I need to do almost immediately
3. by making this change all in one lump and ignoring any
   commonality with the syscall_linux*.go files the diff
   is long but, I think, readable

In future it may be possible to cherry pick functions that
also apply to Linux and put them in (say) syscall_unix.go,
and of course some functions may diverge in future and have
to move out to OS or architecture specific files, but today
I want just the low hanging fruit.

Tested and passed on:

  Darwin (Snow Leopard, 10.6): amd64 and 386
  FreeBSD (8.0-RELEASE):       386 only(*)

(*) All my virtualisation software has stopped playing nice
with FreeBSD for the moment, so I don't have facilities to
test the amd64 port.  As the OS X port is OK and the diff
looks all right to my eyes I shall keep my fingers crossed.
If someone with a FreeBSD/amd64 system cares to test and
report I would be appreciative.

2010-03-27 update: I have replaced my virtualisation software, and have working FreeBSD/i386 and FreeBSD/amd64 virtual machines again.

As I hoped (and expected -- programmers are optimists :-) the code built and passed all but the two currently known to fail tests on FreeBSD/amd64. I rechecked FreeBSD/i386 too: same results.

R=rsc
CC=golang-dev
https://golang.org/cl/751041
2010-03-26 13:23:54 -07:00
doc spec changes for panic and recover. 2010-03-25 17:59:59 -07:00
include Fix *l/*c -V flag segfault 2010-02-08 11:53:27 -08:00
lib godoc: show relative file names without leading '/' (per r's request) 2010-03-24 16:28:59 -07:00
misc misc/bbedit: support for cmplx, real, imag 2010-03-16 13:26:34 -07:00
pkg more description 2009-10-15 23:08:46 -07:00
src syscall: Create syscall_bsd.go for code used by Darwin and other *BSDs 2010-03-26 13:23:54 -07:00
test bug264 didn't report BUG correctly, caused "fail" from test/run 2010-03-25 14:27:24 -07:00
.hgignore runtime: add GOROOT and Version 2010-03-16 23:10:33 -07:00
.hgtags release.2010-03-22 part two 2010-03-23 14:18:57 +11:00
AUTHORS A+C: add Kyle Consalus (individual CLA) 2010-03-20 22:37:53 -07:00
CONTRIBUTORS A+C: add Kyle Consalus (individual CLA) 2010-03-20 22:37:53 -07:00
favicon.ico add a favicon plus a couple of hi-res versions of gordon 2009-10-26 10:13:07 -07:00
LICENSE Add an explicit patent grant to the Go license. 2010-01-25 15:39:32 -08:00
README add a README file, so that if someone finds a 2009-11-08 09:57:37 -08:00

This is the source code repository for the Go programming language.  

For documentation about how to install and use Go,
visit http://golang.org/ or load doc/install.html in your web browser.

After installing Go, you can view a nicely formatted
doc/install.html by running godoc --http=:6060
and then visiting http://localhost:6060/doc/install.html.

Unless otherwise noted, the Go source files are distributed
under the BSD-style license found in the LICENSE file.