Skip to content

Commit

Permalink
just disable the damn thing
Browse files Browse the repository at this point in the history
  • Loading branch information
benjamin-hodgson authored Nov 16, 2023
1 parent 7dc09a9 commit 9084d5b
Show file tree
Hide file tree
Showing 26 changed files with 48 additions and 10 deletions.
5 changes: 0 additions & 5 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,5 @@ tab_width = 4
end_of_line = lf
insert_final_newline = true

[*.cs]
# seemingly a bug in `dotnet format`
dotnet_sort_system_directives_first = false
dotnet_separate_import_directive_groups = false

[*.Generated.cs]
generated_code = true
2 changes: 2 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ jobs:
uses: benjamin-hodgson/BuildScripts/.github/workflows/dotnet.yml@main
with:
DOCS_FOLDER: Pidgin.Docs
# due to a bug in `dotnet format` with `using static`
CHECK_FORMATTING: false
NET8: true
secrets:
NUGET_KEY: ${{ secrets.NUGET_KEY }}
2 changes: 1 addition & 1 deletion Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
</ItemGroup>

<ItemGroup>
<GlobalPackageReference Include="Benjamin.Pizza.BuildScripts" Version="2.2.4" />
<GlobalPackageReference Include="Benjamin.Pizza.BuildScripts" Version="2.2.2" />
<GlobalPackageReference Include="StyleCop.Analyzers" Version="1.1.118" />
</ItemGroup>

Expand Down
3 changes: 3 additions & 0 deletions Pidgin.Bench/ExpressionBench.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
using System;
using System.Diagnostics.CodeAnalysis;
using System.Linq;

using BenchmarkDotNet.Attributes;
using BenchmarkDotNet.Configs;

using Pidgin.Expression;

using static Pidgin.Parser<char>;

namespace Pidgin.Bench;
Expand Down
2 changes: 2 additions & 0 deletions Pidgin.Bench/JsonBench.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,10 @@
using System.Collections.Immutable;
using System.Diagnostics.CodeAnalysis;
using System.Linq;

using BenchmarkDotNet.Attributes;
using BenchmarkDotNet.Configs;

using Pidgin.Bench.SpracheParsers;
using Pidgin.Bench.SuperpowerParsers;
using Pidgin.Examples.Json;
Expand Down
1 change: 1 addition & 0 deletions Pidgin.Bench/NumberBench.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using System;
using System.Diagnostics.CodeAnalysis;

using BenchmarkDotNet.Attributes;

namespace Pidgin.Bench;
Expand Down
3 changes: 3 additions & 0 deletions Pidgin.Bench/SpracheParsers/SpracheJsonParser.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
using System.Collections.Generic;
using System.Collections.Immutable;

using Pidgin.Examples.Json;

using Sprache;

using static Sprache.Parse;

namespace Pidgin.Bench.SpracheParsers;
Expand Down
1 change: 1 addition & 0 deletions Pidgin.Bench/StringBench.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using System.Diagnostics.CodeAnalysis;

using BenchmarkDotNet.Attributes;

namespace Pidgin.Bench;
Expand Down
2 changes: 2 additions & 0 deletions Pidgin.Bench/SuperpowerParsers/SuperpowerJsonParser.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
using System.Collections.Generic;
using System.Collections.Immutable;

using Pidgin.Examples.Json;

using Superpower;
using Superpower.Parsers;

Expand Down
2 changes: 2 additions & 0 deletions Pidgin.Examples/Expression/ExprParser.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
using System;
using System.Collections.Immutable;

using Pidgin.Expression;

using static Pidgin.Parser;

namespace Pidgin.Examples.Expression;
Expand Down
1 change: 1 addition & 0 deletions Pidgin.Examples/Json/JsonParser.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using System.Collections.Generic;
using System.Collections.Immutable;

using static Pidgin.Parser;
using static Pidgin.Parser<char>;

Expand Down
1 change: 1 addition & 0 deletions Pidgin.Examples/Xml/XmlParser.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using System.Linq;

using static Pidgin.Parser;
using static Pidgin.Parser<char>;

Expand Down
2 changes: 2 additions & 0 deletions Pidgin.Tests/CommentParserTests.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
using Pidgin.Comment;

using Xunit;

using static Pidgin.Parser;
using static Pidgin.Parser<char>;

Expand Down
2 changes: 2 additions & 0 deletions Pidgin.Tests/DocumentationTests.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
using System.Threading.Tasks;

using Benjamin.Pizza.DocTest;

using Xunit;

namespace Pidgin.Tests;
Expand Down
8 changes: 4 additions & 4 deletions Pidgin.Tests/ExpressionExampleTests.cs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
using System.Collections.Immutable;

