Farkle 7.1.0
dotnet add package Farkle --version 7.1.0
NuGet\Install-Package Farkle -Version 7.1.0
<PackageReference Include="Farkle" Version="7.1.0" />
<PackageVersion Include="Farkle" Version="7.1.0" />
<PackageReference Include="Farkle" />
paket add Farkle --version 7.1.0
#r "nuget: Farkle, 7.1.0"
#:package Farkle@7.1.0
#addin nuget:?package=Farkle&version=7.1.0
#tool nuget:?package=Farkle&version=7.1.0
Farkle
Farkle is a .NET library for building fast, reliable text parsers in F# and C#. It creates LALR(1) and IELR(1) parsers through an API that resembles parser combinators, letting you define grammars directly in source code without requiring a separate grammar definition language.
Farkle can also generate parsing tables at build time, providing fast startup performance on par with generated parsers, and compile-time grammar validation. Check out the Farkle.Tools.MSBuild package for more information.
Quick Start
C#
using Farkle;
using Farkle.Builder;
var number = Terminals.Int32("Number");
var expression = Nonterminal.Create("Addition",
number.Extended().Append("+").Extend(number).Finish((left, right) => left + right)
);
var parser = expression.Build();
var result = parser.Parse("1 + 2"); // Whitespace is ignored by default.
Console.WriteLine(result); // 3
F#
open Farkle
open Farkle.Builder
let number = Terminals.Int32("Number")
let expression = "Addition" ||= [
!@ number .>> "+" .>>. number => (fun left right -> left + right)
]
let parser = GrammarBuilder.build expression
let result = CharParser.parseString parser "1 + 2" // Whitespace is ignored by default.
printfn "%O" result // 3
Documentation
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- BitCollections (>= 1.0.1)
-
net8.0
- BitCollections (>= 1.0.1)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 7.1.0 | 171 | 9/27/2026 |
| 7.0.1 | 730 | 7/9/2026 |
| 7.0.0 | 229 | 6/28/2026 |
| 7.0.0-preview.3 | 79 | 5/18/2026 |
| 7.0.0-preview.2 | 224 | 10/30/2025 |
| 7.0.0-preview.1 | 171 | 9/6/2025 |
| 6.5.2 | 28,537 | 11/10/2024 |
| 6.5.1 | 30,908 | 1/25/2023 |
| 6.5.0 | 663 | 9/8/2022 |
| 6.4.0 | 882 | 3/11/2022 |
| 6.3.2 | 648 | 10/31/2021 |
| 6.3.1 | 569 | 10/18/2021 |
| 6.3.0 | 628 | 10/3/2021 |
| 6.2.0 | 654 | 5/16/2021 |
| 6.1.0 | 608 | 3/4/2021 |
| 6.0.0 | 637 | 2/22/2021 |
| 6.0.0-alpha.3 | 407 | 11/25/2020 |
| 6.0.0-alpha.2 | 493 | 8/22/2020 |
| 6.0.0-alpha.1 | 474 | 4/13/2020 |
| 5.4.1 | 901 | 3/23/2020 |
You can see information about the latest releases on https://github.com/teo-tsirpanis/Farkle/releases