3 // Copyright 2009 The Go Authors. All rights reserved.
4 // Use of this source code is governed by a BSD-style
5 // license that can be found in the LICENSE file.
15 func addInt(i int) { result += fmt.Sprint(i) }
18 for i := 0; i < 10; i++ {
26 if result != "9876543210" {
27 fmt.Printf("test1: bad defer result (should be 9876543210): %q\n", result)
32 func addDotDotDot(v ...interface{}) { result += fmt.Sprint(v...) }
35 for i := 0; i < 10; i++ {
43 if result != "9876543210" {
44 fmt.Printf("test2: bad defer result (should be 9876543210): %q\n", result)