Created
September 12, 2017 14:37
-
-
Save codecraf8/7e3a246e711425166bfd5b8df4522f7a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package __main__ | |
import πg "grumpy" | |
var Code *πg.Code | |
func init() { | |
Code = πg.NewCode("<module>", "hello.py", nil, 0, func(πF *πg.Frame, _ []*πg.Object) (*πg.Object, *πg.BaseException) { | |
var πR *πg.Object; _ = πR | |
var πE *πg.BaseException; _ = πE | |
var πTemp001 []*πg.Object | |
_ = πTemp001 | |
for ; πF.State() >= 0; πF.PopCheckpoint() { | |
switch πF.State() { | |
case 0: | |
default: panic("unexpected function state") | |
} | |
// line 1: print "hello, world" | |
πF.SetLineno(1) | |
πTemp001 = make([]*πg.Object, 1) | |
πTemp001[0] = πg.NewStr("hello, world").ToObject() | |
if πE = πg.Print(πF, πTemp001, true); πE != nil { | |
continue | |
} | |
} | |
return nil, πE | |
}) | |
πg.RegisterModule("__main__", Code) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment