diff --git a/src/go/ast/ast_test.go b/src/go/ast/ast_test.go index 1d1eeed59b0..55dec2583a7 100644 --- a/src/go/ast/ast_test.go +++ b/src/go/ast/ast_test.go @@ -63,23 +63,30 @@ var commentsRaw = []struct { {[]string{"//", "//", "// foo"}, "//\n//\n// foo\n"}, {[]string{"// foo bar "}, "// foo bar \n"}, {[]string{"// foo", "// bar"}, "// foo\n// bar\n"}, - {[]string{"// foo", "//", "//", "//", "// bar"}, "// foo\n//\n//\n//\n// bar\n"}, + {[]string{"// foo", "//", "//", "//", "// bar"}, + "// foo\n//\n//\n//\n// bar\n"}, {[]string{"// foo", "/* bar */"}, "// foo\n/* bar */\n"}, - {[]string{"//", "//", "//", "// foo", "//", "//", "//"}, "//\n//\n//\n// foo\n//\n//\n//\n"}, + {[]string{"//", "//", "//", "// foo", "//", "//", "//"}, + "//\n//\n//\n// foo\n//\n//\n//\n"}, {[]string{"/**/"}, "/**/\n"}, {[]string{"/* */"}, "/* */\n"}, - {[]string{"/**/", "/**/", "/* */"}, "/**/\n/**/\n/* */\n"}, + {[]string{"/**/", "/**/", "/* */"}, + "/**/\n/**/\n/* */\n"}, {[]string{"/* Foo */"}, "/* Foo */\n"}, {[]string{"/* Foo Bar */"}, "/* Foo Bar */\n"}, {[]string{"/* Foo*/", "/* Bar*/"}, "/* Foo*/\n/* Bar*/\n"}, - {[]string{"/* Foo*/", "/**/", "/**/", "/**/", "// Bar"}, "/* Foo*/\n/**/\n/**/\n/**/\n// Bar\n"}, - {[]string{"/* Foo*/", "/*\n*/", "//", "/*\n*/", "// Bar"}, "/* Foo*/\n/*\n*/\n//\n/*\n*/\n// Bar\n"}, + {[]string{"/* Foo*/", "/**/", "/**/", "/**/", "// Bar"}, + "/* Foo*/\n/**/\n/**/\n/**/\n// Bar\n"}, + {[]string{"/* Foo*/", "/*\n*/", "//", "/*\n*/", "// Bar"}, + "/* Foo*/\n/*\n*/\n//\n/*\n*/\n// Bar\n"}, {[]string{"/* Foo*/", "// Bar"}, "/* Foo*/\n// Bar\n"}, {[]string{"/* Foo\n Bar*/"}, "/* Foo\n Bar*/\n"}, - {[]string{"// foo", "//go:noinline", "// bar", "//:baz"}, "// foo\n//go:noinline\n// bar\n//:baz\n"}, - {[]string{"// foo", "//lint123:ignore", "// bar"}, "// foo\n//lint123:ignore\n// bar\n"}, + {[]string{"// foo", "//go:noinline", "// bar", "//:baz"}, + "// foo\n//go:noinline\n// bar\n//:baz\n"}, + {[]string{"// foo", "//lint123:ignore", "// bar"}, + "// foo\n//lint123:ignore\n// bar\n"}, } func TestCommentRaw(t *testing.T) {