aboutsummaryrefslogtreecommitdiff
path: root/test/ddd2.go
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2010-02-01 00:25:59 -0800
committerRuss Cox <rsc@golang.org>2010-02-01 00:25:59 -0800
commit68796b0270e270c034cd99bfbaacaced5d77a363 (patch)
tree6590f313875bb775a8d04bb714090ecb578bde98 /test/ddd2.go
parent65e671b903807967f84817f84703ff46d6feed9f (diff)
downloadgo-68796b0270e270c034cd99bfbaacaced5d77a363.tar.gz
go-68796b0270e270c034cd99bfbaacaced5d77a363.zip
gc: add ... T, rework plain ...
No longer a distinct type; now a property of func types. R=ken2 CC=golang-dev https://golang.org/cl/197042
Diffstat (limited to 'test/ddd2.go')
-rw-r--r--test/ddd2.go16
1 files changed, 16 insertions, 0 deletions
diff --git a/test/ddd2.go b/test/ddd2.go
new file mode 100644
index 0000000000..a06af0c065
--- /dev/null
+++ b/test/ddd2.go
@@ -0,0 +1,16 @@
+// true
+
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package ddd
+
+func Sum(args ...int) int {
+ s := 0
+ for _, v := range args {
+ s += v
+ }
+ return s
+}
+