Standard library / reflect
reflect.Value.String()
Read a String-kind value. For most other kinds String produces a diagnostic representation rather than conversion. Expected stdout: 'go\n'.
Formal Syntax & Structure
go syntaxgo
func (v Value) String() stringReturn Value
string
Read a String-kind value.
Working Example
Example Snippetgo
package main
import ( "fmt" "reflect")
func main() { fmt.Println(reflect.ValueOf("go").String()) }