Beispiel #1
0
 private static DyObject Lesser(ExecutionContext ctx, DyObject left, DyObject right)
 {
     try
     {
         return(DyTuple.Lesser(ctx, ((DyClass)left).Fields, ((DyClass)right).Fields));
     }
     catch (DyCodeException e)
     {
         ctx.Error = e.Error;
         return(Nil);
     }
 }
Beispiel #2
0
    protected override DyObject LtOp(ExecutionContext ctx, DyObject left, DyObject right)
    {
        if (left.TypeId != right.TypeId)
        {
            return(ctx.OperationNotSupported(Builtins.Lt, left, right));
        }

        try
        {
            return(DyTuple.Lesser(ctx, (DyTuple)left, (DyTuple)right));
        }
        catch (DyCodeException e)
        {
            ctx.Error = e.Error;
            return(Nil);
        }
    }