// exported from runtime. func modinfo() string // ReadBuildInfo returns the build information embedded // in the running binary. The information is available only // in binaries built with module support. func ReadBuildInfo() (info *BuildInfo, ok bool) { … } type BuildInfo … type Module … type BuildSetting … // quoteKey reports whether key is required to be quoted. func quoteKey(key string) bool { … } // quoteValue reports whether value is required to be quoted. func quoteValue(value string) bool { … } // String returns a string representation of a [BuildInfo]. func (bi *BuildInfo) String() string { … } // ParseBuildInfo parses the string returned by [*BuildInfo.String], // restoring the original BuildInfo, // except that the GoVersion field is not set. // Programs should normally not call this function, // but instead call [ReadBuildInfo], [debug/buildinfo.ReadFile], // or [debug/buildinfo.Read]. func ParseBuildInfo(data string) (bi *BuildInfo, err error) { … }