Merge from mainline (167278:168000).
[official-gcc/graphite-test-results.git] / gcc / testsuite / go.test / test / fixedbugs / bug064.go
blob92d2154236fe890a7b103e10c39c798c4158139d
1 // $G $D/$F.go || echo BUG: compilation should succeed
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.
7 package main
9 func
10 swap(x, y int) (u, v int) {
11 return y, x
14 func
15 main() {
16 a := 1;
17 b := 2;
18 a, b = swap(swap(a, b));
19 if a != 2 || b != 1 {
20 panic("bad swap");