diff options
Diffstat (limited to 'src/mscorlib/src/System/Reflection/Emit/Label.cs')
-rw-r--r-- | src/mscorlib/src/System/Reflection/Emit/Label.cs | 38 |
1 files changed, 21 insertions, 17 deletions
diff --git a/src/mscorlib/src/System/Reflection/Emit/Label.cs b/src/mscorlib/src/System/Reflection/Emit/Label.cs index c7b987ff10..f6315a67d2 100644 --- a/src/mscorlib/src/System/Reflection/Emit/Label.cs +++ b/src/mscorlib/src/System/Reflection/Emit/Label.cs @@ -13,11 +13,13 @@ ** ** ===========================================================*/ -namespace System.Reflection.Emit { - using System; - using System.Reflection; - using System.Runtime.InteropServices; +using System; +using System.Reflection; +using System.Runtime.InteropServices; + +namespace System.Reflection.Emit +{ // The Label class is an opaque representation of a label used by the // ILGenerator class. The token is used to mark where labels occur in the IL // stream and then the necessary offsets are put back in the code when the ILGenerator @@ -25,27 +27,29 @@ namespace System.Reflection.Emit { // Labels are created by using ILGenerator.CreateLabel and their position is set // by using ILGenerator.MarkLabel. [Serializable] - public struct Label { - + public struct Label + { internal int m_label; - + //public Label() { // m_label=0; //} - - internal Label (int label) { - m_label=label; + + internal Label(int label) + { + m_label = label; } - - internal int GetLabelValue() { + + internal int GetLabelValue() + { return m_label; } - + public override int GetHashCode() { return m_label; } - + public override bool Equals(Object obj) { if (obj is Label) @@ -53,17 +57,17 @@ namespace System.Reflection.Emit { else return false; } - + public bool Equals(Label obj) { return obj.m_label == m_label; } - + public static bool operator ==(Label a, Label b) { return a.Equals(b); } - + public static bool operator !=(Label a, Label b) { return !(a == b); |