Standard library / go/types

go/types.Typ

Table of predeclared basic type descriptors indexed by BasicKind. Do not mutate the shared table. Expected stdout: 'int\n'.

Formal Syntax & Structure

go syntaxgo
var Typ []*Basic

Working Example

Example Snippetgo
package main
import (  "fmt"  "go/types")
func main() { fmt.Println(types.Typ[types.Int]) }
Go Reference