borkdude / re-find Goto Github PK
View Code? Open in Web Editor NEWFind functions by matching specs
License: Eclipse Public License 1.0
Find functions by matching specs
License: Eclipse Public License 1.0
[:a :b :c] [1 2 3]
previously produced an error when printing results because of laziness. (keep [:a :b :c] [1 2 3])
produced this error.
:a [{:a 1} {:a 2} {:a 1 :b 1}]
{1 [{:a 1} {:a 1 :b 1}] 2 [{:a 2}]}
The examples in the README make it seem like re-find doesn't care whether it's a list or a vector. Which makes sense:
user=> (= [1] '(1))
true
user=> (= [[1]] '((1)))
true
All works fine when the result is provided as a list:
$ clj -Aspeculative --args '2 [1 2 3 4]' -r "'((1 2) (3 4))" -e -v
| function | arguments | return value |
|------------------------+-------------+---------------|
| clojure.core/partition | 2 [1 2 3 4] | ((1 2) (3 4)) |
But there are no results for vectors:
$ clj -Aspeculative --args '2 [1 2 3 4]' -r '[[1 2] [3 4]]' -e -v
$ clj -Aspeculative --args '2 [1 2 3 4]' -r "['(1 2) '(3 4)]" -e -v
Except if you use vectors only for the partitions themselves:
$ clj -Aspeculative --args '2 [1 2 3 4]' -r "'([1 2] [3 4])" -e -v
| function | arguments | return value |
|------------------------+-------------+---------------|
| clojure.core/partition | 2 [1 2 3 4] | ((1 2) (3 4)) |
Currently https://re-find.it/?ret=%28range%29 returns some?
etc. some?
should not appear in the list, because it cannot be called with empty args.
I was expecting to get interpose
for this, but I didn't.
0 [1 2 3 4 5]
(1 0 2 0 3 0 4 0 5)
clj -Aspeculative --args '[1 2 3] inc' -r '[2 3 4]' -e -v -p
clj -Aspeculative --args '' -r '#(every? number? %)' -v -p -f
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.