github.com/xenophex/i18n4go@v0.2.7-0.20160907212557-40256cda157a/test_fixtures/rewrite_package/f_option/expected_output/test_interpolated_strings.go (about) 1 package input_files 2 3 import ( 4 "fmt" 5 "strings" 6 ) 7 8 func Interpolated() string { 9 name := T("cruel") 10 myName := T("evil") 11 fmt.Printf(T("Hello {{.Arg0}} world!", map[string]interface{}{"Arg0": name})) 12 fmt.Printf(T("Hello {{.Arg0}} world!, bye from {{.Arg1}}", map[string]interface{}{"Arg0": name, "Arg1": myName})) 13 14 fmt.Printf(T("Hello {{.Arg0}}({{.Arg1}}) world!, bye from {{.Arg2}}", map[string]interface{}{"Arg0": 10, "Arg1": name, "Arg2": T("Evil")})) 15 16 fmt.Printf(T("Hello {{.Arg0}} world!", map[string]interface{}{"Arg0": name})) 17 fmt.Printf(T("Hello {{.Arg0}} world! {{.Arg1}}", map[string]interface{}{"Arg0": name, "Arg1": name})) 18 }