I am trying to make a very simple script that will pull System uptime and a few other things using system calls in Go. This is some sample code that just will not compile:
package main
import "syscall"
func main(){
var info1 = new(syscall.Sysinfo_t)
var info2 = syscall.Sysinfo_t{}
}
It keeps giving me an error saying undefined: syscall.Sysinfo_t
. What's wrong?