Standard library / runtime

runtime.PanicNilError.RuntimeError()

Marker method for runtime.Error; it does not itself raise a panic. Expected stdout: 'true\n'.

Formal Syntax & Structure

go syntaxgo
func (*PanicNilError) RuntimeError()

Working Example

Example Snippetgo
package main
import (  "fmt"  "runtime")
func main() {  var e runtime.PanicNilError  e.RuntimeError()  var r runtime.Error = &e  fmt.Println(r.Error() != "")}
Go Reference