- 16 Aug, 2011 12 commits
-
-
Mikio Hara authored
Fixes #2127. R=rsc CC=golang-dev https://golang.org/cl/4873043
-
Dmitriy Vyukov authored
The corruption can occur when GOMAXPROCS is changed from >1 to 1, since GOMAXPROCS=1 does not imply there is only 1 goroutine running, other goroutines can still be not parked after the change. R=golang-dev, rsc CC=golang-dev https://golang.org/cl/4873050
-
Julian Phillips authored
When the C API being used includes multiple names for the same underlying symbol (e.g. multiple #define's for the same variable), then cgo will generate the same placeholder variables for each name. This then prevents the code from compiling due to multiple declarations of the same variable - so change cgo to only create one instance of the variable for the underlying symbol. R=rsc CC=golang-dev https://golang.org/cl/4826055
-
Lucio De Re authored
R=golang-dev CC=golang-dev, rsc https://golang.org/cl/4837044
-
Lucio De Re authored
src/cmd/5c/reg.c: . Added USED() attribute. src/cmd/6c/cgen.c: . Revised code around "REGARG" to resemble use in "8c" and consequently remove a warning. src/cmd/6l/asm.c: . Added USED() attributes. . Removed an unnecessary assignment. R=golang-dev CC=golang-dev, rsc https://golang.org/cl/4836045
-
Lucio De Re authored
R=golang-dev CC=golang-dev, rsc https://golang.org/cl/4835043
-
Russ Cox authored
// ERROR "pattern1" "pattern2" means that there has to be one or more lines matching pattern1 and then excluding those, there have to be one or more lines matching pattern2. So if you expect two different error messages from a particular line, writing two separate patterns checks that both errors are produced. Also, errchk now flags lines that produce more errors than expected. Before, as long as at least one error matched the pattern, all the others were ignored. Revise tests to expect or silence these additional errors. R=lvd, r, iant CC=golang-dev https://golang.org/cl/4869044
-
Dmitriy Vyukov authored
Currently it's possible to write: var s rpc.Server ... // reuse for my own purposes s.Lock() ... s.Unlock() which is seemingly not intended. R=golang-dev, adg CC=golang-dev https://golang.org/cl/4888049
-
Dmitriy Vyukov authored
They are seemingly not intended to be a part of the public interface. R=golang-dev, adg CC=golang-dev https://golang.org/cl/4873052
-
Rob Pike authored
R=golang-dev, dvyukov CC=golang-dev https://golang.org/cl/4896046
-
Rob Pike authored
R=golang-dev, adg, dsymonds CC=golang-dev https://golang.org/cl/4875050
-
Robert Griesemer authored
R=r, adg CC=golang-dev https://golang.org/cl/4904045
-
- 15 Aug, 2011 12 commits
-
-
Robert Griesemer authored
- show documentation in text mode; e.g.: http://localhost:7777/cmd/godoc/?f=text - simplify template by using $ variable R=r, adg CC=golang-dev https://golang.org/cl/4873045
-
Robert Griesemer authored
- HTML-escape URL paths - URL-escape URL parameters R=bradfitz CC=golang-dev https://golang.org/cl/4890041
-
Sugu Sougoumarane authored
This is useful for applications that want to micromanage the rpc service. Moved part of ServeCodec into a new readRequest function. Renamed existing readRequest to readRequestHeader, and reordered its parameters to align with the new readRequest and service.call. R=golang-dev, r, rsc, sougou CC=golang-dev, msolomon https://golang.org/cl/4889043
-
Rob Pike authored
Do this by adding a fake package called builtin. At the moment, godoc will not present this documentation because the function names are all lower case, but there are plans to address this. The print and println functions are undocumented here. I could be talked into doing them but I'd rather not promote their use. R=dsymonds, n13m3y3r, r, gri, rsc CC=golang-dev https://golang.org/cl/4907041
-
Gustavo Niemeyer authored
R=rsc CC=golang-dev https://golang.org/cl/4904044
-
Gustavo Niemeyer authored
CL 4873048 introduced the ability to build without hg and getting an "unknown" version. While this approach works to avoid the hg dependency, it also means that every exported tree that is built without hg or .hg will have not only missing information, but will also be compatible to one another. Considering that it is a common practice to remove the VCS data in distributions, I suggest we don't take this approach to avoid its consequences. This CL fixes the same problem in a different way: if a VERSION file at the top of the tree exists, use it at all times. If it doesn't, fall back to using information from hg necessarily, and fail if that's not possible. The error message when VERSION and hg are not available instructs users to handle it properly. The VERSION file can be generated with "src/version.bash -save" while hg is still around. R=golang-dev, rsc, gustavo CC=golang-dev https://golang.org/cl/4897043
-
Gustavo Niemeyer authored
This was initially pushed as part of CL 4876046, found when logic in exp/template was using the method on an Invalid value. R=rsc CC=golang-dev https://golang.org/cl/4890043
-
Andrew Gerrand authored
R=golang-dev, dsymonds, n13m3y3r CC=golang-dev https://golang.org/cl/4873048
-
Gustavo Niemeyer authored
Fixes #2152. R=golang-dev, dvyukov CC=golang-dev https://golang.org/cl/4888044
-
Rob Pike authored
First step of moving exp/template into template: save the old code. Code is unedited except for target name in Makefile. R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/4893042
-
Gustavo Niemeyer authored
While using exp/template in practice, the syntax for indexing values using the "index" action was found to be very inconvenient for frequent use when handling dynamic data from maps such as the ones used with json and yaml, that use a type like map[string]interface{}. For these kinds of maps, the default handling of fields as {{.Field}} makes the task of handling the several references significantly more pleasant and elegant, and is equivalent to what's currently done in the "template" package and in other external packages (e.g. mustache). Even with this change, the index action is still relevant as it allows indexing maps in other scenarios where keys wouldn't be valid field names. R=golang-dev, r, gustavo CC=golang-dev https://golang.org/cl/4898043
-
Gustavo Niemeyer authored
This avoids a non-obvious panic when range is used on a nil interface, and fixes it by behaving as if the range was empty. The new behavior is equivalent to the outcome of iterating on a nil map or slice, and is useful because it allows generic structures such as used in json (map[string]interface{}) to behave correctly if a key generally set to a list or map isn't present. R=golang-dev, r, gustavo CC=golang-dev https://golang.org/cl/4876046
-
- 14 Aug, 2011 2 commits
-
-
Robert Hencke authored
R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/4895042
-
Andrew Gerrand authored
R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/4875048
-
- 13 Aug, 2011 3 commits
-
-
Rob Pike authored
R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/4901041
-
Andrew Gerrand authored
R=golang-dev, r CC=golang-dev https://golang.org/cl/4898042
-
David Symonds authored
R=r, rsc CC=golang-dev https://golang.org/cl/4873046
-
- 12 Aug, 2011 11 commits
-
-
Robert Griesemer authored
Since the posLink_url also adds a non-URL attribute, the quoting and URL-escaping must happen inside posLink_url (otherwise the non-URL attribute becomes part or the URL portion of the tag. R=r CC=golang-dev https://golang.org/cl/4888041
-
Robert Griesemer authored
- rename template funcs for better consistency and sort them into groups of related functionality - try to be more consistent with html vs url escaping R=r CC=golang-dev https://golang.org/cl/4887041
-
Robert Griesemer authored
- simplified pipelines - simplified templates by using template variables - converted most old-style formatters into new-style funcs - fixed some escaping bugs (use of url escaping where it was missing) R=r, dsymonds CC=golang-dev https://golang.org/cl/4868044
-
Marcel van Lohuizen authored
R=r, r CC=golang-dev https://golang.org/cl/4837071
-
Marcel van Lohuizen authored
R=r, r CC=golang-dev https://golang.org/cl/4837071
-
Mikio Hara authored
R=gri, dsymonds CC=golang-dev https://golang.org/cl/4881042
-
Joel Sing authored
R=golang-dev, r CC=golang-dev https://golang.org/cl/4837048
-
Mike Samuel authored
func Reverse(*Template) *Template returns a template that produces the reverse of the original for any input. Changes outside exp/template/html include: - Adding a getter for a template's FuncMap so that derived templates can inherit function definitions. - Exported one node factory function, newIdentifier. Deriving tempaltes requires constructing new nodes, but I didn't export all of them because I think shallow copy functions might be more useful for this kind of work. - Bugfix: Template's Name() method ignores the name field so template.New("foo") is a nil dereference instead of "foo". Caveats: Reverse is a toy. It is not UTF-8 safe, and does not preserve order of calls to funcs in FuncMap. For context, see http://groups.google.com/group/golang-nuts/browse_thread/thread/e8bc7c771aae3f20/b1ac41dc6f609b6e?lnk=gst R=rsc, r, nigeltao, r CC=golang-dev https://golang.org/cl/4808089
-
Rob Pike authored
R=golang-dev, dsymonds CC=golang-dev, mikesamuel https://golang.org/cl/4875042
-
David Symonds authored
R=r CC=golang-dev https://golang.org/cl/4878042
-
Rob Pike authored
How quaint. R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/4874045
-