예제 #1
0
 public IAssemblyEmitter MakeAssemblyEmitter(AssemblyTranslator translator, AssemblyDefinition assembly, JavascriptFormatter formatter)
 {
     if (translator.IsStubbed(assembly) || translator.IsIgnored(assembly))
         return new NullAssemblyEmitter();
     else
         return new WasmSExprAssemblyEmitter(translator, assembly, formatter);
 }
예제 #2
0
 public IAssemblyEmitter MakeAssemblyEmitter(
     AssemblyTranslator translator,
     AssemblyDefinition assembly,
     JavascriptFormatter formatter,
     IDictionary<AssemblyManifest.Token, string> referenceOverrides
 )
 {
     if (translator.IsStubbed(assembly) || translator.IsIgnored(assembly))
         return new NullAssemblyEmitter();
     else
         return new WasmSExprAssemblyEmitter(translator, assembly, formatter);
 }
예제 #3
0
        private bool ShouldSilence(AssemblyTranslator translator, MemberReference member)
        {
            var typeInfo = translator.TypeInfoProvider.GetTypeInformation(member.DeclaringType);
            if (typeInfo.IsIgnored || typeInfo.IsExternal)
                return true;

            var asm = member.DeclaringType.Module.Assembly;
            if (translator.IsStubbed(asm) || translator.IsIgnored(asm))
                return true;

            return false;
        }