@@ -210,7 +210,6 @@ internal MessagePackObject( MessagePackString messagePackString )
210210 public override bool Equals ( Object obj )
211211 {
212212 MessagePackObjectDictionary asDictionary ;
213- // ReSharper disable RedundantIfElseBlock
214213 if ( ReferenceEquals ( obj , null ) )
215214 {
216215 return this . IsNil ;
@@ -227,7 +226,6 @@ public override bool Equals( Object obj )
227226 {
228227 return this . Equals ( ( MessagePackObject ) obj ) ;
229228 }
230- // ReSharper restore RedundantIfElseBlock
231229 }
232230
233231 /// <summary>
@@ -239,7 +237,6 @@ public override bool Equals( Object obj )
239237 /// </returns>
240238 public bool Equals ( MessagePackObject other )
241239 {
242- // ReSharper disable RedundantIfElseBlock
243240 if ( this . _handleOrTypeCode == null )
244241 {
245242 return other . _handleOrTypeCode == null ;
@@ -315,7 +312,6 @@ public bool Equals( MessagePackObject other )
315312 return true ;
316313 }
317314 }
318- // ReSharper restore RedundantIfElseBlock
319315
320316 {
321317 var asExtendedTypeObjectBody = this . _handleOrTypeCode as byte [ ] ;
@@ -411,7 +407,6 @@ private bool EqualsWhenValueType(
411407
412408 private static bool IntegerIntegerEquals ( ulong left , ValueTypeCode leftTypeCode , ulong right , ValueTypeCode rightTypeCode )
413409 {
414- // ReSharper disable RedundantIfElseBlock
415410 if ( leftTypeCode . IsSigned )
416411 {
417412 if ( rightTypeCode . IsSigned )
@@ -446,7 +441,6 @@ private static bool IntegerIntegerEquals( ulong left, ValueTypeCode leftTypeCode
446441 return left == right ;
447442 }
448443 }
449- // ReSharper restore RedundantIfElseBlock
450444 }
451445
452446 private static bool IntegerSingleEquals ( MessagePackObject integer , MessagePackObject real )
@@ -458,7 +452,6 @@ private static bool IntegerSingleEquals( MessagePackObject integer, MessagePackO
458452 {
459453 return unchecked ( ( long ) integer . _value ) == ( float ) real ;
460454 }
461- // ReSharper disable once RedundantIfElseBlock
462455 else
463456 {
464457 return integer . _value == ( float ) real ;
@@ -474,7 +467,6 @@ private static bool IntegerDoubleEquals( MessagePackObject integer, MessagePackO
474467 {
475468 return unchecked ( ( long ) integer . _value ) == ( double ) real ;
476469 }
477- // ReSharper disable once RedundantIfElseBlock
478470 else
479471 {
480472 return integer . _value == ( double ) real ;
@@ -1010,7 +1002,6 @@ public Type UnderlyingType
10101002 }
10111003
10121004 var typeCode = this . _handleOrTypeCode as ValueTypeCode ;
1013- // ReSharper disable RedundantIfElseBlock
10141005 if ( typeCode == null )
10151006 {
10161007 var asMps = this . _handleOrTypeCode as MessagePackString ;
@@ -1027,7 +1018,6 @@ public Type UnderlyingType
10271018 {
10281019 return typeCode . Type ;
10291020 }
1030- // ReSharper restore RedundantIfElseBlock
10311021 }
10321022 }
10331023
@@ -1262,7 +1252,6 @@ public string AsStringUtf16()
12621252 throw new InvalidOperationException ( "Not UTF-16 string." ) ;
12631253 }
12641254
1265- // ReSharper disable RedundantIfElseBlock
12661255 if ( asBytes [ 0 ] == 0xff && asBytes [ 1 ] == 0xfe )
12671256 {
12681257 return Encoding . Unicode . GetString ( asBytes , 2 , asBytes . Length - 2 ) ;
@@ -1275,7 +1264,6 @@ public string AsStringUtf16()
12751264 {
12761265 return Encoding . BigEndianUnicode . GetString ( asBytes , 0 , asBytes . Length ) ;
12771266 }
1278- // ReSharper restore RedundantIfElseBlock
12791267 }
12801268 catch ( ArgumentException ex )
12811269 {
@@ -1362,7 +1350,6 @@ private static void VerifyUnderlyingType<T>( MessagePackObject instance, string
13621350 {
13631351 throw new ArgumentException ( String . Format ( CultureInfo . CurrentCulture , "Do not convert nil MessagePackObject to {0}." , typeof ( T ) ) , parameterName ) ;
13641352 }
1365- // ReSharper disable once RedundantIfElseBlock
13661353 else
13671354 {
13681355 ThrowCannotBeNilAs < T > ( ) ;
@@ -1375,7 +1362,6 @@ private static void VerifyUnderlyingType<T>( MessagePackObject instance, string
13751362 {
13761363 throw new ArgumentException ( String . Format ( CultureInfo . CurrentCulture , "Do not convert {0} MessagePackObject to {1}." , instance . UnderlyingType , typeof ( T ) ) , parameterName ) ;
13771364 }
1378- // ReSharper disable once RedundantIfElseBlock
13791365 else
13801366 {
13811367 ThrowInvalidTypeAs < T > ( instance ) ;
@@ -1394,7 +1380,6 @@ private static void ThrowInvalidTypeAs<T>( MessagePackObject instance )
13941380 {
13951381 throw new InvalidOperationException ( String . Format ( CultureInfo . CurrentCulture , "Do not convert {0} (binary:0x{2:x}) MessagePackObject to {1}." , instance . UnderlyingType , typeof ( T ) , instance . _value ) ) ;
13961382 }
1397- // ReSharper disable once RedundantIfElseBlock
13981383 else
13991384 {
14001385 throw new InvalidOperationException ( String . Format ( CultureInfo . CurrentCulture , "Do not convert {0} MessagePackObject to {1}." , instance . UnderlyingType , typeof ( T ) ) ) ;
@@ -1423,7 +1408,6 @@ public static MessagePackObject FromObject( object boxedValue )
14231408
14241409 // Nullable<T> is boxed as null or underlying value type,
14251410 // so ( obj is Nullable<T> ) is always false.
1426- // ReSharper disable RedundantIfElseBlock
14271411 if ( boxedValue == null )
14281412 {
14291413 return Nil ;
@@ -1512,7 +1496,6 @@ public static MessagePackObject FromObject( object boxedValue )
15121496 {
15131497 return new MessagePackObject ( ( MessagePackExtendedTypeObject ) boxedValue ) ;
15141498 }
1515- // ReSharper restore RedundantIfElseBlock
15161499
15171500 throw new MessageTypeException ( String . Format ( CultureInfo . CurrentCulture , "Type '{0}' is not supported." , boxedValue . GetType ( ) ) ) ;
15181501 }
0 commit comments