File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
sandbox/PerfBenchmarkDotNet Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 44extern alias newmsgpack ;
55extern alias oldmsgpack ;
66
7+ using System ;
78using BenchmarkDotNet . Attributes ;
89using BenchmarkDotNet . Configs ;
910using Nerdbank . Streams ;
@@ -12,7 +13,7 @@ namespace PerfBenchmarkDotNet
1213{
1314 [ GroupBenchmarksBy ( BenchmarkLogicalGroupRule . ByCategory ) ]
1415 [ CategoriesColumn ]
15- public class MessagePackWriterBenchmark
16+ public sealed class MessagePackWriterBenchmark : IDisposable
1617 {
1718 private const int RepsOverArray = 300 * 1024 ;
1819 private readonly Sequence < byte > sequence = new Sequence < byte > ( ) ;
@@ -148,5 +149,10 @@ public void WriteString()
148149 offset = 0 ;
149150 }
150151 }
152+
153+ public void Dispose ( )
154+ {
155+ this . sequence . Dispose ( ) ;
156+ }
151157 }
152158}
You can’t perform that action at this time.
0 commit comments