summaryrefslogtreecommitdiff
path: root/src/cmd/gofmt/rewrite.go
AgeCommit message (Collapse)AuthorFilesLines
2012-04-06Imported Upstream version 1upstream/1Ondřej Surý1-6/+7
2011-09-13Imported Upstream version 60upstream/60Ondřej Surý1-0/+291
2011-09-13Imported Upstream version 60Ondřej Surý1-301/+0
2011-08-03Imported Upstream version 59upstream/59Ondřej Surý1-1/+1
2011-04-28Imported Upstream version 2011.04.27upstream/2011.04.27Ondřej Surý1-11/+28
2011-04-26Imported Upstream version 2011.04.13upstream/2011.04.13Ondřej Surý1-47/+71
2011-02-14Imported Upstream version 2011-02-01.1upstream/2011-02-01.1Ondřej Surý1-2/+2
2011-01-17Imported Upstream version 2011.01.12upstream/2011.01.12Ondřej Surý1-19/+42
2010-07-01strings and bytes.Split: make count of 0 mean 0, not infinite.Rob Pike1-1/+1
Use a count of -1 for infinity. Ditto for Replace. R=rsc CC=golang-dev http://codereview.appspot.com/1704044 Committer: Rob Pike <r@golang.org>
2010-03-15gofmt: fix for gofmt rewrite featureRobert Griesemer1-3/+13
Fixes issue 643. R=rsc CC=golang-dev http://codereview.appspot.com/576041
2010-01-27More steps towards tracking of identifier scopes.Robert Griesemer1-1/+1
- provide scope to parse functions; if non-nil, parser uses the scope to declare and lookup identifiers - resolve forward references where possible R=rsc CC=golang-dev http://codereview.appspot.com/194098
2010-01-15 Steps towards tracking scopes for identifiers.Robert Griesemer1-2/+2
- Identifiers refer now to the language entity (Object) that they denote. At the moment this is at best an approximation. - Initial data structures for language entities (Objects) and expression types (Type) independent of the actual type notations. - Initial support for declaring and looking up identifiers. - Updated various dependent files and added support functions. - Extensively tested to avoid breakage. This is an AST change. R=rsc CC=golang-dev, rog http://codereview.appspot.com/189080
2009-12-17fix for gofmt rewrite matcher bugRobert Griesemer1-0/+3
R=rsc CC=golang-dev http://codereview.appspot.com/179096
2009-12-16- Parse expressions as opposed to statements for gofmt rewrite patterns.Robert Griesemer1-11/+8
Allows stand-alone types (e.g. []int as patterns) and doesn't require a semicolon at the end (which are now mandatory terminators). - Fix a matcher bug. R=rsc CC=golang-dev http://codereview.appspot.com/179088
2009-12-15 1) Change default gofmt default settings forRobert Griesemer1-65/+65
parsing and printing to new syntax. Use -oldparser to parse the old syntax, use -oldprinter to print the old syntax. 2) Change default gofmt formatting settings to use tabs for indentation only and to use spaces for alignment. This will make the code alignment insensitive to an editor's tabwidth. Use -spaces=false to use tabs for alignment. 3) Manually changed src/exp/parser/parser_test.go so that it doesn't try to parse the parser's source files using the old syntax (they have new syntax now). 4) gofmt -w src misc test/bench 1st set of files. R=rsc CC=agl, golang-dev, iant, ken2, r http://codereview.appspot.com/180047
2009-11-23gofmt -r: documentation and minor fixesRuss Cox1-16/+17
fix a few paren insertion bugs in the printer too. R=gri, r CC=golang-dev http://codereview.appspot.com/157119
2009-11-20gofmt: add -r flag to rewrite source code according to patternRuss Cox1-0/+226
a little slow, but usable (speed unchanged when not using -r) tweak go/printer to handle nodes without line numbers more gracefully in a couple cases. R=gri http://codereview.appspot.com/156103