Ferrous.Results 3.1.0

dotnet add package Ferrous.Results --version 3.1.0
                    
NuGet\Install-Package Ferrous.Results -Version 3.1.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Ferrous.Results" Version="3.1.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Ferrous.Results" Version="3.1.0" />
                    
Directory.Packages.props
<PackageReference Include="Ferrous.Results" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Ferrous.Results --version 3.1.0
                    
#r "nuget: Ferrous.Results, 3.1.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Ferrous.Results@3.1.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Ferrous.Results&version=3.1.0
                    
Install as a Cake Addin
#tool nuget:?package=Ferrous.Results&version=3.1.0
                    
Install as a Cake Tool

Ferrous.Results

Allocation-free readonly struct Result<T, TError> and Option<T> types for .NET inspired by Rust—with explicit uninitialized-default protection, NativeAOT/trimming compatibility, and [MustUse] integration.

Installation

dotnet add package Ferrous.Results

Quick Example

using Ferrous.Results;

Result<int, string> ParsePort(string input) =>
    int.TryParse(input, out int port) && port is > 0 and <= 65535
        ? Result.Ok<int, string>(port)
        : Result.Err<int, string>($"Invalid port: {input}");

string status = ParsePort("8080")
    .Map(p => p + 1)
    .Match(
        onOk: p => $"Listening on {p}",
        onErr: err => $"Failed: {err}");

See the Results & Options Guide and ferrous.westness.cc for full documentation.

Product Compatible and additional computed target framework versions.
.NET 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.  net11.0 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (5)

Showing the top 5 NuGet packages that depend on Ferrous.Results:

Package Downloads
Ferrous

Rust-grade compile-time safety, zero-allocation primitives, source generators, and 70 rustc-style Roslyn analyzers (FE0001–FE0508) for strict .NET 10 & .NET 11 builds and AI coding agents.

Ferrous.AspNetCore

ASP.NET Core Minimal API integrations for Ferrous: Result/Option to RFC 7807 ProblemDetails IResult mapping and automatic endpoint filter unwrapping.

Ferrous.EntityFrameworkCore

Entity Framework Core integrations for Ferrous: ValueConverters for NonEmptyString, NonZero<T>, and [Newtype] structs, plus Result/Option-returning async query helpers.

Ferrous.Http

Exception-free outbound HttpClient extensions for Ferrous returning Task<Result<T, HttpError>> with zero-boxing [DiscriminatedUnion] HttpError and NativeAOT JsonTypeInfo overloads.

Ferrous.Testing

Rust-grade testing utilities for .NET: in-memory compile-fail assertions (CompileAssert, like Rust's trybuild), property-based testing (PropAssert/Gen), framework-agnostic Result/Option assertions, and zero-allocation assertions (AllocAssert).

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
3.1.0 0 12/1/2026
3.0.1 0 12/1/2026
3.0.0 0 11/30/2026
2.8.1 0 11/30/2026
2.8.0 0 11/30/2026
2.7.0 0 11/30/2026
2.6.0 0 11/30/2026
2.4.2 0 11/30/2026
2.4.1 0 11/30/2026
2.4.0 0 11/30/2026
2.3.0 0 11/30/2026
2.2.0 0 11/30/2026
2.1.0 0 11/30/2026
2.0.0 0 11/30/2026
1.7.4 0 11/30/2026
1.7.3 0 11/30/2026
1.7.2 0 11/30/2026
1.7.1 0 11/30/2026
1.7.0 0 11/30/2026
1.6.0 0 11/30/2026
Loading failed