Converting Erlang-C port example to Erlang-Golang
问题 I'm trying to write a Golang driver for Erlang, accesible via an Erlang port. I've started with the Erlang C port example, which works fine: http://www.erlang.org/doc/tutorial/c_port.html Now I'm trying to port the C code to Golang; just trying to echo a simple 'Hello World\n' message, using '\n' as the delimiter. So my Golang code is as follows: package main import ( "bufio" "fmt" "os" ) func main() { reader := bufio.NewReader(os.Stdin) fmt.Print("Enter text: ") bytes, _ := reader.ReadBytes(