Fork me on GitHub
#admin-announcements
<
2015-12-30
>
blissdev07:12:48

for those using clojure with emacs, is there a way to set the default indentation to always be just 2 spaces instead of forcing evenness with the preceding argument in a function call etc?

crocket11:12:31

Can anyone recommend a decent functional programming language for small command line programs? I tried clojurescript on nodejs, but it is not suitable for a command line program.

crocket11:12:21

Perhaps, haskell

crocket11:12:25

Is Rust a proper functional language? I doubt it.

crocket11:12:50

@dnolen: Sorry for losing focus, I moved here.

jaen11:12:42

Depend on your definition of functional, I suppose. To me it has a distinctly functional slant.

jaen11:12:21

That said it's ownership semantics is fairly complicated to grok at first.

jaen11:12:31

It does help you avoid all kinds of memory errors though.

crocket11:12:36

I would rather use haskell or OCaml than Rust for small command line programs. Dealing with memory management is unneccesary in such programs.

magomimmo11:12:12

@crocket: as you prefer. but just in case here is a nice post on rust. http://science.raphael.poss.name/rust-for-functional-programmers.html#id13

jaen12:12:30

That is fair, in small utilities you don't really need the safety Rust provides

jaen12:12:42

It's also why go is so popular for server plumbing infrastructure.

jaen12:12:36

Something like Nimrod could be interesting in that niche also - http://nim-lang.org/

crocket12:12:38

I can see how go is popular for small command line programs.

jaen12:12:34

Yeah, fast boot and execution and simplicity of the language probably buy a lot of mindshare there.

jaen12:12:53

I'm curious if Nimrod and Crystal will also become popular there, or will they remain niche.

jaen12:12:01

@crocket: if you want to remain functional then maybe some lightweight scheme like Racket or Chicken?

crocket12:12:24

I also considered them, too, but I haven't made a decision, yet.

jaen12:12:32

But it's fairly new.

crocket12:12:37

Pixie is too young to be useful.

jaen12:12:26

If by "useful" you mean "I would have to wrap too many C libs by myself" then yeah, probably.

crocket12:12:12

The language is not even documented, other than saying it's based on clojure. I can't afford to be a pioneer in every area.

jaen12:12:37

True enough, though if you look at this example - https://github.com/pixie-lang/pixie/blob/master/examples/gen-docs.pxi - then the only thing giving away it's not Clojure is the ns form. So I guess you would be readily able to code in it.

jaen12:12:45

But the problem of having to wrap things

crocket12:12:56

Tooling and libraries

jaen12:12:02

That in, say, node someone did before

jaen12:12:05

Remains.

pbostrom15:12:47

@blissdev: I believe you want to set clojure-defun-style-default-indent to a non-nil value to achieve this

michaeldrogalis15:12:27

Anyone know of lein test has a verbose mode plugin that prints every deftest var name before execution?

clojer19:12:44

With Prismatic Schema why do the long, String and double in: (s/validate {long {String double}} {1 {"2" 3.0 "4" 5.0}}) not require a namespace prefix?

jaen19:12:23

Because you're probably referring to the Java types and not schema predicates.

jaen19:12:48

Schema interprets Java classes as predicates that check if the given value is of that type.

jaen19:12:17

Though I'm not 100% sure why long or double would work, since it's primitves not classes, someone else would need to chime in on that.

solicode19:12:25

seems like it’s just piggybacking off the coercion functions in core

jaen19:12:31

Thanks, that's nice of them to have implemented it that way.

blissdev20:12:49

@pbostrom: thanks!

bocaj23:12:43

I'm collecting examples of datascript on the jvm or node, saving a history to a database. So far I have using rethinkdb https://github.com/runexec/PossibleDB