github.com/switchupcb/yaegi@v0.10.2/_test/ioutil0.go (about)

     1  package main
     2  
     3  import (
     4  	"fmt"
     5  	"io/ioutil"
     6  	"log"
     7  	"strings"
     8  )
     9  
    10  func main() {
    11  	r := strings.NewReader("Go is a general-purpose language designed with systems programming in mind.")
    12  
    13  	b, err := ioutil.ReadAll(r)
    14  	if err != nil {
    15  		log.Fatal(err)
    16  	}
    17  	fmt.Printf("%s", b)
    18  }
    19  
    20  // Output:
    21  // Go is a general-purpose language designed with systems programming in mind.