Пример #1
0
        public HExpr EnsurePseudoProcedure(string name, BaseType dt, int arity)
        {
            var exp = host.EnsurePseudoProcedure(name, ntf.GetRekoType((HExpr)dt), arity);
            var pc  = new ProcedureConstant(PrimitiveType.Ptr32, exp);

            return(m.MapToHandle(pc));
        }
Пример #2
0
        public HExpr EnsureIntrinsicProcedure(string name, int isIdempotent, BaseType dt, int arity)
        {
            var exp = host.EnsureIntrinsic(name, isIdempotent != 0, ntf.GetRekoType((HExpr)dt), arity);
            var pc  = new ProcedureConstant(PrimitiveType.Ptr32, exp);

            return(m.MapToHandle(pc));
        }
Пример #3
0
        public void Ntf_array_i32()
        {
            var ntf = new NativeTypeFactory();
            var a   = ntf.ArrayOf((HExpr)BaseType.Int32, 4);
            var arr = ntf.GetRekoType(a);

            Assert.AreEqual("(arr int32 4)", arr.ToString());
        }