File tree Expand file tree Collapse file tree 6 files changed +9
-9
lines changed
Microsoft.AspNetCore.Razor.Language
Microsoft.CodeAnalysis.Razor/src Expand file tree Collapse file tree 6 files changed +9
-9
lines changed Original file line number Diff line number Diff line change 1- // Licensed to the .NET Foundation under one or more agreements.
1+ // Licensed to the .NET Foundation under one or more agreements.
22// The .NET Foundation licenses this file to you under the MIT license.
33
44using System ;
@@ -69,7 +69,7 @@ public override bool Equals(RazorDiagnostic obj)
6969
7070 public override int GetHashCode ( )
7171 {
72- var hash = new HashCodeCombiner ( ) ;
72+ var hash = HashCodeCombiner . Start ( ) ;
7373 hash . Add ( Descriptor . GetHashCode ( ) ) ;
7474 hash . Add ( Span . GetHashCode ( ) ) ;
7575
Original file line number Diff line number Diff line change @@ -94,7 +94,7 @@ public virtual bool Equals(RazorConfiguration other)
9494
9595 public override int GetHashCode ( )
9696 {
97- var hash = new HashCodeCombiner ( ) ;
97+ var hash = HashCodeCombiner . Start ( ) ;
9898 hash . Add ( LanguageVersion ) ;
9999 hash . Add ( ConfigurationName ) ;
100100
Original file line number Diff line number Diff line change @@ -125,7 +125,7 @@ public override bool Equals(object obj)
125125
126126 public override int GetHashCode ( )
127127 {
128- var hash = new HashCodeCombiner ( ) ;
128+ var hash = HashCodeCombiner . Start ( ) ;
129129 hash . Add ( Span ) ;
130130 hash . Add ( NewText , StringComparer . Ordinal ) ;
131131 return hash ;
Original file line number Diff line number Diff line change @@ -229,7 +229,7 @@ public override bool Equals(object obj)
229229 /// </summary>
230230 public override int GetHashCode ( )
231231 {
232- var combiner = new HashCodeCombiner ( ) ;
232+ var combiner = HashCodeCombiner . Start ( ) ;
233233 combiner . Add ( Start ) ;
234234 combiner . Add ( Length ) ;
235235
Original file line number Diff line number Diff line change @@ -10,8 +10,8 @@ public class HashCodeCombinerTest
1010 [ Fact ]
1111 public void GivenTheSameInputs_ItProducesTheSameOutput ( )
1212 {
13- var hashCode1 = new HashCodeCombiner ( ) ;
14- var hashCode2 = new HashCodeCombiner ( ) ;
13+ var hashCode1 = HashCodeCombiner . Start ( ) ;
14+ var hashCode2 = HashCodeCombiner . Start ( ) ;
1515
1616 hashCode1 . Add ( 42 ) ;
1717 hashCode1 . Add ( "foo" ) ;
Original file line number Diff line number Diff line change 1- // Licensed to the .NET Foundation under one or more agreements.
1+ // Licensed to the .NET Foundation under one or more agreements.
22// The .NET Foundation licenses this file to you under the MIT license.
33
44using System ;
@@ -40,7 +40,7 @@ public override int GetHashCode(AssemblyIdentity obj)
4040 return 0 ;
4141 }
4242
43- var hash = new HashCodeCombiner ( ) ;
43+ var hash = HashCodeCombiner . Start ( ) ;
4444 hash . Add ( obj . Name , StringComparer . OrdinalIgnoreCase ) ;
4545 hash . Add ( obj . Version ) ;
4646 return hash ;
You can’t perform that action at this time.
0 commit comments