Logo

Programming-Idioms

History of Idiom 48 > diff from v73 to v74

Edit summary for version 74 by programming-idioms.org:
[Go] +DemoURL

Version 73

2020-07-01, 22:55:53

Version 74

2020-07-01, 22:57:27

Idiom #48 Multi-line string literal

Assign to variable s a string literal consisting in several lines of text

Idiom #48 Multi-line string literal

Assign to variable s a string literal consisting in several lines of text

Variables
s
Variables
s
Extra Keywords
multiline raw
Extra Keywords
multiline raw
Code
s := `Huey
Dewey
Louie`
Code
s := `Huey
Dewey
Louie`
Comments bubble
This is a raw string literal (not "interpreted").
Comments bubble
This is a raw string literal (not "interpreted").
Doc URL
https://golang.org/ref/spec#String_literals
Doc URL
https://golang.org/ref/spec#String_literals
Origin
http://stackoverflow.com/a/7933487/871134
Origin
http://stackoverflow.com/a/7933487/871134
Demo URL
https://play.golang.org/p/1wZ_vgJezsr