cjfrisz / core.match Goto Github PK
View Code? Open in Web Editor NEWThis project forked from clojure/core.match
Home Page: http://clojure.org
License: Other
This project forked from clojure/core.match
Home Page: http://clojure.org
License: Other
Currently, core.match allows for matching on one or more items thanks to Lisp-style sequence destructuring. For example, consider the following match clause:
[([a & b] :seq)] rhs
This will match a sequence of one or more items, with the first bound to a
and the rest bound to a sequence identified by b
.
This is pretty nice, but it falls short of the niceness we get in IU Scheme Match. Specifically, consider the following match clause in IU Scheme:
[(a* ...) rhs]
This will return a list matching all the elements if matching on a list (though this is pretty silly in practice). Note that this will match on the empty list, but there's no way express the same thing in clojure.core.match.
I'd be interested to see if this is possible, even if added with a more Scheme-like syntax.
Again, Clojure's core.match, while quite nice, lacks some of the trimmings of IU Scheme Match. Of note is the catamorphism syntax, or at least the simple version. In IU Match, this allows for recurring to the same instance of match with the variable(s) that matched the given pattern.
The official core.match repo claims that predicate dispatch is on their road map. This might map onto catamorphism syntax, so I'll have to stay apprised of that.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.