Skip to content

Commit 181ddf9

Browse files
committed
Removed Join method.
1 parent 4a231ab commit 181ddf9

2 files changed

Lines changed: 9 additions & 13 deletions

File tree

‎ReClass.NET/Extensions/LinqExtensions.cs‎

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using System;
1+
using System;
22
using System.Collections.Generic;
33
using System.Diagnostics;
44
using System.Diagnostics.Contracts;
@@ -8,16 +8,6 @@ namespace ReClassNET.Extensions
88
{
99
public static class LinqExtension
1010
{
11-
public static string Join(this IEnumerable<string> source)
12-
{
13-
return Join(source, string.Empty);
14-
}
15-
16-
public static string Join(this IEnumerable<string> source, string separator)
17-
{
18-
return string.Join(separator, source);
19-
}
20-
2111
public static TResult Max<TSource, TResult>(this IEnumerable<TSource> source, Func<TSource, TResult> selector, IComparer<TResult> comparer)
2212
{
2313
comparer = comparer ?? Comparer<TResult>.Default;

‎ReClass.NET/Util/Rtf/RtfBuilder.cs‎

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -218,11 +218,17 @@ public override string ToString()
218218
sb.Append(@"{\rtf1\ansi\ansicpg1252\deff0\deflang3081");
219219

220220
sb.Append(@"{\fonttbl");
221-
sb.Append(usedFonts.Select((f, i) => string.Format(f, i)).Join());
221+
for (var i = 0; i < usedFonts.Count; ++i)
222+
{
223+
sb.AppendFormat(usedFonts[i], i);
224+
}
222225
sb.AppendLine("}");
223226

224227
sb.Append(@"{\colortbl ;");
225-
sb.Append(usedColors.Select(c => $@"\red{c.R}\green{c.G}\blue{c.B};").Join());
228+
foreach (var color in usedColors)
229+
{
230+
sb.Append($@"\red{color.R}\green{color.G}\blue{color.B};");
231+
}
226232
sb.AppendLine("}");
227233

228234
sb.Append(@"\viewkind4\uc1\pard\plain\f0");

0 commit comments

Comments
 (0)