Standard library / runtime
runtime.Compiler
Name of the compiler toolchain used for the running program. Do not assume every implementation uses gc. Expected stdout: 'true\n'.
Formal Syntax & Structure
go syntaxgo
const Compiler = "gc"Working Example
Example Snippetgo
package main
import ( "fmt" "runtime")
func main() { fmt.Println(runtime.Compiler != "") }