matchr: Pattern Matching and Enumerated Types in R

Inspired by pattern matching and enum types in Rust and many functional programming languages, this package offers an updated version of the 'switch' function called 'Match' that accepts atomic values, functions, expressions, and enum variants. Conditions and return expressions are separated by '->' and multiple conditions can be associated with the same return expression using '|'. 'Match' also includes support for 'fallthrough'. The package also replicates the Result and Option enums from Rust.

Version: 0.1.0
Depends: R (≥ 3.5.0), rlang, utils
Published: 2021-09-09
DOI: 10.32614/CRAN.package.matchr
Author: Christopher Mann
Maintainer: Christopher Mann <cmann3 at unl.edu>
License: MIT + file LICENSE
NeedsCompilation: no
CRAN checks: matchr results

Documentation:

Reference manual: matchr.pdf

Downloads:

Package source: matchr_0.1.0.tar.gz
Windows binaries: r-devel: matchr_0.1.0.zip, r-release: matchr_0.1.0.zip, r-oldrel: matchr_0.1.0.zip
macOS binaries: r-release (arm64): matchr_0.1.0.tgz, r-oldrel (arm64): matchr_0.1.0.tgz, r-release (x86_64): matchr_0.1.0.tgz, r-oldrel (x86_64): matchr_0.1.0.tgz

Reverse dependencies:

Reverse imports: refer

Linking:

Please use the canonical form https://CRAN.R-project.org/package=matchr to link to this page.