Rub_ixCube 2017-03-02 07:45:11
hello
Cale 2017-03-02 07:45:28
hi
fresheyeball 2017-03-02 07:47:21
Cale: fixed!
Hello_ 2017-03-02 07:51:24
Does Haskell have the observable pattern built in?
Hello_ 2017-03-02 07:51:33
IE is there is no need for ReactiveX?
fresheyeball 2017-03-02 07:51:56
Hello_: Haskell has Reactive programming
fresheyeball 2017-03-02 07:52:17
but Reactive programming is distinct from the Observable pattern
fresheyeball 2017-03-02 07:53:38
Hello_: imho ReactiveX is kind of a broken idea
SomeT 2017-03-02 07:54:23
for a false beginner in haskell, whats the best genetic algorithm library?
Hello_ 2017-03-02 07:54:51
How is it distinct? I'm new to functional programming and have trouble understanding. Doesn't Reactive programming essentially boil down to events being dispatched in an immutable stream and a listener responding to those events, and making changes based purely on the state?
fresheyeball 2017-03-02 07:56:08
Hello_: its distinct in a couple ways. So Rx Observable are writable at any time. Reactive streams are immutable, and so all the information needed to create the stream must be local to stream creation. IE no `onNext`.
fresheyeball 2017-03-02 07:56:59
Rx Observables are also samplable at any time. And most Reactive streams are not samplable, IE you can't just get the last value out at any time.
fresheyeball 2017-03-02 07:57:34
I think you have the core idea of Reactive, but its pretty different from what Rx gives you inpractice.
kuribas 2017-03-02 07:58:53
Hello_: there is reactive-banana
soulisson 2017-03-02 07:58:56
Hi, sorry to bother you. I'm trying to learn about functional programming. I'm not familiar with haskell but I would like to understand the concept of Monad. I read several blog posts and I understood a Monad as an object that contains a value and has some methods like bind.
fresheyeball 2017-03-02 07:58:57
Rx also has this idea of a hot and cold stream, this is mutation built into the core abstraction of an Observable. Haskell does not allow this.
kuribas 2017-03-02 07:59:20
soulisson: Monad is not an object, it's apattern.
kuribas 2017-03-02 07:59:45
soulisson: It's basicly a typeclass, with some laws (which aren't enforced).
fresheyeball 2017-03-02 07:59:58
soulisson: Monad is a type for which you can write two functions, that obey the Monad laws
fresheyeball 2017-03-02 08:00:46
Hello_: so reactive streams cannot be active or inactive, they just are.
fresheyeball 2017-03-02 08:01:20
soulisson: I would start by understanding Functor before learning about Monad
soulisson 2017-03-02 08:01:35
fresheyeball: ok
kuribas 2017-03-02 08:02:14
soulisson: for example, r -> a is a monad, but it doesn't "contain" an "a".
Hello_ 2017-03-02 08:02:37
fresheyball: I see.
kuribas 2017-03-02 08:02:42
soulisson: it's purely a type level thing.
kuribas 2017-03-02 08:03:20
(well, except for the laws)
fresheyeball 2017-03-02 08:03:29
soulisson: yeah kuribas is right. Many people trip on this. Monads are not necissarily containers, though many containers are Monads.
fresheyeball 2017-03-02 08:03:50
soulisson: Monad is just more abstract then your intuition tells you at first.
soulisson 2017-03-02 08:04:05
fresheyeball: the notion of type is close to the notion of class in OOP?
fresheyeball 2017-03-02 08:05:18
soulisson: no
kuribas 2017-03-02 08:05:18
soulisson: no
kuribas 2017-03-02 08:06:00
soulisson: you shouldn't try to understand monads before you know what typeclasses are.
fresheyeball 2017-03-02 08:06:02
soulisson: there are Monads in OOP, but you would never know it, because the asbraction of Monad is impossible to express in OOP. You can think of Monad more like its an interface.
kuribas 2017-03-02 08:06:13
soulisson: it will just confuse you.
fresheyeball 2017-03-02 08:06:48
soulisson: type classes are like way more flexible interfaces in OOP
soulisson 2017-03-02 08:07:21
Ok, I'll try. seems a little complex for now. Thanks for your help
fresheyeball 2017-03-02 08:08:49
soulisson: keep on learning!
shapr 2017-03-02 08:09:59
soulisson: I like haskellbook.com, it builds up from functor to applicative to monad
soulisson 2017-03-02 08:10:36
I'll check it
shapr 2017-03-02 08:14:50
soulisson: have you written any Haskell code?
soulisson 2017-03-02 08:15:33
shapr: No, I'm learning FP without any specific language, just the theory for now
shapr 2017-03-02 08:15:45
soulisson: found anything especially interesting?
fresheyeball 2017-03-02 08:15:52
soulisson: I highly recommend learning Haskell to accomplish that
soulisson 2017-03-02 08:17:02
shapr: liked memoization, currying, higher order functions and clojures but Monads are challenging to understand for now
shapr 2017-03-02 08:17:36
soulisson: the best hand wavey explanation I've seen is "decorating function composition"
Zemyla 2017-03-02 08:18:06
Question. Is the specific type of garbage collector part of the RTS chosen, or is it baked deeper into GHC?
shapr 2017-03-02 08:18:30
I think generational garbage collection is baked into GHC, but you can tune the settings.
soulisson 2017-03-02 08:18:54
shapr: I kind of understand the bind function and its usefulness but other than that ...
sternmull 2017-03-02 08:19:31
i would say playing around in haskell with a few basic monads is very helpful to understand their nature. Most of the stuff i read about monads is harder to understand than when you see how it fits together in practice.
pi___ 2017-03-02 08:19:36
Hello, When I try to compile Cabal I get this error:
pi___ 2017-03-02 08:19:37
gcc: error: dist/build/Distribution/PackageDescription/Parse.dyn_o: No such file or directory
pi___ 2017-03-02 08:19:40
`gcc' failed in phase `Linker'. (Exit code: 1)
shapr 2017-03-02 08:20:03
soulisson: how would you describe the usefulness of the bind function?
soulisson 2017-03-02 08:21:48
shapr: I seep it like a pipe between the output a function and the input of another function. I mainly saw it when it comes to handling errors
pi___ 2017-03-02 08:24:54
Hello, When I try to compile Cabal I get this error:
pi___ 2017-03-02 08:24:58
gcc: error: dist/build/Distribution/PackageDescription/Parse.dyn_o: No such file or directory
pi___ 2017-03-02 08:25:01
`gcc' failed in phase `Linker'. (Exit code: 1)
pi___ 2017-03-02 08:29:54
hello
SomeT 2017-03-02 08:31:24
Why can't I install these? I really need to install these: https://hastebin.com/wopipabegi.txt
suppi 2017-03-02 08:33:15
SomeT: which ghc version are you using?
SomeT 2017-03-02 08:34:20
the latest
SomeT 2017-03-02 08:34:26
but when I used the older versions
SomeT 2017-03-02 08:34:32
moo package failed to even pick up
SomeT 2017-03-02 08:34:34
can't win lol
suppi 2017-03-02 08:34:46
that package was last updated before Applicative became a superclass of Monad
SomeT 2017-03-02 08:35:12
do I need to edit anything in config file for cabal?
monochrom 2017-03-02 08:35:50
Modify monad-mersenne-random source code, or use an older GHC.
SomeT 2017-03-02 08:36:23
when I used an oldere ghc then it would not find moo
suppi 2017-03-02 08:37:36
what do you mean?
kuribas 2017-03-02 08:37:42
why does the ghci debugger, when I force an expression, still evaluates the subexpression?
monochrom 2017-03-02 08:38:04
Yeah, I don't understand "not find" either. What is the exact error message?
kuribas 2017-03-02 08:39:08
(after :step)
SomeT 2017-03-02 08:39:51
I think I will uninstall everything lol
SomeT 2017-03-02 08:39:56
I think I messed up my installation
SomeT 2017-03-02 08:40:32
http://support.hfm.io/1.3/HaskellCLI-7.10.3-5.18-2.html
SomeT 2017-03-02 08:40:34
I used them
suppi 2017-03-02 08:40:40
did you use cabal without sandboxes?
SomeT 2017-03-02 08:40:42
and now I can't figure out how to fully remove
SomeT 2017-03-02 08:40:46
yes without sandbox
suppi 2017-03-02 08:41:31
sorry i must go, i'll be back later
SomeT 2017-03-02 08:42:32
ok
kuribas 2017-03-02 08:42:52
how annoying...
kuribas 2017-03-02 08:43:14
Either ghci is retarded, or I am missing something...