зеркало из https://github.com/mozilla/gecko-dev.git
Bug 296672: fixes to build on latest Mono, and produce non-empty interfaces.
Patch from Mark Steele <mwsteele@gmail.com>, r=shaver.
This commit is contained in:
Родитель
bcda601644
Коммит
27ba19fa07
|
@ -206,7 +206,7 @@ class ProxyGenerator
|
|||
EmitPrepareArgStore(i);
|
||||
ilg.Emit(OpCodes.Stind_I4);
|
||||
break;
|
||||
case TypeTag.NSIDPtr:
|
||||
case TypeTag.NSIdPtr:
|
||||
EmitPrepareArgStore(i);
|
||||
ilg.Emit(OpCodes.Stind_I4); // XXX 64-bitness
|
||||
break;
|
||||
|
|
|
@ -17,10 +17,10 @@ public struct XPTType
|
|||
public byte padding;
|
||||
public UInt16 arg3;
|
||||
|
||||
static implicit operator XPTType(TypeInfo.TypeDescriptor td)
|
||||
static public implicit operator XPTType(TypeInfo.TypeDescriptor td)
|
||||
{
|
||||
XPTType t = new XPTType();
|
||||
t.prefix = (byte)(td.flags | td.tag);
|
||||
t.prefix = (byte) ((byte)td.flags | (byte)td.tag);
|
||||
t.arg1 = td.arg1;
|
||||
t.arg2 = td.arg2;
|
||||
t.arg3 = td.arg3;
|
||||
|
@ -91,7 +91,7 @@ public class TypeInfo
|
|||
return false;
|
||||
}
|
||||
|
||||
static implicit operator TypeDescriptor(XPTType t)
|
||||
static public implicit operator TypeDescriptor(XPTType t)
|
||||
{
|
||||
TypeDescriptor td = new TypeInfo.TypeDescriptor();
|
||||
td.flags = (TypeFlags)(t.prefix & XPTType.FlagMask);
|
||||
|
|
|
@ -12,7 +12,8 @@ public class Generate
|
|||
PropertyBuilder lastProperty = null;
|
||||
const PropertyAttributes PROPERTY_ATTRS = PropertyAttributes.None;
|
||||
const MethodAttributes METHOD_ATTRS = MethodAttributes.Public |
|
||||
MethodAttributes.Abstract | MethodAttributes.Virtual;
|
||||
MethodAttributes.Abstract | MethodAttributes.Virtual |
|
||||
MethodAttributes.NewSlot;
|
||||
|
||||
Type FixupInterfaceType(TypeInfo.ParamDescriptor desc)
|
||||
{
|
||||
|
@ -87,9 +88,12 @@ public class Generate
|
|||
else
|
||||
parentType = EmitOneInterface(parentName);
|
||||
|
||||
Console.WriteLine ("Emitting: " + name + " : " + parentType);
|
||||
|
||||
TypeBuilder ifaceTb = mb.DefineType("Mozilla.XPCOM.Interfaces." + name,
|
||||
TypeAttributes.Public |
|
||||
TypeAttributes.Interface,
|
||||
TypeAttributes.Interface |
|
||||
TypeAttributes.Abstract,
|
||||
parentType);
|
||||
ifaceTable.Add(name, ifaceTb);
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче