func _compile(args []string) { public := neyo.DEFAULT_PUBLIC_DIRETORY if len(args) == 2 { public = args[1] } err := neyo.Compile(public) if err != nil { neyo.Log(neyo.ERROR, "%s", err) } }
func _pprof() { f, _ := os.OpenFile("neyo.pprof", os.O_WRONLY|os.O_TRUNC|os.O_CREATE, os.ModePerm) defer f.Close() pprof.StartCPUProfile(f) defer pprof.StopCPUProfile() for i := 0; i < 100; i++ { err := neyo.Compile(neyo.DEFAULT_PUBLIC_DIRETORY) if err != nil { neyo.Log(neyo.ERROR, "%s", err) } } }