私が間違っていることは何ですか?ToUpper が機能しないのはなぜですか?
package main
import (
"fmt"
"regexp"
"strings"
)
func main() {
r := regexp.MustCompile("(\\w)(\\w+)")
// Getting "sometext" instead of "SomeText"
res := r.ReplaceAllString("some text", strings.ToUpper("$1") + "$2")
fmt.Println(res)
}