Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(2817)

Delta Between Two Patch Sets: test/fixedbugs/bug465.dir/a.go

Issue 11455045: code review 11455045: [release-branch.go1.1] cmd/gc: fix pointer composite li... (Closed)
Left Patch Set: Created 10 years, 8 months ago
Right Patch Set: diff -r a7bd9a33067b https://code.google.com/p/go Created 10 years, 8 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
Right: Side by side diff | Download
« no previous file with change/comment | « src/cmd/gc/fmt.c ('k') | test/fixedbugs/bug465.dir/b.go » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
(no file at all)
1 // Copyright 2012 The Go Authors. All rights reserved. 1 // Copyright 2012 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style 2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file. 3 // license that can be found in the LICENSE file.
4 4
5 package a 5 package a
6 6
7 type T struct{ A, B int } 7 type T struct{ A, B int }
8 8
9 type A []int 9 type A []int
10 10
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 } 52 }
53 return 0 53 return 0
54 } 54 }
55 55
56 func F7() int { 56 func F7() int {
57 for m := (M{}); len(m) < (T{1, 2}).A; m[1] = (A{1})[0] { 57 for m := (M{}); len(m) < (T{1, 2}).A; m[1] = (A{1})[0] {
58 return 1 58 return 1
59 } 59 }
60 return 0 60 return 0
61 } 61 }
62
63 func F8() int {
64 if a := (&T{1, 1}); a != nil {
65 return 1
66 }
67 return 0
68 }
69
70 func F9() int {
71 var a *T
72 if a = (&T{1, 1}); a != nil {
73 return 1
74 }
75 return 0
76 }
LEFTRIGHT

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b