compiler: implement engine.AppCall interop
This commit is contained in:
parent
ead0b8ff94
commit
330db36168
4 changed files with 129 additions and 2 deletions
|
@ -14,7 +14,7 @@ var (
|
|||
builtinFuncs = []string{
|
||||
"len", "append", "SHA256",
|
||||
"SHA1", "Hash256", "Hash160",
|
||||
"VerifySignature",
|
||||
"VerifySignature", "AppCall",
|
||||
"FromAddress", "Equals",
|
||||
}
|
||||
)
|
||||
|
@ -180,6 +180,11 @@ func isBuiltin(expr ast.Expr) bool {
|
|||
return false
|
||||
}
|
||||
|
||||
func isAppCall(expr ast.Expr) bool {
|
||||
t, ok := expr.(*ast.SelectorExpr)
|
||||
return ok && t.Sel.Name == "AppCall"
|
||||
}
|
||||
|
||||
func isByteArray(lit *ast.CompositeLit, tInfo *types.Info) bool {
|
||||
if len(lit.Elts) == 0 {
|
||||
return false
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue