Skip to content

Commit dc8e19b

Browse files
committed
update formatting for references
1 parent 652864d commit dc8e19b

File tree

11 files changed

+246
-362
lines changed

11 files changed

+246
-362
lines changed
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
===
1+
---
2+
23
/TEST_OUTPUT/workspace/main.go
34
References in File: 1
4-
===
5-
Reference at Line 12, Column 14:
5+
At: L12:C14
6+
67
11|func main() {
78
12| fmt.Println(FooBar())
89
13|}
9-
Lines changed: 8 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
1-
===
1+
---
2+
23
/TEST_OUTPUT/workspace/another_consumer.go
34
References in File: 1
4-
===
5-
Reference at Line 8, Column 34:
5+
At: L8:C34
6+
67
6|func AnotherConsumer() {
78
7| // Use helper function
89
8| fmt.Println("Another message:", HelperFunction())
@@ -11,62 +12,17 @@ Reference at Line 8, Column 34:
1112
11| s := &SharedStruct{
1213
12| ID: 2,
1314
13| Name: "another test",
14-
14| Value: 99.9,
15-
15| Constants: []string{SharedConstant, "extra"},
16-
16| }
17-
17|
18-
18| // Use the struct methods
19-
19| if name := s.GetName(); name != "" {
20-
20| fmt.Println("Got name:", name)
21-
21| }
22-
22|
23-
23| // Implement the interface with a custom type
24-
24| type CustomImplementor struct {
25-
25| SharedStruct
26-
26| }
27-
27|
28-
28| custom := &CustomImplementor{
29-
29| SharedStruct: *s,
30-
30| }
31-
31|
32-
32| // Custom type implements SharedInterface through embedding
33-
33| var iface SharedInterface = custom
34-
34| iface.Process()
35-
35|
36-
36| // Use shared type as a slice type
37-
37| values := []SharedType{1, 2, 3}
38-
38| for _, v := range values {
39-
39| fmt.Println("Value:", v)
40-
40| }
41-
41|}
4215

