aboutsummaryrefslogtreecommitdiff
path: root/libgo/go/text/scanner/example_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'libgo/go/text/scanner/example_test.go')
-rw-r--r--libgo/go/text/scanner/example_test.go21
1 files changed, 11 insertions, 10 deletions
diff --git a/libgo/go/text/scanner/example_test.go b/libgo/go/text/scanner/example_test.go
index f8b51b7..f48c31d 100644
--- a/libgo/go/text/scanner/example_test.go
+++ b/libgo/go/text/scanner/example_test.go
@@ -19,6 +19,7 @@ func Example() {
someParsable = text
}`
var s scanner.Scanner
+ s.Filename = "example"
s.Init(strings.NewReader(src))
var tok rune
for tok != scanner.EOF {
@@ -27,14 +28,14 @@ func Example() {
}
// Output:
- // At position 3:4 : if
- // At position 3:6 : a
- // At position 3:8 : >
- // At position 3:11 : 10
- // At position 3:13 : {
- // At position 4:15 : someParsable
- // At position 4:17 : =
- // At position 4:22 : text
- // At position 5:3 : }
- // At position 5:3 :
+ // At position example:3:4 : if
+ // At position example:3:6 : a
+ // At position example:3:8 : >
+ // At position example:3:11 : 10
+ // At position example:3:13 : {
+ // At position example:4:15 : someParsable
+ // At position example:4:17 : =
+ // At position example:4:22 : text
+ // At position example:5:3 : }
+ // At position example:5:3 :
}