Search Haskell Channel Logs

Thursday, February 9, 2017

#haskell channel featuring dmwit, lpaste_, qmm, skeuomorf, monochrom, markasoftware,

monochrom 2017-02-09 14:45:32
Do not learn from blogs. Learn from GHC Users Guide.
fresheyeball 2017-02-09 14:47:24
hmm
fresheyeball 2017-02-09 14:47:28
so that just eats it
monochrom 2017-02-09 14:47:38
Bill Gates's appraisal at the back cover of GHC Users Guide: "If you have read it cover to cover, send me your CV"
qmm 2017-02-09 14:47:41
monochrom: i don't think i understood what you were suggesting unfortumately :\ https://github.com/hvr/cassava/issues/130
fresheyeball 2017-02-09 14:47:45
I ran `cabal build --ghc-options="-ddump-splices"`
fresheyeball 2017-02-09 14:47:51
and nothing special happened
monochrom 2017-02-09 14:48:07
cabal build is too late for this.
monochrom 2017-02-09 14:48:21
Or maybe not. I don't know. Nevermind.
markasoftware 2017-02-09 14:48:27
monochrom: really?
qmm 2017-02-09 14:48:35
monochrom: it does seem to want a bytestring as you suggested: https://github.com/hvr/cassava/blob/545b86d60276c51ec29681f1917f1e5fb9b67c54/Data/Csv/Encoding.hs#L88
monochrom 2017-02-09 14:49:04
I'm just kidding. I stole that Bill Gates quote from the back cover of Knuth's TAOCP
monochrom 2017-02-09 14:50:17
qmm, wrong parenthesizing.
monochrom 2017-02-09 14:50:40
"x (y :: T)" ≠ "x y :: T"
monochrom 2017-02-09 14:51:20
The error message says that too.
qmm 2017-02-09 14:52:00
i thought i was getting better at error messages
qmm 2017-02-09 14:52:38
just when i think i can write haskell pretty well, i publically embarrass myself
qmm 2017-02-09 14:53:27
case (decodeByName csvData :: Either ...) of -- maybe?
monochrom 2017-02-09 14:53:43
You need no parenthesizing at all
HaskellLord69 2017-02-09 14:54:29
dont worry qmm i will divert
HaskellLord69 2017-02-09 14:55:18
http://pastebin.com/UduEt1Kf
HaskellLord69 2017-02-09 14:55:33
im having trouble with monad transformers if anyone can help
HaskellLord69 2017-02-09 14:55:47
ive been staring at this for hours and I feel like my brain is mush
lpaste_ 2017-02-09 14:56:28
qmm pasted "i think it's going to take awhile for me to understand how to use this library" at http://lpaste.net/352296
qmm 2017-02-09 14:56:49
HaskellLord69 :)
monochrom 2017-02-09 14:56:53
HaskellLord69, I think you have the ordering backwards
HaskellLord69 2017-02-09 14:58:01
i thought backwards was the point with monad transformers lol
monochrom 2017-02-09 14:58:45
At some other point you see the backwardness. But your current example doesn't hit it.
monochrom 2017-02-09 14:59:39
The problem with learning from oversimplified simple-minded slogans that would get an A+ from essay graders.
monochrom 2017-02-09 15:02:44
qmm, perhaps use decode instead of decodeByName. This means you won't have a distingished header or column names. But you will have a 2-dimension vector (or list, or both).
qmm 2017-02-09 15:03:47
oops, i updated the comment on github with the result of decode (instead of decodeByName) https://github.com/hvr/cassava/issues/130
qmm 2017-02-09 15:03:59
that's the result of just using decode
qmm 2017-02-09 15:04:08
about to change it to be a result of decodeByName
dmwit 2017-02-09 15:05:03
fresheyeball: -ddump-splices often pairs well with -fforce-recomp
monochrom 2017-02-09 15:05:43
I don't see the update. I have already crtl-r'ed 3 times.
qmm 2017-02-09 15:05:59
monochrom: now it's there
monochrom 2017-02-09 15:06:17
the 4th time and still don't see it.
qmm 2017-02-09 15:06:25
it's an edit
monochrom 2017-02-09 15:06:26
OK, sorry, see it now.
qmm 2017-02-09 15:06:27
not a new comment
monochrom 2017-02-09 15:06:57
You will not have Header.
monochrom 2017-02-09 15:07:22
It's simply Either String V.Vector (V.Vector BL.ByteString)
monochrom 2017-02-09 15:08:09
I don't know whether to point out that the error message also says this.
monochrom 2017-02-09 15:09:03
I don't know. tibbe misled you down this path and I suppose I'll just say it's his problem now.
qmm 2017-02-09 15:10:01
monochrom: thank you for your patience
qmm 2017-02-09 15:10:21
monochrom: i won't ask anymore from you
skeuomorf 2017-02-09 15:38:29
is the order of the definitions of a function important? e.g. a function that takes the empty list, returns an empty list, if it takes a non-empty list, it does some computation
skeuomorf 2017-02-09 15:38:46
so, they're defined as patterns
skeuomorf 2017-02-09 15:38:58
e.g. myfunc [] = []
skeuomorf 2017-02-09 15:39:07
myfunc xs = dostuff
geekosaur 2017-02-09 15:39:32
the first one that matches is used, so if you swapped them then xs would also match the empty list
skeuomorf 2017-02-09 15:40:00
yeah, that was just a quick example
skeuomorf 2017-02-09 15:40:10
but I see what you mean
skeuomorf 2017-02-09 15:41:06
is there a resource more terse than real world haskell?
Rotaerk 2017-02-09 15:41:41
I didn't like RWH because its examples were way too elaborate and distracting
skeuomorf 2017-02-09 15:42:16
yeah, I am already comfortable programming in multiple other languages, some of them functional, some of them typed, but not both
skeuomorf 2017-02-09 15:42:20
I get the general idea
skeuomorf 2017-02-09 15:42:44
But I think I will need to learn all the IO stuff
skeuomorf 2017-02-09 15:42:57
cause it's unconventional, at least for me