We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2153355 commit 5c0220eCopy full SHA for 5c0220e
sandbox/PerfBenchmarkDotNet/MessagePackWriterBenchmark.cs
@@ -4,6 +4,7 @@
4
extern alias newmsgpack;
5
extern alias oldmsgpack;
6
7
+using System;
8
using BenchmarkDotNet.Attributes;
9
using BenchmarkDotNet.Configs;
10
using Nerdbank.Streams;
@@ -12,7 +13,7 @@ namespace PerfBenchmarkDotNet
12
13
{
14
[GroupBenchmarksBy(BenchmarkLogicalGroupRule.ByCategory)]
15
[CategoriesColumn]
- public class MessagePackWriterBenchmark
16
+ public sealed class MessagePackWriterBenchmark : IDisposable
17
18
private const int RepsOverArray = 300 * 1024;
19
private readonly Sequence<byte> sequence = new Sequence<byte>();
@@ -148,5 +149,10 @@ public void WriteString()
148
149
offset = 0;
150
}
151
152
+
153
+ public void Dispose()
154
+ {
155
+ this.sequence.Dispose();
156
+ }
157
158
0 commit comments