Skip to content

x/text/message: Print, Println funcs do not do any language-specific formatting #45471

@vinser

Description

@vinser

What version of Go are you using (go version)?

$ go version
on Playground and in Docker

Does this issue reproduce with the latest release?

I don't know because I didn't use it before

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
on Playground and in Docker

What did you do?

package main

import (
	"golang.org/x/text/language"
	"golang.org/x/text/message"
	"os"
)

func main() {
	message.SetString(language.Dutch, "soccer", "voetbal")
	p := message.NewPrinter(language.Dutch)
	p.Println("soccer")
	p.Fprintln(os.Stdout, "soccer")
	p.Print("soccer", "\n")
	p.Printf("soccer", "\n")

}

https://play.golang.org/p/LjQ6DfG1CJX

What did you expect to see?

voetbal
voetbal
voetbal
voetbal

What did you see instead?

soccer
soccer
soccer
voetbal

Metadata

Metadata

Assignees

No one assigned

    Labels

    FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions