andreaferretti/patty
View on GitHub ↗ ★ 282 Nim
A pattern matching library for Nim
6 mentions on Hacker News by 4 people: 0 stories, 6 comments · first 2018-11-29 · latest 2023-10-01
20082026
-
…Currently I just use a library for sum type syntax on top of object variants: https://github.com/andreaferretti/patty
comment by elcritch · 2023-10-01 · in Representing Heterogeneous Data -
Libraries exist: https://github.com/haxscramper/nimtraits https://github.com/andreaferretti/patty https://github.com/alaviss/union Again we are not new to this problem and already offer alternatives.
comment by planetis · 2022-09-13 · in Ask HN: What would be your “perfect” programming language? -
…matching. And of course there are plenty of alternatives available as well, the simplest one imo is https://github.com/andreaferretti/patty
comment by planetis · 2021-03-11 · in Patten Matching in Nim -
…data types and pattern matching possible in Nim? Googling shows that there are libraries ( https://github.com/andreaferretti/patty for example) but basically amounts to deferring their implementation by way of the macro…
comment by zinclozenge · 2019-01-09 · in Nim in 2018: A short recap -
…/nim-lang.org/docs/tut2.html#object-oriented-programm... There are some macros for easier generation: https://github.com/andreaferretti/patty#constructing-variant... There are pattern matching libs: pattern matching is implemented on top…
comment by alehander42 · 2018-11-29 · in Advent of Nim