tl-expected
« Back to VersTracker
Description:
C++11/14/17 std::expected with functional-style extensions
Type: Formula  |  Tracked Since: Dec 28, 2025
Links: Homepage  |  formulae.brew.sh
Category: Developer tools
Tags: c++ error-handling library functional header-only
Install: brew install tl-expected
About:
Tl::Expected is a C++11/14/17 library implementation of the std::expected idiom, designed for error handling without exceptions. It provides a type that either contains a value or an error, enabling expressive and safe functional-style error propagation. The library includes extensions beyond the standard proposal, such as support for unexpected types and monadic operations.
Key Features:
  • C++11/14/17 compatible implementation
  • Monadic operations for error handling (and_then, transform, or_else)
  • No exceptions or dynamic memory allocation required
  • Header-only library for easy integration
Use Cases:
  • Error handling in performance-critical or embedded C++ applications
  • Refactoring legacy codebases to use modern, exception-free error propagation
  • Functional-style programming in C++ for better code readability and safety
Alternatives:
  • std::expected (C++23) – Standard library version requires C++23; tl::expected provides backward compatibility and additional extensions.
  • Boost.Outcome – Heavier dependency with broader features; tl::expected is lighter and header-only.
Version History
Detected Version Rev Change Commit