Documentation
¶
Overview ¶
Package build holds the static version, platform, compiler, and copyright strings reported by the gopy runtime. Mirrors CPython's getversion.c, getplatform.c, getcompiler.c, and getcopyright.c.
Index ¶
Constants ¶
const Copyright = "Copyright (c) 2026 The gopy Authors. All Rights Reserved.\n" +
"\n" +
"Portions of the design and behavior are derived from CPython,\n" +
"Copyright (c) 2001-2026 Python Software Foundation. All Rights Reserved.\n" +
"\n" +
"This program is licensed under the Apache License, Version 2.0.\n"
Copyright is the static copyright string surfaced by the runtime, matching the form used by CPython's Py_GetCopyright.
CPython: Python/getcopyright.c:20 Py_GetCopyright
const PythonCompatVersion = "3.14.0+"
PythonCompatVersion is the upstream CPython version this port tracks.
const PythonMajorVersion = 3
PythonMajorVersion is the major component of the CPython version gopy tracks. Mirrors Include/patchlevel.h:20 PY_MAJOR_VERSION.
const PythonMinorVersion = 14
PythonMinorVersion is the minor component of the CPython version gopy tracks. Mirrors Include/patchlevel.h:21 PY_MINOR_VERSION.
const Version = "0.8.0"
Version is the gopy release version. Bumped per release tag.
Variables ¶
This section is empty.
Functions ¶
func Compiler ¶
func Compiler() string
Compiler returns the Go toolchain identifier that built the running binary (e.g. "go1.26"). Mirrors CPython's Py_GetCompiler, which returns a string like "[GCC 13.2.0]".
CPython: Python/getcompiler.c:24 Py_GetCompiler
func Platform ¶
func Platform() string
Platform returns the platform string in the form "GOOS/GOARCH" (e.g. "darwin/arm64", "linux/amd64"). Mirrors CPython's Py_GetPlatform.
CPython: Python/getplatform.c:9 Py_GetPlatform
func VersionString ¶
func VersionString() string
VersionString returns the full version banner.
gopy 0.1.0 (3.14.0+) [go1.26 darwin/arm64]
CPython: Python/getversion.c:27 Py_GetVersion
Types ¶
This section is empty.