1
0
mirror of https://github.com/golang/go synced 2024-11-21 16:44:43 -07:00

gofmt: applied gofmt -w -s src misc

R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/5451070
This commit is contained in:
Robert Griesemer 2011-12-01 14:33:24 -08:00
parent e281576b9a
commit 15a3a5cf6c
8 changed files with 13 additions and 13 deletions

View File

@ -38,8 +38,8 @@ POSSIBILITY OF SUCH DAMAGE.
package main
import (
big "gmp"
"fmt"
big "gmp"
"runtime"
)

View File

@ -5,8 +5,8 @@
package main
import (
"swig/callback"
"fmt"
"swig/callback"
)
type GoCallback struct{}

View File

@ -165,8 +165,8 @@ func (fs *httpZipFS) Open(name string) (http.File, error) {
&fileInfo{
name,
os.ModeDir,
0, // no size for directory
time.Time{}, // no mtime for directory
0, // no size for directory
time.Time{}, // no mtime for directory
},
nil,
fs.list[index:],

View File

@ -69,7 +69,7 @@ var timefileinfoTypeConfig = &TypeConfig{
//
func timefileinfoIsOld(f *ast.File, typeof map[interface{}]string) bool {
old := false
// called records the expressions that appear as
// the function part of a function call, so that
// we can distinguish a ref to the possibly new time.UTC

View File

@ -21,12 +21,12 @@ type WriteTest struct {
}
var writeTests = []WriteTest{
WriteTest{
{
Name: "foo",
Data: []byte("Rabbits, guinea pigs, gophers, marsupial rats, and quolls."),
Method: Store,
},
WriteTest{
{
Name: "bar",
Data: nil, // large data set in the test
Method: Deflate,

View File

@ -30,11 +30,11 @@ func TestRenderer(t *testing.T) {
Type: ElementNode,
Data: "p",
Attr: []Attribute{
Attribute{
{
Key: "id",
Val: "A",
},
Attribute{
{
Key: "foo",
Val: `abc"def`,
},
@ -48,7 +48,7 @@ func TestRenderer(t *testing.T) {
Type: ElementNode,
Data: "b",
Attr: []Attribute{
Attribute{
{
Key: "empty",
Val: "",
},
@ -64,7 +64,7 @@ func TestRenderer(t *testing.T) {
Type: ElementNode,
Data: "i",
Attr: []Attribute{
Attribute{
{
Key: "backslash",
Val: `\`,
},

View File

@ -716,7 +716,7 @@ func (e *escaper) editTextNode(n *parse.TextNode, text []byte) {
// commit applies changes to actions and template calls needed to contextually
// autoescape content and adds any derived templates to the set.
func (e *escaper) commit() {
for name, _ := range e.output {
for name := range e.output {
e.template(name).Funcs(funcMap)
}
for _, t := range e.derived {

View File

@ -1597,7 +1597,7 @@ func TestRedundantFuncs(t *testing.T) {
for n0, m := range redundantFuncs {
f0 := funcMap[n0].(func(...interface{}) string)
for n1, _ := range m {
for n1 := range m {
f1 := funcMap[n1].(func(...interface{}) string)
for _, input := range inputs {
want := f0(input)