using Pidgin.Examples.Expression;

using Xunit;
Expand All @@ -23,10 +25,8 @@ public void TestExpression()
new Call(
new Call(
new Identifier("foo"),
[
new UnaryOp(UnaryOperatorType.Neg, new Literal(3)),
new Identifier("x")
]
[new UnaryOp(UnaryOperatorType.Neg, new Literal(3)), new Identifier("x")

Check failure on line 28 in Pidgin.Tests/ExpressionExampleTests.cs

View workflow job for this annotation

GitHub Actions / build / build

]
),
[]
),
Expand Down
3 changes: 3 additions & 0 deletions Pidgin.Tests/ExpressionParserTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,11 @@
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.Linq;

using Pidgin.Expression;

using Xunit;

using static Pidgin.Parser;
using static Pidgin.Parser<char>;

Expand Down
2 changes: 2 additions & 0 deletions Pidgin.Tests/ParseStateTests.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
using System;
using System.IO;
using System.Numerics;

using Pidgin.Configuration;
using Pidgin.TokenStreams;

using Xunit;

namespace Pidgin.Tests;
Expand Down
2 changes: 2 additions & 0 deletions Pidgin.Tests/ResumableTokenStreamTests.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
using System;
using System.IO;

using Pidgin.TokenStreams;

using Xunit;

namespace Pidgin.Tests;
Expand Down
4 changes: 4 additions & 0 deletions Pidgin.Tests/StringParserTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
using System.Collections.Immutable;
using System.Linq;
using System.Text;

using Xunit;

using static Pidgin.Parser;
using static Pidgin.Parser<char>;

Expand Down Expand Up @@ -1128,6 +1130,7 @@ public void TestCIOneOf()
new Expected<char>(ImmutableArray.Create('B')),
new Expected<char>(ImmutableArray.Create('c')),
new Expected<char>(ImmutableArray.Create('C'))
,

Check failure on line 1133 in Pidgin.Tests/StringParserTests.cs

View workflow job for this annotation

GitHub Actions / build / build

],
0,
SourcePosDelta.Zero,
Expand Down Expand Up @@ -1157,6 +1160,7 @@ public void TestCIOneOf()
new Expected<char>(ImmutableArray.Create('B')),
new Expected<char>(ImmutableArray.Create('c')),
new Expected<char>(ImmutableArray.Create('C'))
,

Check failure on line 1163 in Pidgin.Tests/StringParserTests.cs

View workflow job for this annotation

GitHub Actions / build / build

],
0,
SourcePosDelta.Zero,
Expand Down
1 change: 1 addition & 0 deletions Pidgin.Tests/TryTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,7 @@ [new Expected<TToken>(ImmutableArray.CreateRange(render("foobat")))],
[

Check failure on line 214 in Pidgin.Tests/TryTests.cs

View workflow job for this annotation

GitHub Actions / build / build

new Expected<TToken>(ImmutableArray.CreateRange(render("foo"))),
new Expected<TToken>(ImmutableArray.CreateRange(render("foobat")))
,

Check failure on line 217 in Pidgin.Tests/TryTests.cs

View workflow job for this annotation

GitHub Actions / build / build

],
0,
SourcePosDelta.Zero,
Expand Down
3 changes: 3 additions & 0 deletions Pidgin.Tests/XmlTest.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
using System;

using Pidgin.Examples.Xml;

using Xunit;

using Attribute = Pidgin.Examples.Xml.Attribute;

namespace Pidgin.Tests;
Expand Down
1 change: 1 addition & 0 deletions Pidgin/ParseState.ComputeSourcePos.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using System;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

using Pidgin.Configuration;

namespace Pidgin;
Expand Down
1 change: 1 addition & 0 deletions Pidgin/ParseState.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
using System.ComponentModel;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

using Pidgin.Configuration;

namespace Pidgin;
Expand Down
1 change: 1 addition & 0 deletions Pidgin/Parser.Chain.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using System;
using System.Diagnostics.CodeAnalysis;

using Pidgin.Configuration;

namespace Pidgin;
Expand Down
1 change: 1 addition & 0 deletions Pidgin/Parser.Configuration.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using System.Diagnostics.CodeAnalysis;

using Pidgin.Configuration;

namespace Pidgin;
Expand Down
2 changes: 2 additions & 0 deletions Pidgin/ParserExtensions.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
using System;
using System.Collections.Generic;
using System.IO;

using Pidgin.Configuration;
using Pidgin.TokenStreams;

using Config = Pidgin.Configuration.Configuration;

namespace Pidgin;
Expand Down

0 comments on commit 9084d5b

Please sign in to comment.