Fix compilation of array initializer used inside field initializer of an anonymous...
[mono.git] / mcs / mcs / symbolwriter.cs
index bfe58d02fa4f84569a178273e1e5e663776e8db9..ce19cfc492acb6c54b129d1e6a6d915c8e7d134b 100644 (file)
 //
 
 using System;
+
+#if STATIC
+using IKVM.Reflection;
+using IKVM.Reflection.Emit;
+#else
 using System.Reflection;
 using System.Reflection.Emit;
+#endif
 
 using Mono.CompilerServices.SymbolWriter;
 
@@ -20,7 +26,7 @@ namespace Mono.CSharp
 {
        static class SymbolWriter
        {
-#if !NET_4_0
+#if !NET_4_0 && !STATIC
                delegate int GetILOffsetFunc (ILGenerator ig);
                static GetILOffsetFunc get_il_offset_func;
 
@@ -51,7 +57,7 @@ namespace Mono.CSharp
 
                static int GetILOffset (ILGenerator ig)
                {
-#if NET_4_0
+#if NET_4_0 || STATIC
                        return ig.ILOffset;
 #else
                        if (get_il_offset_func == null)
@@ -63,7 +69,7 @@ namespace Mono.CSharp
 
                public static Guid GetGuid (ModuleBuilder module)
                {
-#if NET_4_0
+#if NET_4_0 || STATIC
                        return module.ModuleVersionId;
 #else
                        if (get_guid_func == null)