Re: Time complexity of operations on collections

2013-05-23 Thread Matthew
http://www.innoq.com/blog/st/2010/04/clojure_performance_guarantees.html -- -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patie

clojure.spec.gen: Negative testing

2016-11-08 Thread matthew
I want to do generative testing with clojure.spec, specifically both positive and negative tests. Is clojure.spec intended to be used in this way? Suppose I have this function which accepts external input from the user: (defn handle-action [[action payload]] (case action :create (do-creat

Re: Sending Clojure Objects over TCP

2013-02-07 Thread Matthew
Aleph On Thursday, February 7, 2013 12:16:03 PM UTC+11, JvJ wrote: > > Does anyone know if there's a simplified networking library that allows > this? -- -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to

Re: Clojure + Web Services + Web Sockets

2013-02-11 Thread Matthew
+1 for Aleph. I've used it loads and it's great. On Tuesday, February 12, 2013 10:12:57 AM UTC+11, Ryan T. wrote: > > Unless someone has to suggest something better, it seems that the best way > to achieve what i want is to use aleph > which > allows you to i

[ANN] lein-clique - Function dependency graph generator

2013-05-03 Thread Matthew
This is a tool for generating dependency graphs of functions used by functions. It goes through the source of functions and resolves any symbols in external namespaces, collecting a graph of which functions use which other functions. The result is a dotviz file to be layed-out and analyzed in a

Protocols and default method implementations

2010-08-12 Thread Matthew
defaults in order to happily extend a "public" protocol. Am I missing something key here? I realise there are some very experienced people contributing to Clojure, so am fully expecting to be told I've missed something obvious ;) Cheers, Matthew. [1] http://groups.google.com/group/clo

Re: Merry Christmas Everybody

2012-12-26 Thread Matthew
Merry Christmas from me too! (source ) -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are m

Help with binding

2012-01-08 Thread Matthew
of either the map or the anonymous function. Because if I change the function to just iteratively call (write-a :byte \I) (write- a :byte \D) etc it works fine. Thanks, matthew -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this g

A newbie question on Agents and ants

2008-12-07 Thread Matthew Wyatt
Hi all, I have a newbie question about Agents. I've been looking at the ants.clj file: http://clojure.googlegroups.com/web/ants.clj?hl=en&gda=-X7f3joAAABoLitVpBTEcNIQc_NHg39SZujXwZ5jF2pV4ArMqQ0G0e9OU0NQiFWgQuhmPR7veGf97daDQaep90o7AOpSKHW0 Most of it makes sense to me, but the use of Agents is c

Re: Poll for a new name for clojure eclipse plugin 'clojure-dev'

2009-06-24 Thread Matthew Erker
I second that vote. (Though I prefer Clipse, which is somewhat taken.) On Jun 23, 6:47 pm, Rayne wrote: > I vote Corona. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send

Feedback on a simplified regexp implementation

2009-11-08 Thread Matthew Denson
not sure that is true with my code here. Finally, this is just an exercise. If I needed regexp in another problem, I would use the clojure tools. Thanks in advance, Matthew P.S. There must be some libraries for testing that would be better than what I've done, but I didn't find any

Clojure Koans?

2009-12-02 Thread Matthew Williams
seeing more and more benefits as the days go by. Thanks for being such an great community! -Matthew Williams @mwilliams -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that post

Re: Getting Started in Mac OS X Snow Leopard

2009-12-02 Thread Matthew Williams
Using the Cocoa build of Emacs 23 (http://www.emacsformacosx.com) I was able to get up and running extremely quickly with Technomancy's swank-clojure install. http://technomancy.us/swank-clojure After just a few minutes I was in the REPL and ready to go. Good luck! On Nov 30, 8:32 pm, Charras

Re: Clojure Koans?

2009-12-02 Thread Matthew Williams
On Dec 2, 12:43 pm, Jim Weirich wrote: > On Dec 2, 2009, at 4:36 PM, ataggart wrote: > > > If by "koan" you mean usage examples, then there are plenty of them > > within the clojure source itself, as well as clojure-contrib. > > The Koans are more than "just" examples.  They are designed to   >

No matching method found for javax.mail.internet.MimeMessage

2010-05-27 Thread Matthew Elder
ime Environment (build 1.6.0_16-b01) Windows XP SP3 - I am retrieving jars via lein (project.clj included in pastebin) Any help is appreciated! Thanks, Matthew Elder Novice Clojure Programmer -- You received this message because you are subscribed to the Google Groups "Clojure" group. To

Re: No matching method found for javax.mail.internet.MimeMessage

2010-05-27 Thread Matthew Elder
This actually helped alot, here is the relevant excerpt (defn plain- message). It is rewritten the original way I wanted to do it. Here it is: (defn plain-message [{:keys [from to cc bcc subject body]}] (doto (new MimeMessage (get-default-session)) (.setRecipients Message$RecipientType/TO (i

Re: No matching method found for javax.mail.internet.MimeMessage

2010-05-27 Thread Matthew Elder
This actually helped alot, here is the relevant excerpt (defn plain- message). It is rewritten the original way I wanted to do it. Here it is: (defn plain-message [{:keys [from to cc bcc subject body]}] (doto (new MimeMessage (get-default-session)) (.setRecipients Message$RecipientType/TO (i

Re: No matching method found for javax.mail.internet.MimeMessage

2010-05-27 Thread Matthew Elder
This actually helped alot, here is the relevant excerpt (defn plain- message). It is rewritten the original way I wanted to do it. Here it is: (defn plain-message [{:keys [from to cc bcc subject body]}] (doto (new MimeMessage (get-default-session)) (.setRecipients Message$RecipientType/TO (i

Re: No matching method found for javax.mail.internet.MimeMessage

2010-05-27 Thread Matthew Elder
TO ^String to) >     (setRecipients Message$RecipientType/CC ^String cc) >     (setRecipients Message$RecipientType/BCC ^String bcc) >     (setFrom from) >     (setSubject subject) >     (setContent body "text/plain"))) > > Hope that helps, > Sean > > On May

Re: Which GUI toolkit would you like to see wrapped in an idiomatic Clojure library?

2010-05-28 Thread Matthew Elder
+1 QT On 5/27/10, Joost wrote: > Personally, I prefer SWT over Swing mostly because seems a lot more > useful and a little more responsive to the user. > > But then I think Swing is horrible and SWT is just a bit better. I > seriously prefer Tk over both (except for the file selection dialogs > o

Re: Which GUI toolkit would you like to see wrapped in an idiomatic Clojure library?

2010-05-28 Thread Matthew Elder
I will send patches!! get on github no. ;) On 5/27/10, Luke VanderHart wrote: > Thanks, Heinz... I may. > > Right now I'm still exploring what I want the API to be. I was hoping > to achieve something a bit "thicker" that could insulate the user from > Java classes completely. The user would

Re: Which GUI toolkit would you like to see wrapped in an idiomatic Clojure library?

2010-05-28 Thread Matthew Elder
Yes but not too much yak shaving, it is important to run with the simplest thing that will work first. On 5/27/10, Jason Smith wrote: > Why not design it so that it can be backed by Swing or SWT or HTML > (perhaps with some AJAX) or whatever? It seems kind of silly to do an > abstraction on a s

Re: [ANN] alpacas: a new Clojure source viewer

2013-06-04 Thread Matthew Chadwick
hehe looks similar to something I've been writing: http://celeriac.net/ioio/public/ -- -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderat

Re: ANN: Potemkin 0.3.0

2013-06-19 Thread Matthew Chadwick
> > If anyone has moral or aesthetic objections to 'import-vars', you're not > alone, but please remember you're under no obligation to use it. I used lein-clique to make a graph of Lamina's dependencies(huge PNG

Re: [ANN] Nightcode, an IDE for Clojure and Java

2013-08-04 Thread Matthew Chadwick
this is great! please please add structural editing (not simply bracket-matching in a text-editor, but direct manipulation of Clojure data structures (including code). I've been trying out some ideas in this area & would be happy to help out. On Friday, August 2, 2013 11:03:03 PM UTC+10, Zach

Re: Fantasy Baseball Lineup Optimization

2013-09-14 Thread Matthew Rocklin
Perhaps a bit intense but this problem might lend itself to mixed integer linear programming. MILP is a very broad formulation of optimization problems. Optimal solution of MILP problems is NP-Hard but very mature software solutions exist. I don't know what's out there in Clojure land for th

GSOC 2015 — tools.reader.cljs

2015-03-05 Thread Matthew West
Hello everyone, I am an undergraduate student looking to participate in the GSOC this summer. I've been looking through the project ideas on the Clojure Development site, and the one that looks most interesting to me is implementing tool

Re: Om design query

2015-03-06 Thread Matthew Davidson
uld the Flexbox layout work here? Matthew On Friday, March 6, 2015 at 10:15:23 AM UTC-5, James Reeves wrote: > On 6 March 2015 at 05:22, Dave Della Costa wrote: > (cc'ing clojur...@googlegroups.com) > > > Let me make sure I understand what you're asking: you have a parent

Re: Better/more idiomatic way to read EDNs than using java.io.PushbackReader

2015-03-08 Thread Matthew Boston
I've done something like: (clojure.edn/read-string (slurp (clojure.java.io/resource edn-file))) This of course assumes the file resides in `/resources`. On Friday, March 6, 2015 at 8:18:03 PM UTC-7, Sam Raker wrote: > > I'm experimenting a little with EDN files. I've currently got this > functi

State of the Art in Clojure Debugging

2015-03-30 Thread Matthew West
What is the current preferred strategy for debugging Clojure code? I'd prefer a solution that doesn't involve Emacs, as I already know vim pretty well and don't really want to switch. What are my options that are still actively maintained? -- You received this message because you are subscribe

Re: ANN: ClojureScript 0.0-2496, cljs.test - a clojure.test port

2015-05-08 Thread Matthew Boston
Here's the commit I used when swapping cljs.test from clojurescript.test: https://github.com/testdouble/clojurescript.csv/commit/ad68052e311df423e245ec4d2a7ee5572b2a3a35 Note the runner.js file line 26 is calling the exported function to run all the tests. On Friday, May 8, 2015 at 12:49:07 AM

Re: namespace :as vs :require

2015-06-08 Thread Matthew Boston
Here's a great post on the subject by Stuart Sierra: http://stuartsierra.com/2015/05/10/clojure-namespace-aliases - Matthew On Friday, June 5, 2015 at 9:33:32 PM UTC-6, Todd Stout wrote: > > What is considered idiomatic when using :as and :require in your namespace > declarations

Small parsing bug in data.json - advice sought

2015-07-28 Thread Matthew Gilliard
ly whitespace remaining? - Can we just live with this bug as-is? - Is there a middle ground? (eg checking the next n bytes for non-whitespace then stopping) - Would it make sense if we treat 'read-str differently from 'read in this case? Thanks. Matthew -- You received this messa

Stumped: unable to resolve symbol in macro expansion

2014-07-20 Thread Matthew DeVore
I don't have a Clojure REPL handy at the moment but it looks like the x symbol is being resolved in the macro context rather than the expansion context. In the macro source, where you have a plain x, try to replace it with ~'x ... This blog post may be relevant: http://amalloy.hubpages.com/hub/

Re: Stumped: unable to resolve symbol in macro expansion

2014-07-21 Thread Matthew DeVore
ambda-list) > [docstring forms] (parse-defun-decls decls-doc-forms) > args-var (gensym "args") > positional-parameters (get param-map '&positional)] > (if docstring > (comment ; *FINISH* docstring variant > ;; `(defn ~functio

Ring and Compojure in Clojurescript

2014-12-08 Thread Matthew Molloy
Hi guys, I love making Clojure web apps, however their startup time is a serious drawback when used with a transient hosting service such as Heroku. My thought is to port Ring and Compojure over to Clojurescript and create a Node.js ring adapter. Has anybody tried something like this? Any s

Ring and Compojure with Node.js via Clojurescript

2014-12-08 Thread Matthew Molloy
. Any thoughts or suggestions? Matthew -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To u

Re: Ring and Compojure with Node.js via Clojurescript

2014-12-13 Thread Matthew Molloy
Thanks for the feedback. I'll let you know how things progress. Matthew -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - pl

Re: Ring and Compojure with Node.js via Clojurescript

2014-12-16 Thread Matthew Molloy
Update: Somebody else has beat me to it. https://github.com/bodil/dogfort Matt -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please b

Re: [lein] compile sass?

2014-12-26 Thread Matthew Boston
There is also Dieter: https://github.com/edgecase/dieter On Tuesday, December 23, 2014 3:41:46 PM UTC-7, stephanos wrote: > > Hey there, > > I would love to use the SASS library bourbon.io for my project. Is there > any way I can use leiningen to compile the scss files to css? > > PS: I tried *le

Re: Optimizaton for finding the next key in a sorted-map

2020-05-25 Thread Matthew Downey
Don't forget about subseq and rsubseq, the technology behind [the world's smallest time series database]( https://www.dotkam.com/2015/12/02/time-series-database-in-one-line-of-clojure/) ;) On Monday, May 25, 2020 at 4:47:58 PM UTC-5, Harmon Nine wrote: > > Is there an optimization for sorted-ma

Re: First post: how to mimic a Java List with types?

2020-08-14 Thread matthew...@gmail.com
Another option would be to do what Alex is suggesting and define and as a function. Just because it’s a macro in clojure.core doesn’t mean you can’t write your own :) (defn eval' [x] (if (map? x) (apply (:fn x) (:coll x)) x)) (defn and-list [& items] (let [if? (fn [x] (if x true f

Re: Rationale behind github.com/cljctools project

2020-08-31 Thread matthew...@gmail.com
You've probably seen this already, but https://github.com/ptaoussanis/encore is a great extended core libary for Clojure(Script) that I find myself using all the time in various projects. On Sunday, August 30, 2020 at 1:42:25 AM UTC-5 sergei...@gmail.com wrote: > Thought process behind and go

Re: Mexico City Clojureists?

2020-10-21 Thread matthew...@gmail.com
Here, here. There's already a [Mexico City JVM meetup](https://www.meetup.com/jvm-mx/), but once we're able to we should put together a Clojure meetup as well. On Wednesday, October 21, 2020 at 2:59:01 PM UTC-5 nihilipster wrote: > Hola... not exactly in Mexico City but in the same country. >

Re: Recommended way to develop a command-line app in Clojure

2021-06-23 Thread matthew...@gmail.com
It's also probably worth testing out writing something in "normal" Clojure and compiling it to an uberjar instead of running it via lein / clj, because depending on what "fast" means to you, a normal jar will often fit the bill, since the JVM itself starts in ~100ms. On Wednesday, June 23, 20

Re: Use latest stable

2016-07-15 Thread Matthew Boston
On the topic of keeping dependencies up-to-date, I use https://www.versioneye.com. I sign in with GitHub and it watches all the projects that I choose for out-of-date deps. It sends me a weekly/daily email so I'm rarely behind every new release. Cheers. On Thursday, July 14, 2016 at 11:58:41 A

Re: [ClojureScript] Re: ANN: ClojureScript 0.0-2913, Google Closure Modules, improved nREPL support

2016-10-30 Thread Matthew Chadwick
On Tuesday, February 24, 2015 at 12:37:46 PM UTC, David Nolen wrote: > :preamble will only be applied to the base module. When using :modules there > is not such thing as a main output file. > > > You cannot currently have a per module :preamble. > I recently wanted per-module :preamble when p

def partial vs let partial

2016-12-01 Thread Matthew Hamrick
I'm confused by the following code. Could someone explain to me why the def-ed partial has different behavior to the letted one? This is especially confusing to me since the #() special form one works as I expect. (def sum-partial-def (partial reduce +)) (let [sum-partial (partial reduce +)

Tentacles; Going Forward

2017-01-26 Thread Matthew Boston
tastic piece of software. So, I want to open a discussion to the community, as to how we, the community, should proceed. Cheers, Matthew Boston #RIPRaynes -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to cloj

Re: Tentacles; Going Forward

2017-02-15 Thread Matthew Boston
bruary 14, 2017 at 5:01:09 PM UTC-7, Alan Moore wrote: > > Matthew, > > +1 everything Chas said. #RIPRaynes > > I do have a question about tentacles more generally. Given GitHub's move > to GraphQL, how do you see this being supported (or not?) in this library > going f

Re: Raynes' legacy

2017-02-26 Thread Matthew Boston
I'm happy to hear that others are willing to step up to the plate in regards to continuing Anthony's legacy. I started a thread specifically about tentacles a month ago here: https://groups.google.com/forum/#!searchin/clojure/tentacles%7Csort:relevance/clojure/15x_LWE2IMM/CGULJTXLBQAJ We, at C

Re: ANN: Cognitect acquired by Microsoft

2017-04-03 Thread Matthew Boston
Not believable at all. Everyone knows Cognitect will be acquired by Oracle 😉 On Saturday, April 1, 2017 at 2:00:16 PM UTC-6, Gregg Reynolds wrote: > > made ya look! > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email

Re: [ANN] graphql-clj 0.2.0

2017-04-30 Thread Matthew Boston
The first, and biggest difference that I see, is that a schema is defined as a single string in graphql-clj, but Lacinia uses data structures to describe your graphql schema. The latter being more easily composable, if that's something you need. On Monday, April 24, 2017 at 8:29:24 PM UTC-6, Di

Re: [ANN] Clojure 1.9.0-alpha18

2017-08-23 Thread Matthew Phillips
Just for everyone's info: seems this update breaks CIDER 0.15: https://github.com/clojure-emacs/cider/issues/2081 -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new m

Re: Spy - Clojure / ClojureScript library for stubs, spies and mocks

2018-05-03 Thread Matthew Boston
There is also https://github.com/circleci/bond which we use quite extensively at CircleCI. And I have used it on other projects outside of CircleCI. On Monday, April 30, 2018 at 7:48:31 AM UTC-6, Didier wrote: > > This looks cool for validation. -- You received this message because you are sub

Re: [ANN] Clojure 1.10.0-RC1 (please test!)

2018-10-11 Thread Matthew Phillips
Hi Alex, have just finished testing on an 18 KLOC Clojure backend service (Java 8, Linux). Test suites and deployed service runs fine. Let me add my thanks for your hard work! Cheers, Matthew. -- You received this message because you are subscribed to the Google Groups "Clojure"

NoSuchMethodError when AOT'ing with Clojure 1.10

2019-01-15 Thread Matthew Phillips
Hi all, I have an inexplicable runtime error with a leiningen-generated AOT uberjar that happens when using Clojure 1.10 that doesn't happen with 1.9 (I'm on Java 8 for both compilation and deployment). The code in question looks like: (defn make-apns-message [payload] (let [buffer (ByteBuff

Re: NoSuchMethodError when AOT'ing with Clojure 1.10

2019-01-16 Thread Matthew Phillips
I am pretty sure I'm using Java 8. I do have both Java 8 and Java 11 installed, but the environment it's built with: $ java -version java version "1.8.0_162" Java(TM) SE Runtime Environment (build 1.8.0_162-b12) Java HotSpot(TM) 64-Bit Server VM (build 25.162-b12, mixed mode) $ echo $JAVA_HOME

Re: NoSuchMethodError when AOT'ing with Clojure 1.10

2019-01-16 Thread Matthew Phillips
I've been able to reproduce this by deliberately building with Java 11/Clojure 1.10, then running on Java 8. Doing the same thing but built with Java 8 is fine. So, somehow some classes built with Java 11 must have gotten into the build. Time to check my build cleanliness... Thanks again, and

Re: Component question/advice

2019-09-24 Thread Matthew Downey
One thing you could consider is constructing the individual pieces of your system as system-maps that you can merge together. (A pattern from " Tips and Tricks for Component"

Re: [ANN] Clojure wrapper for the Interactive Brokers API

2020-04-28 Thread Matthew Downey
Very cool, thanks for sharing! I'm curious, whats your workflow when connecting running IB's client? Is there an easy way to run this on a headless server? On Tuesday, April 28, 2020 at 4:00:46 PM UTC-5, Alexandre Almosni wrote: > > Hi, > > just released https://github.com/alex314159/ib-re-acto

Re: first time without state - and I'm lost

2020-05-13 Thread Matthew Downey
I totally understand that, I felt the same way first coming to Clojure. For this situation, there are a couple approaches that you could take depending on how hardcore you want to be about keeping things functional & immutable. The most similar thing you could do to your Java code would be keepin

[CfP] DLS 2020 - Dynamic Languages Symposium, submission deadline July 9th

2020-05-18 Thread Matthew Flatt
to the first day of your conference. The official publication date affects the deadline for any patent filings related to published work. Program Committee - Alexandre Bergel, U Chile Shigeru Chiba, U Tokyo Stéphane Ducasse, Inria Tim Felgentreff, HPI Matthew Flatt, U Utah (chair

Re: ANN: ClojureScript 1.7.28 - Optional Self Hosting

2015-08-06 Thread Matthew Molloy
Hi David, Are macros supported directly within clojurescript then? I'm having some trouble compiling a macro via defmacro. Matt On Saturday, August 1, 2015 at 1:52:23 AM UTC+8, David Nolen wrote: > ClojureScript, the Clojure compiler that emits JavaScript source code. > > > README and source

Re: ANN: ClojureScript 1.7.28 - Optional Self Hosting

2015-08-07 Thread Matthew Molloy
Sorry, what I meant was can bootstrapped ClojureScript do (:require-macros ...) without the JVM. Perhaps you can clarify that FAQ to say that. -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.

Deploying Lein Template to Clojars

2015-08-27 Thread Matthew Molloy
According to the current documentation I create a leiningen plugin using the pattern (defproject your-template-name/lein-template "0.1.0-SNAPSHOT" however the clojars tutorial indicates that projects should be named as (defproject org.clojars.whamtet/too-hot "1.0.0" where whamtet is m

Re: Deploying Lein Template to Clojars

2015-08-27 Thread Matthew Molloy
mplate you > could use with "lein new foobar ..." > > - James > > On 27 August 2015 at 16:29, Matthew Molloy > > wrote: > >> According to the current documentation I create a leiningen plugin using >> the pattern >> >> (defproject

Re: Suggestions on staying up to date with Clojure

2015-09-29 Thread Matthew Boston
Which in turn drives a mailing list. The open-source aspect, I hope, will attract newcomers to contribute to real applications. - Matthew On Monday, September 28, 2015 at 6:04:22 PM UTC-6, Jonathon McKitrick wrote: > > What list of blogs, websites, and/or feeds would you suggest for so

Re: The middleware pattern

2015-10-02 Thread Matthew Boston
comp isn't backwards, it's just "outside-in". ((comp not zero?) x) == (not (zero x)) So it reads in the same order from left-to-right as it would otherwise. On Friday, October 2, 2015 at 1:10:54 PM UTC-6, Jason Felice wrote: > > Why is it so hard to describe to new people? > > I mean, the questi

Re: Library suggestions requested for clojure-toolbox.com

2015-10-07 Thread Matthew Boston
Here are a few that I and others on my team have created. clojurescript.csv - https://github.com/testdouble/clojurescript.csv - csv parsers, clojurescript baizen - https://github.com/testdouble/baizen - parsing ring-okta - https://github.com/Hendrick/ring-okta - request middleware avenue - htt

Filtering lazy sequence on itself - Eratosthenes Sieve

2015-11-04 Thread Matthew Ulrich
All - I'm trying to generate a lazy sequence of primes using Erastosthenes Sieve (from Abelson & Sussman) and am encountering some issues with lazy sequence. Here's what I have: --- (defn divisible? [input numerator] (= 0 (mod input numerator))) (defn sieve [stream] (lazy-seq (con

Re: Filtering lazy sequence on itself - Eratosthenes Sieve

2015-11-05 Thread Matthew Ulrich
range-peek > (filter (partial prime? primes)) > first)] > (cons p (lazy-seq (sieve (conj primes p))) > > (last (take 1 (sieve))) > > This version keeps the visited primes in a vector so it will grow in > memory but won’t overfl

Re: Project structure when using reader conditionals

2016-01-01 Thread Matthew Boston
I've done it multiple ways: src/app/foo.clj src-cljs/app/bar.cljs src-cljc/app/baz.cljc AND src/clj/app/foo.clj src/cljs/app/bar.cljs src/cljc/app/baz.cljc I prefer the latter, probably for ease of navigation in the command line and in emacs. But I totally agree that having them all together

Re: Upgrading to Clojure 1.8 (direct linking)

2016-04-07 Thread Matthew Phillips
und it far better to run dev with it off, because otherwise you usually need to reload the world to reliably redefine a single function. Sidenote: if only I had the time, I would *so* love to jump in and try implementing this with JDK 8 switchpoints/method handles/etc [1]. With that approach w

Improving pprint behavior for anonymous functions

2014-04-25 Thread Matthew DeVore
Hi, There has been one thing bugging me for a long time that seems worth it to fix, and I was wondering if anyone else has had the same problem. I have enjoyed using Clojure's REPL and embracing a Clojure-style data model for my app, where everything is a glorified map or vector and there are n

Re: Improving pprint behavior for anonymous functions

2014-04-25 Thread Matthew DeVore
ould want the equality semantics; at > least in the case of impure functions the equality does not hold. > > On Friday, April 25, 2014 11:01:37 AM UTC-5, Matthew DeVore wrote: >> >> Hi, >> >> There has been one thing bugging me for a long time that seems worth i

Re: Improving pprint behavior for anonymous functions

2014-04-25 Thread Matthew DeVore
在 2014年4月25日星期五UTC-7下午12时16分22秒,Alex Miller写道: > > > On Friday, April 25, 2014 1:23:49 PM UTC-5, Matthew DeVore wrote: >> >> Thanks for pointing out the ticket, but based on the Description, it >> falls short of what I need. It doesn't have any additional inf

Re: Improving pprint behavior for anonymous functions

2014-04-26 Thread Matthew DeVore
Greg's is a nice and clean solution for the data visualization problem, assuming you're only going to use partials. I hacked together a solution to support functions with equality semantics, if anyone is interested. It doesn't support anonymous functions or closures, but doing that would requir

Re: OSGi manifest creation for Clojure projects

2013-09-21 Thread Matthew Bishop
These pages are no longer available. Can you re-post new URLs for them? Thanks! On Friday, March 16, 2012 2:48:42 PM UTC-7, Paudi Moriarty wrote: > > Hi, > > I've spent quite a lot of time with Clojure and OSGi lately and have had > some success in using Bnd and tools.namespace to generate a man

Using Friend with a proxy

2013-10-17 Thread Matthew Chadwick
hi, I'm using Friend, and it works very well, except now I've got things set up in production my app server has a reverse-proxy in front and the redirects no longer work for my protected routes. I tried using requires-scheme-with-proxy but without success...am playing around with it now, don't

Re: [ANN] clojure.data.priority-map 0.0.3

2013-10-31 Thread Matthew Chadwick
very cool - thankyou On Wednesday, October 23, 2013 5:46:00 PM UTC+11, puzzler wrote: > > https://github.com/clojure/data.priority-map/ > > A priority map is similar to a sorted map, but sorts the entries by the > values rather than the keys in the map. Think of it as a kind of priority > queue

Re: Comparing core.async and Reactive Extensions

2013-12-19 Thread Matthew Podwysocki
You can easily do bi-directional communication using Rx, but it's involving two Subjects, which are both Observables and Observers, or any flavor thereof Subjects whether Replay, Async, Behavior, or Buffered or Controlled (for backpressure coming soon). var subject1 = new Rx.Subject(); var subj

Re: Comparing core.async and Reactive Extensions

2013-12-19 Thread Matthew Podwysocki
this always been the way that Rx > worked (the locking part)? I haven't used Rx for several years, so I may be > off in my assumptions. > > Timothy > > > On Thu, Dec 19, 2013 at 9:41 AM, Matthew Podwysocki < > matthew.p...@gmail.com > wrote: > >> You c

EDN for Objective-C (iOS/OS X)

2013-02-05 Thread Matthew Phillips
Hello, a quick search of this group, and the web at large, doesn't get any hits for an Obj-C EDN implementation. Is there anyone working on this? If not, I'll likely go ahead and implement a basic subset of the EDN spec for my own needs, which I'd be happy to share. C

Re: EDN for Objective-C (iOS/OS X)

2013-02-06 Thread Matthew Phillips
Thanks. I did look at the (incomplete) C version, and will take another closer look before deciding what route to take, but I suspect an Obj-C/Cocoa version would have different enough requirements to warrant a new start, or at least a significant re-write. Cheers, Matthew. On Wednesday

ANN: MPEdn, an EDN reader/writer for OS X and iOS

2013-02-22 Thread Matthew Phillips
d useful 1.0 release. Feedback otherwise, or comments welcome. Cheers, Matthew. -- -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated

ClojureScript crossovers

2013-03-27 Thread Matthew Hill
Hello, I'm working on a library that works with both Clojure and ClojureScript. Here's the project.clj for the library: (defproject libtest "0.1.0-SNAPSHOT" :description "FIXME: write description" :url "http://example.com/FIXME"; :license {:name "Eclipse Public License" :url "h

Re: ClojureScript crossovers

2013-03-27 Thread Matthew Hill
Hi Evan. Thanks for the response. The ClojureScript compiler looks for *.cljs files to compile as > ClojureScript. Hence, at a minimum, the *.clj files that you want to also > use from ClojureScript need to be copied (or perhaps symlinked, but that's > not what lein-cljsbuild does) to *.cljs f

Re: ClojureScript crossovers

2013-03-27 Thread Matthew Hill
^ To be clear, that's in the project dependent upon the library, where I'm trying to use it, not the library itself. On Thursday, 28 March 2013 02:03:38 UTC, Matthew Hill wrote: > > Hi Evan. Thanks for the response. > > The ClojureScript compiler looks for *.cl

Re: -> operator and monads

2013-04-14 Thread Matthew Hill
Function composition is done via comp. Using -> and ->> is like function composition in reverse order (though there's a difference between how the two thread return values), and often it reads more naturally. user> (-> [1 2 5] rest first) 2 user> ((comp first rest) [1 2 5]) 2 On Wednesday, 3 Ap

Re: -> operator and monads

2013-04-17 Thread Matthew Hill
nalogue to ->. On Sunday, 14 April 2013 21:03:20 UTC+1, Marko Topolnik wrote: > > On Sunday, April 14, 2013 7:51:10 PM UTC+2, Matthew Hill wrote: > >> Function composition is done via comp. Using -> and ->> is like function >> composition in reverse order (though there&#x

Re: Commercially-supported, polished Clojure development environment

2010-06-09 Thread Matthew Elder
i think if la clojure were improved more, ie autocompletion in the repl etc that it would be very solid. On Wed, Jun 9, 2010 at 4:33 AM, Chas Emerick wrote: > Following the results from the State of Clojure survey, and some follow-up > comments from some in #clojure indicating that they, too, wo

Re: Protocols and default method implementations

2010-08-13 Thread Matthew Phillips
many, many times in Java: one of the reasons I got excited about multimethods in Clojure is that they allow me to transparently extend the system after the fact with no such ugliness. Thanks to the superpower that is macro, I'm sure I could make a defprotocol+ and a extend+ that do this, just wan

Re: Protocols and default method implementations

2010-08-14 Thread Matthew Phillips
e method sets on the global Object type. One idea that I tried was to use extend-type on a protocol, say to extend any Node to be a PrettyPrintableNode. Obviously this didn't work, and I'm not sure it actually makes semantic sense, but it's interesting that was my intuitive action.

Re: Protocols and default method implementations

2010-08-14 Thread Matthew Phillips
On Aug 14, 9:07 am, Kevin Downey wrote: > so clients don't directly call the protocol functions they call > print-ast which then checks to see if PrettyPrintable has been > extended to the object and falls back to the default if it hasn't Sure, but I'm talking about publishing protocols that clie

Re: Protocols and default method implementations

2010-08-14 Thread Matthew Phillips
On Aug 14, 3:22 am, Armando Blancas wrote: > > A more concrete example: say I've defined a protocol for AST nodes in > > 1.0 of a library, and later when developing 2.0 I discover it would > > have been a good idea to have a "pretty-print" method on nodes to show > > human-readable output. If the

Re: Protocols and default method implementations

2010-08-16 Thread Matthew Phillips
t implementation for existing clients, then I could have saved quite a lot of messing about. Am I still on the wrong track here? Matthew. -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegrou

Re: Protocols and default method implementations

2010-08-16 Thread Matthew Phillips
: the instance just needs to provide whichever one is most suitable. Matthew. On Aug 14, 9:30 pm, Nicolas Oury wrote: > On Sat, Aug 14, 2010 at 5:32 AM, Matthew Phillips wrote: > > > One idea that I tried was to use extend-type on a protocol, say to > > extend any Node to b

Re: Protocols and default method implementations

2010-08-17 Thread Matthew Phillips
assInfo, IProvideClassInfo2 (COM). So perhaps what I'm really asking for is better seen as an equivalent to a :default multimethod. Matthew. -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@google

Re: sessions in Ring, Sandbar, Compojure, etc...

2011-05-10 Thread Matthew Boston
Maybe try looking at the source of a project on github using logins/ sessions. One I'm currently using for reference is from 4clojure https://github.com/dbyrne/4clojure On May 10, 2:24 am, Shree Mulay wrote: > For the life of me, I can't get sessions to work, immaterial of which > tutorial I try

  1   2   >