xgo/objects/builtin_function.go
2019-01-08 23:17:42 -08:00

31 lines
552 B
Go

package objects
import (
"github.com/d5/tengo/token"
)
type BuiltinFunction BuiltinFunc
func (o BuiltinFunction) TypeName() string {
return "builtin-function"
}
func (o BuiltinFunction) String() string {
return "<builtin-function>"
}
func (o BuiltinFunction) BinaryOp(op token.Token, rhs Object) (Object, error) {
return nil, ErrInvalidOperator
}
func (o BuiltinFunction) Copy() Object {
return BuiltinFunction(o)
}
func (o BuiltinFunction) IsFalsy() bool {
return false
}
func (o BuiltinFunction) Equals(x Object) bool {
return false
}