View definition

func MakeFromLiteral(lit string, tok Token, zero uint) Value

Defined in github.com/golang/go/src/go/constant/value.go

Description

MakeFromLiteral returns the corresponding integer, floating-point, imaginary, character, or string value for a Go literal string. The tok value must be one of token.INT, token.FLOAT, token.IMAG, token.CHAR, or token.STRING. The final argument must be zero. If the literal string syntax is invalid, the result is an Unknown.