43-
===
16+
---
17+
4418
/TEST_OUTPUT/workspace/consumer.go
4519
References in File: 1
46-
===
47-
Reference at Line 7, Column 13:
20+
At: L7:C13
21+
4822
6|func ConsumerFunction() {
4923
7| message := HelperFunction()
5024
8| fmt.Println(message)
5125
9|
5226
10| // Use shared struct
5327
11| s := &SharedStruct{
5428
12| ID: 1,
55-
13| Name: "test",
56-
14| Value: 42.0,
57-
15| Constants: []string{SharedConstant},
58-
16| }
59-
17|
60-
18| // Call methods on the struct
61-
19| fmt.Println(s.Method())
62-
20| s.Process()
63-
21|
64-
22| // Use shared interface
65-
23| var iface SharedInterface = s
66-
24| fmt.Println(iface.GetName())
67-
25|
68-
26| // Use shared type
69-
27| var t SharedType = 100
70-
28| fmt.Println(t)
71-
29|}
72-
Lines changed: 12 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,11 @@
1-
===
1+
---
2+
23
/TEST_OUTPUT/workspace/another_consumer.go
34
References in File: 1
4-
===
5-
Reference at Line 19, Column 15:
6-
6|func AnotherConsumer() {
7-
7| // Use helper function
8-
8| fmt.Println("Another message:", HelperFunction())
9-
9|
10-
10| // Create another SharedStruct instance
11-
11| s := &SharedStruct{
12-
12| ID: 2,
13-
13| Name: "another test",
5+
At: L19:C15
6+
7+
6|func AnotherConsumer() {
8+
...
149
14| Value: 99.9,
1510
15| Constants: []string{SharedConstant, "extra"},
1611
16| }
@@ -22,42 +17,15 @@ Reference at Line 19, Column 15:
2217
22|
2318
23| // Implement the interface with a custom type
2419
24| type CustomImplementor struct {
25-
25| SharedStruct
26-
26| }
27-
27|
28-
28| custom := &CustomImplementor{
29-
29| SharedStruct: *s,
30-
30| }
31-
31|
32-
32| // Custom type implements SharedInterface through embedding
33-
33| var iface SharedInterface = custom
34-
34| iface.Process()
35-
35|
36-
36| // Use shared type as a slice type
37-
37| values := []SharedType{1, 2, 3}
38-
38| for _, v := range values {
39-
39| fmt.Println("Value:", v)
40-
40| }
41-
41|}
4220

43-
===
21+
---
22+
4423
/TEST_OUTPUT/workspace/consumer.go
4524
References in File: 1
46-
===
47-
Reference at Line 24, Column 20:
48-
6|func ConsumerFunction() {
49-
7| message := HelperFunction()
50-
8| fmt.Println(message)
51-
9|
52-
10| // Use shared struct
53-
11| s := &SharedStruct{
54-
12| ID: 1,
55-
13| Name: "test",
56-
14| Value: 42.0,
57-
15| Constants: []string{SharedConstant},
58-
16| }
59-
17|
60-
18| // Call methods on the struct
25+
At: L24:C20
26+
27+
6|func ConsumerFunction() {
28+
...
6129
19| fmt.Println(s.Method())
6230
20| s.Process()
6331
21|
@@ -69,4 +37,3 @@ Reference at Line 24, Column 20:
6937
27| var t SharedType = 100
7038
28| fmt.Println(t)
7139
29|}
72-
Lines changed: 12 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
===
1+
---
2+
23
/TEST_OUTPUT/workspace/another_consumer.go
34
References in File: 1
4-
===
5-
Reference at Line 15, Column 23:
6-
6|func AnotherConsumer() {
7-
7| // Use helper function
8-
8| fmt.Println("Another message:", HelperFunction())
9-
9|
5+
At: L15:C23
6+
7+
6|func AnotherConsumer() {
8+
...
109
10| // Create another SharedStruct instance
1110
11| s := &SharedStruct{
1211
12| ID: 2,
@@ -18,37 +17,15 @@ Reference at Line 15, Column 23:
1817
18| // Use the struct methods
1918
19| if name := s.GetName(); name != "" {
2019
20| fmt.Println("Got name:", name)
21-
21| }
22-
22|
23-
23| // Implement the interface with a custom type
24-
24| type CustomImplementor struct {
25-
25| SharedStruct
26-
26| }
27-
27|
28-
28| custom := &CustomImplementor{
29-
29| SharedStruct: *s,
30-
30| }
31-
31|
32-
32| // Custom type implements SharedInterface through embedding
33-
33| var iface SharedInterface = custom
34-
34| iface.Process()
35-
35|
36-
36| // Use shared type as a slice type
37-
37| values := []SharedType{1, 2, 3}
38-
38| for _, v := range values {
39-
39| fmt.Println("Value:", v)
40-
40| }
41-
41|}
4220

43-
===
21+
---
22+
4423
/TEST_OUTPUT/workspace/consumer.go
4524
References in File: 1
46-
===
47-
Reference at Line 15, Column 23:
48-
6|func ConsumerFunction() {
49-
7| message := HelperFunction()
50-
8| fmt.Println(message)
51-
9|
25+
At: L15:C23
26+
27+
6|func ConsumerFunction() {
28+
...
5229
10| // Use shared struct
5330
11| s := &SharedStruct{
5431
12| ID: 1,
@@ -60,13 +37,3 @@ Reference at Line 15, Column 23:
6037
18| // Call methods on the struct
6138
19| fmt.Println(s.Method())
6239
20| s.Process()
63-
21|
64-
22| // Use shared interface
65-
23| var iface SharedInterface = s
66-
24| fmt.Println(iface.GetName())
67-
25|
68-
26| // Use shared type
69-
27| var t SharedType = 100
70-
28| fmt.Println(t)
71-
29|}
72-
Lines changed: 12 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,11 @@
1-
===
1+
---
2+
23
/TEST_OUTPUT/workspace/another_consumer.go
34
References in File: 1
4-
===
5-
Reference at Line 33, Column 12:
6-
6|func AnotherConsumer() {
7-
7| // Use helper function
8-
8| fmt.Println("Another message:", HelperFunction())
9-
9|
10-
10| // Create another SharedStruct instance
11-
11| s := &SharedStruct{
12-
12| ID: 2,
13-
13| Name: "another test",
14-
14| Value: 99.9,
15-
15| Constants: []string{SharedConstant, "extra"},
16-
16| }
17-
17|
18-
18| // Use the struct methods
19-
19| if name := s.GetName(); name != "" {
20-
20| fmt.Println("Got name:", name)
21-
21| }
22-
22|
23-
23| // Implement the interface with a custom type
24-
24| type CustomImplementor struct {
25-
25| SharedStruct
26-
26| }
27-
27|
5+
At: L33:C12
6+
7+
6|func AnotherConsumer() {
8+
...
289
28| custom := &CustomImplementor{
2910
29| SharedStruct: *s,
3011
30| }
@@ -36,27 +17,15 @@ Reference at Line 33, Column 12:
3617
36| // Use shared type as a slice type
3718
37| values := []SharedType{1, 2, 3}
3819
38| for _, v := range values {
39-
39| fmt.Println("Value:", v)
40-
40| }
41-
41|}
4220

43-
===
21+
---
22+
4423
/TEST_OUTPUT/workspace/consumer.go
4524
References in File: 1
46-
===
47-
Reference at Line 23, Column 12:
48-
6|func ConsumerFunction() {
49-
7| message := HelperFunction()
50-
8| fmt.Println(message)
51-
9|
52-
10| // Use shared struct
53-
11| s := &SharedStruct{
54-
12| ID: 1,
55-
13| Name: "test",
56-
14| Value: 42.0,
57-
15| Constants: []string{SharedConstant},
58-
16| }
59-
17|
25+
At: L23:C12
26+
27+
6|func ConsumerFunction() {
28+
...
6029
18| // Call methods on the struct
6130
19| fmt.Println(s.Method())
6231
20| s.Process()
@@ -68,5 +37,3 @@ Reference at Line 23, Column 12:
6837
26| // Use shared type
6938
27| var t SharedType = 100
7039
28| fmt.Println(t)
71-
29|}
72-

0 commit comments

Comments
 (0)