﻿.class private abstract auto ansi sealed beforefieldinit Costura.AssemblyLoader
extends [mscorlib]System.Object
{
.class abstract auto ansi sealed nested private beforefieldinit '<>O'
extends [mscorlib]System.Object
{
.field public static class [mscorlib]System.ResolveEventHandler '<0>__ResolveAssembly'
}
.field private static object nullCacheLock
.field private static class [mscorlib]System.Collections.Generic.Dictionary`2<string,bool> nullCache
.field private static class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> assemblyNames
.field private static class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> symbolNames
.field private static int32 isAttached
.method private hidebysig static string
CultureToString(class [mscorlib]System.Globalization.CultureInfo culture) cil managed
{
.maxstack  2
.locals init (bool V_0,
string V_1)
IL_0000:  nop
IL_0001:  ldarg.0
IL_0002:  ldnull
IL_0003:  ceq
IL_0005:  stloc.0
IL_0006:  ldloc.0
IL_0007:  brfalse.s  IL_0012
IL_0009:  nop
IL_000a:  ldsfld     string [mscorlib]System.String::Empty
IL_000f:  stloc.1
IL_0010:  br.s       IL_001b
IL_0012:  ldarg.0
IL_0013:  callvirt   instance string [mscorlib]System.Globalization.CultureInfo::get_Name()
IL_0018:  stloc.1
IL_0019:  br.s       IL_001b
IL_001b:  ldloc.1
IL_001c:  ret
}
.method private hidebysig static void  Log(string format,
object[] args) cil managed
{
.maxstack  8
IL_0000:  nop
IL_0001:  ldstr      "=== COSTURA === "
IL_0006:  ldarg.0
IL_0007:  ldarg.1
IL_0008:  call       string [mscorlib]System.String::Format(string,
object[])
IL_000d:  call       string [mscorlib]System.String::Concat(string,
string)
IL_0012:  call       void [System]System.Diagnostics.Debug::WriteLine(string)
IL_0017:  nop
IL_0018:  ret
}
.method private hidebysig static class [mscorlib]System.Reflection.Assembly
ReadExistingAssembly(class [mscorlib]System.Reflection.AssemblyName name) cil managed
{
.maxstack  5
.locals init (class [mscorlib]System.AppDomain V_0,
class [mscorlib]System.Reflection.Assembly[] V_1,
class [mscorlib]System.Reflection.Assembly[] V_2,
int32 V_3,
class [mscorlib]System.Reflection.Assembly V_4,
class [mscorlib]System.Reflection.AssemblyName V_5,
bool V_6,
class [mscorlib]System.Reflection.Assembly V_7)
IL_0000:  nop
IL_0001:  call       class [mscorlib]System.AppDomain [mscorlib]System.AppDomain::get_CurrentDomain()
IL_0006:  stloc.0
IL_0007:  ldloc.0
IL_0008:  callvirt   instance class [mscorlib]System.Reflection.Assembly[] [mscorlib]System.AppDomain::GetAssemblies()
IL_000d:  stloc.1
IL_000e:  nop
IL_000f:  ldloc.1
IL_0010:  stloc.2
IL_0011:  ldc.i4.0
IL_0012:  stloc.3
IL_0013:  br.s       IL_0086
IL_0015:  ldloc.2
IL_0016:  ldloc.3
IL_0017:  ldelem.ref
IL_0018:  stloc.s    V_4
IL_001a:  nop
IL_001b:  ldloc.s    V_4
IL_001d:  callvirt   instance class [mscorlib]System.Reflection.AssemblyName [mscorlib]System.Reflection.Assembly::GetName()
IL_0022:  stloc.s    V_5
IL_0024:  ldloc.s    V_5
IL_0026:  callvirt   instance string [mscorlib]System.Reflection.AssemblyName::get_Name()
IL_002b:  ldarg.0
IL_002c:  callvirt   instance string [mscorlib]System.Reflection.AssemblyName::get_Name()
IL_0031:  ldc.i4.3
IL_0032:  call       bool [mscorlib]System.String::Equals(string,
string,
valuetype [mscorlib]System.StringComparison)
IL_0037:  brfalse.s  IL_0058
IL_0039:  ldloc.s    V_5
IL_003b:  callvirt   instance class [mscorlib]System.Globalization.CultureInfo [mscorlib]System.Reflection.AssemblyName::get_CultureInfo()
IL_0040:  call       string Costura.AssemblyLoader::CultureToString(class [mscorlib]System.Globalization.CultureInfo)
IL_0045:  ldarg.0
IL_0046:  callvirt   instance class [mscorlib]System.Globalization.CultureInfo [mscorlib]System.Reflection.AssemblyName::get_CultureInfo()
IL_004b:  call       string Costura.AssemblyLoader::CultureToString(class [mscorlib]System.Globalization.CultureInfo)
IL_0050:  ldc.i4.3
IL_0051:  call       bool [mscorlib]System.String::Equals(string,
string,
valuetype [mscorlib]System.StringComparison)
IL_0056:  br.s       IL_0059
IL_0058:  ldc.i4.0
IL_0059:  stloc.s    V_6
IL_005b:  ldloc.s    V_6
IL_005d:  brfalse.s  IL_0081
IL_005f:  nop
IL_0060:  ldstr      "Assembly '{0}' already loaded, returning existing "
+ "assembly"
IL_0065:  ldc.i4.1
IL_0066:  newarr     [mscorlib]System.Object
IL_006b:  dup
IL_006c:  ldc.i4.0
IL_006d:  ldloc.s    V_4
IL_006f:  callvirt   instance string [mscorlib]System.Reflection.Assembly::get_FullName()
IL_0074:  stelem.ref
IL_0075:  call       void Costura.AssemblyLoader::Log(string,
object[])
IL_007a:  nop
IL_007b:  ldloc.s    V_4
IL_007d:  stloc.s    V_7
IL_007f:  br.s       IL_0091
IL_0081:  nop
IL_0082:  ldloc.3
IL_0083:  ldc.i4.1
IL_0084:  add
IL_0085:  stloc.3
IL_0086:  ldloc.3
IL_0087:  ldloc.2
IL_0088:  ldlen
IL_0089:  conv.i4
IL_008a:  blt.s      IL_0015
IL_008c:  ldnull
IL_008d:  stloc.s    V_7
IL_008f:  br.s       IL_0091
IL_0091:  ldloc.s    V_7
IL_0093:  ret
}
.method private hidebysig static string
GetAssemblyResourceName(class [mscorlib]System.Reflection.AssemblyName requestedAssemblyName) cil managed
{
.maxstack  3
.locals init (string V_0,
bool V_1,
string V_2)
IL_0000:  nop
IL_0001:  ldarg.0
IL_0002:  callvirt   instance string [mscorlib]System.Reflection.AssemblyName::get_Name()
IL_0007:  callvirt   instance string [mscorlib]System.String::ToLowerInvariant()
IL_000c:  stloc.0
IL_000d:  ldarg.0
IL_000e:  callvirt   instance class [mscorlib]System.Globalization.CultureInfo [mscorlib]System.Reflection.AssemblyName::get_CultureInfo()
IL_0013:  brfalse.s  IL_002a
IL_0015:  ldarg.0
IL_0016:  callvirt   instance class [mscorlib]System.Globalization.CultureInfo [mscorlib]System.Reflection.AssemblyName::get_CultureInfo()
IL_001b:  callvirt   instance string [mscorlib]System.Globalization.CultureInfo::get_Name()
IL_0020:  call       bool [mscorlib]System.String::IsNullOrEmpty(string)
IL_0025:  ldc.i4.0
IL_0026:  ceq
IL_0028:  br.s       IL_002b
IL_002a:  ldc.i4.0
IL_002b:  stloc.1
IL_002c:  ldloc.1
IL_002d:  brfalse.s  IL_004d
IL_002f:  nop
IL_0030:  ldarg.0
IL_0031:  callvirt   instance class [mscorlib]System.Globalization.CultureInfo [mscorlib]System.Reflection.AssemblyName::get_CultureInfo()
IL_0036:  call       string Costura.AssemblyLoader::CultureToString(class [mscorlib]System.Globalization.CultureInfo)
IL_003b:  ldstr      "."
IL_0040:  ldloc.0
IL_0041:  call       string [mscorlib]System.String::Concat(string,
string,
string)
IL_0046:  callvirt   instance string [mscorlib]System.String::ToLowerInvariant()
IL_004b:  stloc.0
IL_004c:  nop
IL_004d:  ldloc.0
IL_004e:  stloc.2
IL_004f:  br.s       IL_0051
IL_0051:  ldloc.2
IL_0052:  ret
}
.method private hidebysig static void  CopyTo(class [mscorlib]System.IO.Stream source,
class [mscorlib]System.IO.Stream destination) cil managed
{
.maxstack  4
.locals init (uint8[] V_0,
int32 V_1,
bool V_2)
IL_0000:  nop
IL_0001:  ldc.i4     0x14000
IL_0006:  newarr     [mscorlib]System.Byte
IL_000b:  stloc.0
IL_000c:  br.s       IL_001a
IL_000e:  nop
IL_000f:  ldarg.1
IL_0010:  ldloc.0
IL_0011:  ldc.i4.0
IL_0012:  ldloc.1
IL_0013:  callvirt   instance void [mscorlib]System.IO.Stream::Write(uint8[],
int32,
int32)
IL_0018:  nop
IL_0019:  nop
IL_001a:  ldarg.0
IL_001b:  ldloc.0
IL_001c:  ldc.i4.0
IL_001d:  ldloc.0
IL_001e:  ldlen
IL_001f:  conv.i4
IL_0020:  callvirt   instance int32 [mscorlib]System.IO.Stream::Read(uint8[],
int32,
int32)
IL_0025:  dup
IL_0026:  stloc.1
IL_0027:  ldc.i4.0
IL_0028:  cgt.un
IL_002a:  stloc.2
IL_002b:  ldloc.2
IL_002c:  brtrue.s   IL_000e
IL_002e:  ret
}
.method private hidebysig static class [mscorlib]System.IO.Stream
LoadStream(string fullName) cil managed
{
.maxstack  2
.locals init (class [mscorlib]System.Reflection.Assembly V_0,
bool V_1,
class [mscorlib]System.IO.Stream V_2,
class [System]System.IO.Compression.DeflateStream V_3,
class [mscorlib]System.IO.MemoryStream V_4,
class [mscorlib]System.IO.Stream V_5)
IL_0000:  nop
IL_0001:  call       class [mscorlib]System.Reflection.Assembly [mscorlib]System.Reflection.Assembly::GetExecutingAssembly()
IL_0006:  stloc.0
IL_0007:  ldarg.0
IL_0008:  ldstr      ".compressed"
IL_000d:  callvirt   instance bool [mscorlib]System.String::EndsWith(string)
IL_0012:  stloc.1
IL_0013:  ldloc.1
IL_0014:  brfalse.s  IL_005e
IL_0016:  nop
IL_0017:  ldloc.0
IL_0018:  ldarg.0
IL_0019:  callvirt   instance class [mscorlib]System.IO.Stream [mscorlib]System.Reflection.Assembly::GetManifestResourceStream(string)
IL_001e:  stloc.2
.try
{
IL_001f:  ldloc.2
IL_0020:  ldc.i4.0
IL_0021:  newobj     instance void [System]System.IO.Compression.DeflateStream::.ctor(class [mscorlib]System.IO.Stream,
valuetype [System]System.IO.Compression.CompressionMode)
IL_0026:  stloc.3
.try
{
IL_0027:  nop
IL_0028:  newobj     instance void [mscorlib]System.IO.MemoryStream::.ctor()
IL_002d:  stloc.s    V_4
IL_002f:  ldloc.3
IL_0030:  ldloc.s    V_4
IL_0032:  call       void Costura.AssemblyLoader::CopyTo(class [mscorlib]System.IO.Stream,
class [mscorlib]System.IO.Stream)
IL_0037:  nop
IL_0038:  ldloc.s    V_4
IL_003a:  ldc.i4.0
IL_003b:  conv.i8
IL_003c:  callvirt   instance void [mscorlib]System.IO.Stream::set_Position(int64)
IL_0041:  nop
IL_0042:  ldloc.s    V_4
IL_0044:  stloc.s    V_5
IL_0046:  leave.s    IL_0069
}  // end .try
finally
{
IL_0048:  ldloc.3
IL_0049:  brfalse.s  IL_0052
IL_004b:  ldloc.3
IL_004c:  callvirt   instance void [mscorlib]System.IDisposable::Dispose()
IL_0051:  nop
IL_0052:  endfinally
}  // end handler
}  // end .try
finally
{
IL_0053:  ldloc.2
IL_0054:  brfalse.s  IL_005d
IL_0056:  ldloc.2
IL_0057:  callvirt   instance void [mscorlib]System.IDisposable::Dispose()
IL_005c:  nop
IL_005d:  endfinally
}  // end handler
IL_005e:  ldloc.0
IL_005f:  ldarg.0
IL_0060:  callvirt   instance class [mscorlib]System.IO.Stream [mscorlib]System.Reflection.Assembly::GetManifestResourceStream(string)
IL_0065:  stloc.s    V_5
IL_0067:  br.s       IL_0069
IL_0069:  ldloc.s    V_5
IL_006b:  ret
}
.method private hidebysig static class [mscorlib]System.IO.Stream
LoadStream(class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> resourceNames,
string name) cil managed
{
.maxstack  3
.locals init (string V_0,
bool V_1,
class [mscorlib]System.IO.Stream V_2)
IL_0000:  nop
IL_0001:  ldarg.0
IL_0002:  ldarg.1
IL_0003:  ldloca.s   V_0
IL_0005:  callvirt   instance bool class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>::TryGetValue(!0,
!1&)
IL_000a:  stloc.1
IL_000b:  ldloc.1
IL_000c:  brfalse.s  IL_0018
IL_000e:  nop
IL_000f:  ldloc.0
IL_0010:  call       class [mscorlib]System.IO.Stream Costura.AssemblyLoader::LoadStream(string)
IL_0015:  stloc.2
IL_0016:  br.s       IL_001c
IL_0018:  ldnull
IL_0019:  stloc.2
IL_001a:  br.s       IL_001c
IL_001c:  ldloc.2
IL_001d:  ret
}
.method private hidebysig static uint8[]
ReadStream(class [mscorlib]System.IO.Stream 'stream') cil managed
{
.maxstack  2
.locals init (class [mscorlib]System.IO.MemoryStream V_0,
uint8[] V_1)
IL_0000:  nop
IL_0001:  newobj     instance void [mscorlib]System.IO.MemoryStream::.ctor()
IL_0006:  stloc.0
.try
{
IL_0007:  nop
IL_0008:  ldarg.0
IL_0009:  ldloc.0
IL_000a:  callvirt   instance void [mscorlib]System.IO.Stream::CopyTo(class [mscorlib]System.IO.Stream)
IL_000f:  nop
IL_0010:  ldloc.0
IL_0011:  callvirt   instance uint8[] [mscorlib]System.IO.MemoryStream::ToArray()
IL_0016:  stloc.1
IL_0017:  leave.s    IL_0024
}  // end .try
finally
{
IL_0019:  ldloc.0
IL_001a:  brfalse.s  IL_0023
IL_001c:  ldloc.0
IL_001d:  callvirt   instance void [mscorlib]System.IDisposable::Dispose()
IL_0022:  nop
IL_0023:  endfinally
}  // end handler
IL_0024:  ldloc.1
IL_0025:  ret
}
.method private hidebysig static class [mscorlib]System.Reflection.Assembly
ReadFromEmbeddedResources(class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> assemblyNames,
class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> symbolNames,
class [mscorlib]System.Reflection.AssemblyName requestedAssemblyName) cil managed
{
.maxstack  2
.locals init (string V_0,
uint8[] V_1,
class [mscorlib]System.IO.Stream V_2,
bool V_3,
class [mscorlib]System.Reflection.Assembly V_4,
class [mscorlib]System.IO.Stream V_5,
bool V_6,
uint8[] V_7)
IL_0000:  nop
IL_0001:  ldarg.2
IL_0002:  call       string Costura.AssemblyLoader::GetAssemblyResourceName(class [mscorlib]System.Reflection.AssemblyName)
IL_0007:  stloc.0
IL_0008:  ldarg.0
IL_0009:  ldloc.0
IL_000a:  call       class [mscorlib]System.IO.Stream Costura.AssemblyLoader::LoadStream(class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>,
string)
IL_000f:  stloc.2
.try
{
IL_0010:  nop
IL_0011:  ldloc.2
IL_0012:  ldnull
IL_0013:  ceq
IL_0015:  stloc.3
IL_0016:  ldloc.3
IL_0017:  brfalse.s  IL_001f
IL_0019:  nop
IL_001a:  ldnull
IL_001b:  stloc.s    V_4
IL_001d:  leave.s    IL_0079
IL_001f:  ldloc.2
IL_0020:  call       uint8[] Costura.AssemblyLoader::ReadStream(class [mscorlib]System.IO.Stream)
IL_0025:  stloc.1
IL_0026:  nop
IL_0027:  leave.s    IL_0034
}  // end .try
finally
{
IL_0029:  ldloc.2
IL_002a:  brfalse.s  IL_0033
IL_002c:  ldloc.2
IL_002d:  callvirt   instance void [mscorlib]System.IDisposable::Dispose()
IL_0032:  nop
IL_0033:  endfinally
}  // end handler
IL_0034:  ldarg.1
IL_0035:  ldloc.0
IL_0036:  call       class [mscorlib]System.IO.Stream Costura.AssemblyLoader::LoadStream(class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>,
string)
IL_003b:  stloc.s    V_5
.try
{
IL_003d:  nop
IL_003e:  ldloc.s    V_5
IL_0040:  ldnull
IL_0041:  cgt.un
IL_0043:  stloc.s    V_6
IL_0045:  ldloc.s    V_6
IL_0047:  brfalse.s  IL_005f
IL_0049:  nop
IL_004a:  ldloc.s    V_5
IL_004c:  call       uint8[] Costura.AssemblyLoader::ReadStream(class [mscorlib]System.IO.Stream)
IL_0051:  stloc.s    V_7
IL_0053:  ldloc.1
IL_0054:  ldloc.s    V_7
IL_0056:  call       class [mscorlib]System.Reflection.Assembly [mscorlib]System.Reflection.Assembly::Load(uint8[],
uint8[])
IL_005b:  stloc.s    V_4
IL_005d:  leave.s    IL_0079
IL_005f:  nop
IL_0060:  leave.s    IL_006f
}  // end .try
finally
{
IL_0062:  ldloc.s    V_5
IL_0064:  brfalse.s  IL_006e
IL_0066:  ldloc.s    V_5
IL_0068:  callvirt   instance void [mscorlib]System.IDisposable::Dispose()
IL_006d:  nop
IL_006e:  endfinally
}  // end handler
IL_006f:  ldloc.1
IL_0070:  call       class [mscorlib]System.Reflection.Assembly [mscorlib]System.Reflection.Assembly::Load(uint8[])
IL_0075:  stloc.s    V_4
IL_0077:  br.s       IL_0079
IL_0079:  ldloc.s    V_4
IL_007b:  ret
}
.method public hidebysig static class [mscorlib]System.Reflection.Assembly
ResolveAssembly(object sender,
class [mscorlib]System.ResolveEventArgs e) cil managed
{
.maxstack  5
.locals init (string V_0,
class [mscorlib]System.Reflection.AssemblyName V_1,
class [mscorlib]System.Reflection.Assembly V_2,
object V_3,
bool V_4,
bool V_5,
class [mscorlib]System.Reflection.Assembly V_6,
bool V_7,
bool V_8,
object V_9,
bool V_10,
bool V_11)
IL_0000:  nop
IL_0001:  ldarg.1
IL_0002:  callvirt   instance string [mscorlib]System.ResolveEventArgs::get_Name()
IL_0007:  stloc.0
IL_0008:  ldloc.0
IL_0009:  newobj     instance void [mscorlib]System.Reflection.AssemblyName::.ctor(string)
IL_000e:  stloc.1
IL_000f:  ldsfld     object Costura.AssemblyLoader::nullCacheLock
IL_0014:  stloc.3
IL_0015:  ldc.i4.0
IL_0016:  stloc.s    V_4
.try
{
IL_0018:  ldloc.3
IL_0019:  ldloca.s   V_4
IL_001b:  call       void [mscorlib]System.Threading.Monitor::Enter(object,
bool&)
IL_0020:  nop
IL_0021:  nop
IL_0022:  ldsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,bool> Costura.AssemblyLoader::nullCache
IL_0027:  ldloc.0
IL_0028:  callvirt   instance bool class [mscorlib]System.Collections.Generic.Dictionary`2<string,bool>::ContainsKey(!0)
IL_002d:  stloc.s    V_5
IL_002f:  ldloc.s    V_5
IL_0031:  brfalse.s  IL_003c
IL_0033:  nop
IL_0034:  ldnull
IL_0035:  stloc.s    V_6
IL_0037:  leave      IL_00ec
IL_003c:  nop
IL_003d:  leave.s    IL_004b
}  // end .try
finally
{
IL_003f:  ldloc.s    V_4
IL_0041:  brfalse.s  IL_004a
IL_0043:  ldloc.3
IL_0044:  call       void [mscorlib]System.Threading.Monitor::Exit(object)
IL_0049:  nop
IL_004a:  endfinally
}  // end handler
IL_004b:  ldloc.1
IL_004c:  call       class [mscorlib]System.Reflection.Assembly Costura.AssemblyLoader::ReadExistingAssembly(class [mscorlib]System.Reflection.AssemblyName)
IL_0051:  stloc.2
IL_0052:  ldloc.2
IL_0053:  ldnull
IL_0054:  cgt.un
IL_0056:  stloc.s    V_7
IL_0058:  ldloc.s    V_7
IL_005a:  brfalse.s  IL_0065
IL_005c:  nop
IL_005d:  ldloc.2
IL_005e:  stloc.s    V_6
IL_0060:  br         IL_00ec
IL_0065:  ldstr      "Loading assembly '{0}' into the current context"
IL_006a:  ldc.i4.1
IL_006b:  newarr     [mscorlib]System.Object
IL_0070:  dup
IL_0071:  ldc.i4.0
IL_0072:  ldloc.1
IL_0073:  stelem.ref
IL_0074:  call       void Costura.AssemblyLoader::Log(string,
object[])
IL_0079:  nop
IL_007a:  ldsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> Costura.AssemblyLoader::assemblyNames
IL_007f:  ldsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> Costura.AssemblyLoader::symbolNames
IL_0084:  ldloc.1
IL_0085:  call       class [mscorlib]System.Reflection.Assembly Costura.AssemblyLoader::ReadFromEmbeddedResources(class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>,
class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>,
class [mscorlib]System.Reflection.AssemblyName)
IL_008a:  stloc.2
IL_008b:  ldloc.2
IL_008c:  ldnull
IL_008d:  ceq
IL_008f:  stloc.s    V_8
IL_0091:  ldloc.s    V_8
IL_0093:  brfalse.s  IL_00e7
IL_0095:  nop
IL_0096:  ldsfld     object Costura.AssemblyLoader::nullCacheLock
IL_009b:  stloc.s    V_9
IL_009d:  ldc.i4.0
IL_009e:  stloc.s    V_10
.try
{
IL_00a0:  ldloc.s    V_9
IL_00a2:  ldloca.s   V_10
IL_00a4:  call       void [mscorlib]System.Threading.Monitor::Enter(object,
bool&)
IL_00a9:  nop
IL_00aa:  nop
IL_00ab:  ldsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,bool> Costura.AssemblyLoader::nullCache
IL_00b0:  ldloc.0
IL_00b1:  ldc.i4.1
IL_00b2:  callvirt   instance void class [mscorlib]System.Collections.Generic.Dictionary`2<string,bool>::set_Item(!0,
!1)
IL_00b7:  nop
IL_00b8:  nop
IL_00b9:  leave.s    IL_00c8
}  // end .try
finally
{
IL_00bb:  ldloc.s    V_10
IL_00bd:  brfalse.s  IL_00c7
IL_00bf:  ldloc.s    V_9
IL_00c1:  call       void [mscorlib]System.Threading.Monitor::Exit(object)
IL_00c6:  nop
IL_00c7:  endfinally
}  // end handler
IL_00c8:  ldloc.1
IL_00c9:  callvirt   instance valuetype [mscorlib]System.Reflection.AssemblyNameFlags [mscorlib]System.Reflection.AssemblyName::get_Flags()
IL_00ce:  ldc.i4     0x100
IL_00d3:  and
IL_00d4:  ldc.i4.0
IL_00d5:  cgt.un
IL_00d7:  stloc.s    V_11
IL_00d9:  ldloc.s    V_11
IL_00db:  brfalse.s  IL_00e6
IL_00dd:  nop
IL_00de:  ldloc.1
IL_00df:  call       class [mscorlib]System.Reflection.Assembly [mscorlib]System.Reflection.Assembly::Load(class [mscorlib]System.Reflection.AssemblyName)
IL_00e4:  stloc.2
IL_00e5:  nop
IL_00e6:  nop
IL_00e7:  ldloc.2
IL_00e8:  stloc.s    V_6
IL_00ea:  br.s       IL_00ec
IL_00ec:  ldloc.s    V_6
IL_00ee:  ret
}
.method private hidebysig specialname rtspecialname static
void  .cctor() cil managed
{
.maxstack  3
IL_0000:  newobj     instance void [mscorlib]System.Object::.ctor()
IL_0005:  stsfld     object Costura.AssemblyLoader::nullCacheLock
IL_000a:  newobj     instance void class [mscorlib]System.Collections.Generic.Dictionary`2<string,bool>::.ctor()
IL_000f:  stsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,bool> Costura.AssemblyLoader::nullCache
IL_0014:  newobj     instance void class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>::.ctor()
IL_0019:  stsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> Costura.AssemblyLoader::assemblyNames
IL_001e:  newobj     instance void class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>::.ctor()
IL_0023:  stsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> Costura.AssemblyLoader::symbolNames
IL_0028:  ldsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> Costura.AssemblyLoader::assemblyNames
IL_002d:  ldstr      "assemblytoreference"
IL_0032:  ldstr      "costura.assemblytoreference.dll.compressed"
IL_0037:  callvirt   instance void class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>::Add(!0,
!1)
IL_003c:  ldsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> Costura.AssemblyLoader::symbolNames
IL_0041:  ldstr      "assemblytoreference"
IL_0046:  ldstr      "costura.assemblytoreference.pdb.compressed"
IL_004b:  callvirt   instance void class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>::Add(!0,
!1)
IL_0050:  ldsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> Costura.AssemblyLoader::assemblyNames
IL_0055:  ldstr      "assemblytoreferencepreembedded"
IL_005a:  ldstr      "costura.assemblytoreferencepreembedded.dll"
IL_005f:  callvirt   instance void class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>::Add(!0,
!1)
IL_0064:  ldsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> Costura.AssemblyLoader::symbolNames
IL_0069:  ldstr      "assemblytoreferencepreembedded"
IL_006e:  ldstr      "costura.assemblytoreferencepreembedded.pdb.compres"
+ "sed"
IL_0073:  callvirt   instance void class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>::Add(!0,
!1)
IL_0078:  ldsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> Costura.AssemblyLoader::assemblyNames
IL_007d:  ldstr      "exetoreference"
IL_0082:  ldstr      "costura.exetoreference.exe.compressed"
IL_0087:  callvirt   instance void class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>::Add(!0,
!1)
IL_008c:  ldsfld     class [mscorlib]System.Collections.Generic.Dictionary`2<string,string> Costura.AssemblyLoader::symbolNames
IL_0091:  ldstr      "exetoreference"
IL_0096:  ldstr      "costura.exetoreference.pdb.compressed"
IL_009b:  callvirt   instance void class [mscorlib]System.Collections.Generic.Dictionary`2<string,string>::Add(!0,
!1)
IL_00a0:  ret
}
.method public hidebysig static void  Attach(bool subscribe) cil managed
{
.maxstack  3
.locals init (bool V_0,
bool V_1,
class [mscorlib]System.AppDomain V_2)
IL_0000:  nop
IL_0001:  ldsflda    int32 Costura.AssemblyLoader::isAttached
IL_0006:  ldc.i4.1
IL_0007:  call       int32 [mscorlib]System.Threading.Interlocked::Exchange(int32&,
int32)
IL_000c:  ldc.i4.1
IL_000d:  ceq
IL_000f:  stloc.0
IL_0010:  ldloc.0
IL_0011:  brfalse.s  IL_0016
IL_0013:  nop
IL_0014:  br.s       IL_0045
IL_0016:  ldarg.0
IL_0017:  stloc.1
IL_0018:  ldloc.1
IL_0019:  brfalse.s  IL_0045
IL_001b:  nop
IL_001c:  call       class [mscorlib]System.AppDomain [mscorlib]System.AppDomain::get_CurrentDomain()
IL_0021:  stloc.2
IL_0022:  ldloc.2
IL_0023:  ldsfld     class [mscorlib]System.ResolveEventHandler Costura.AssemblyLoader/'<>O'::'<0>__ResolveAssembly'
IL_0028:  dup
IL_0029:  brtrue.s   IL_003e
IL_002b:  pop
IL_002c:  ldnull
IL_002d:  ldftn      class [mscorlib]System.Reflection.Assembly Costura.AssemblyLoader::ResolveAssembly(object,
class [mscorlib]System.ResolveEventArgs)
IL_0033:  newobj     instance void [mscorlib]System.ResolveEventHandler::.ctor(object,
native int)
IL_0038:  dup
IL_0039:  stsfld     class [mscorlib]System.ResolveEventHandler Costura.AssemblyLoader/'<>O'::'<0>__ResolveAssembly'
IL_003e:  callvirt   instance void [mscorlib]System.AppDomain::add_AssemblyResolve(class [mscorlib]System.ResolveEventHandler)
IL_0043:  nop
IL_0044:  nop
IL_0045:  ret
}
}