News for hackers. Stuff that matters.

koloron

Re:Modern Functional Programming: The Onion Architecture on Friday September 30, 2016 @09:43PM (#12616203)
Here are two blog posts on free monads that should be accessible for people who understand what a monad is and are able to read Haskell:

http://www.haskellforall.com/2012/06/you-could-have-invented...

http://www.haskellforall.com/2012/07/purify-code-using-free-...

Yeah, someone please write reverse-dependency-ci! :)
Re:Make for hipsters on Monday June 20, 2016 @01:49PM (#11939711)
> but it's still the best at what it does.

If "what it does" means "build complex software projects" I think your claim is rather debatable.

GHC is currently switching away from make after having already overhauled its make-based build system two times:

http://research.microsoft.com/en-us/um/people/simonpj/papers...

Re:Programming from the Ground Up [pdf] on Sunday May 15, 2016 @04:24PM (#11702573)
Hah, just today I started to read "Haskell programming from first principles"[1] which also targets non-programmers but builds on lambda calculus instead of assembly.

Would anyone actually recommend to a beginner to start learn assembly first?

[1]http://haskellbook.com/

Nearly the same question was recently asked in r/haskell:

https://www.reddit.com/r/haskell/comments/4fhuw3/json_for_ad...

Re:Building a Better Custom Haskell Prelude on Friday April 08, 2016 @03:51PM (#11457389)
Even better with mapMaybe:

    map transform . mapMaybe safeHead
Re:Building a Better Custom Haskell Prelude on Friday April 08, 2016 @02:44PM (#11456895)
The project has existed only since last summer.
Re:Building a Better Custom Haskell Prelude on Friday April 08, 2016 @02:38PM (#11456852)
If you're still using string types for pathnames you may want to check out the path and path-io packages. The path package defines a Path type parameterized by its locality (absolute or relative) and type (pointing at a file or a directory).

Especially the distinction between relative and absolute paths adds a nice safety layer.

Re:Building a Better Custom Haskell Prelude on Friday April 08, 2016 @02:04PM (#11456617)
mcbuilder has already mentioned it, but I really want to emphasize that dependency management in Haskell is an entirely different story now with stack.
IMO, the difference in readability has little to do with the difference between OOP and FP. What's important is the expressiveness of the language.

So Ruby can be very easy to read because you can simply keep appending methods to the right.

In Haskell you can do the same, only you'll prepend functions on the left, so you end up reading expressions from right to left:

    (intercalate ", " . map show . Map.elems) myMap
What I find really hard to read, are expressions where the direction of the data flow changes, something that often happens to me in Java:

    Streams.takeWhile(list.stream().map(e -> f(e)), e -> e.isNeeded())
Re:Golang: channels are not enough on Friday March 11, 2016 @07:20PM (#11270585)
> It doesn't want to be Haskell or Lisp, those languages can be very hard to use and maintain for junior developers in large teams.

Can you expand a bit on the difficulties that these junior developers had with Haskell?

Re:The Joy and Agony of Haskell in Production on Saturday February 20, 2016 @04:31AM (#11139516)
I find ghcid very useful. It reloads your code automatically when it detects a filechange.

https://github.com/ndmitchell/ghcid http://neilmitchell.blogspot.de/2014/09/ghcid-new-ghci-based...

Re:Kotlin 1.0 Released: Pragmatic Language for JVM and Android on Tuesday February 16, 2016 @02:10PM (#11112326)
Since GHC-7.10, the minimal complete definition for a Monad instance has been (>>=) (bind) only. So you can simply move the old definition for "return" into the Applicative instance as "pure" and you're good.
How does Maven compare to Haskell's Stack in your opinion?
Didn't downvote, just FYI: Haskell's Applicative is a superclass of Monad now.
Re:Rust vs. C++: Fine-grained Performance on Sunday February 07, 2016 @03:48PM (#11054747)
Can you share some links?
Re:Imogen Heap releases single on Ethereum-based Mycelia on Tuesday October 06, 2015 @10:46AM (#10339208)
My favorite song by her: https://www.youtube.com/watch?v=eAKh26bfkpw

Beautiful usage of a vocoder.

Yes, I know it's OT…

Re:400 days of Go on Tuesday September 15, 2015 @12:57PM (#10221699)
Haskell has a pretty cool new dependency management tool called stack (https://github.com/commercialhaskell/stack).

It's based on the curated package server https://stackage.org which server sets of packages that are tested for compatibility.

Re:What can I only do in Erlang? on Friday November 07, 2014 @07:23AM (#8572175)
How does Haskell compare to Erlang regarding these features?
Re:Show HN: A simple IP address API on Friday February 14, 2014 @12:25PM (#7239662)
"postal" and "loc" are a bit off in my case. My true location is about 6km away from "loc".
Re:The Workman Keyboard Layout on Sunday October 13, 2013 @04:04AM (#6541862)
Symbols are in the same class as uppercase letters in the Neo layout. They are easily accessible by pressing the caps lock key.

Hover your mouse over "Ebene 3" here: http://neo-layout.org/

Re:The Workman Keyboard Layout on Sunday October 13, 2013 @01:28AM (#6541600)
I'm a happy user of the Neo layout. It's very different from QWERTY (or rather German QWERTZ) but optimised for English and German bi- and trigrams as well as programming.

Read about it here: http://en.wikipedia.org/wiki/Keyboard_layout#Neo

Or take a good look at its multilevel layout here: http://neo-layout.org/ ("Ebene 3" is especially interesting for programmers…)

Re:What is new in IPython 1.0 on Sunday July 28, 2013 @02:08PM (#6117475)
AFAIK any shell command preceded by a "!" works just as you would it expect it to work in your shell.
Re:Vim as a Python IDE, or Python IDE as Vim on Saturday June 15, 2013 @11:17AM (#5885210)
I'm currently looking to adapt vim for Python development. What are the other plugins that you use or would you possibly even share your .vimrc?