Exemple #1
0
        public static IshtarObject *ToIshtarObject(string str, CallFrame frame = null, IshtarObject **node = null)
        {
            var arg   = IshtarGC.AllocObject(TYPE_STRING.AsRuntimeClass(), node);
            var clazz = IshtarUnsafe.AsRef <RuntimeIshtarClass>(arg->clazz);

            arg->vtable[clazz.Field["!!value"].vtable_offset] = StringStorage.Intern(str);
            return(arg);
        }
Exemple #2
0
 public RuntimeIshtarClass decodeClass()
 {
     if (clazz is null)
     {
         return(null);
     }
     return(IshtarUnsafe.AsRef <RuntimeIshtarClass>(clazz));
 }
Exemple #3
0
        public static IshtarObject *ToIshtarObject(float dotnet_value, CallFrame frame = null, IshtarObject **node = null)
        {
            var obj   = IshtarGC.AllocObject(TYPE_I8.AsRuntimeClass(), node);
            var clazz = IshtarUnsafe.AsRef <RuntimeIshtarClass>(obj->clazz);

            obj->vtable[clazz.Field["!!value"].vtable_offset] = (int *)BitConverter.SingleToInt32Bits(dotnet_value);

            return(obj);
        }
Exemple #4
0
        public static IshtarObject *ToIshtarObject(long dotnet_value, CallFrame frame = null, IshtarObject **node = null)
        {
            var obj   = IshtarGC.AllocObject(TYPE_I8.AsRuntimeClass(), node);
            var clazz = IshtarUnsafe.AsRef <RuntimeIshtarClass>(obj->clazz);

            obj->vtable[clazz.Field["!!value"].vtable_offset] = (long *)dotnet_value;

            return(obj);
        }