Switch to compiler-tester
[mono.git] / mcs / class / corlib / System.Reflection.Emit / LocalBuilder.cs
old mode 100755 (executable)
new mode 100644 (file)
index 9588db7..5ed11d4
@@ -38,9 +38,15 @@ using System.Reflection;
 using System.Reflection.Emit;
 using System.Globalization;
 using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
 using System.Diagnostics.SymbolStore;
 
 namespace System.Reflection.Emit {
+#if NET_2_0
+       [ComVisible (true)]
+       [ClassInterfaceAttribute (ClassInterfaceType.None)]
+       [ComDefaultInterfaceAttribute (typeof (_LocalBuilder))]
+#endif
 #if NET_2_0
        public sealed class LocalBuilder : LocalVariableInfo {
 #else
@@ -62,6 +68,8 @@ namespace System.Reflection.Emit {
 #endif
                
                internal ILGenerator ilgen;
+               int startOffset;
+               int endOffset;
 
                internal LocalBuilder (Type t, ILGenerator ilgen)
                {
@@ -71,7 +79,9 @@ namespace System.Reflection.Emit {
 
                public void SetLocalSymInfo (string lname, int startOffset, int endOffset)
                {
-                       // nop
+                       name = lname;
+                       this.startOffset = startOffset;
+                       this.endOffset = endOffset;
                }
 
                public void SetLocalSymInfo (string lname)
@@ -104,5 +114,17 @@ namespace System.Reflection.Emit {
                        }
                }
 #endif
+
+               internal string Name {
+                       get { return name; }
+               }
+               
+               internal int StartOffset {
+                       get { return startOffset; }
+               }
+               
+               internal int EndOffset {
+                       get { return endOffset; }
+               }
        }
 }