Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
// "go build" successful
// "gomobile build" fails with
// "gomobile: type io.Reader not defined in package package readsomething ("")
package readsomething
import (
func ReadSomething(r io.Reader) ([]byte, error) {
result, err := ioutil.ReadAll(r)
if err != nil {
return nil, err
return result, nil
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment