ertes 2017-01-27 03:47:05
merijn: i just view (.) as punctuation: "f .\ng .\nh . \ni $ x"
bennofs1 2017-01-27 03:48:03
let a = [ ps !! 0, ps !! 1, ps !! 2, ps !! 3, ps !! 4 ] and 'let a = take 5 ps' should be exactly equal, right???? (if length a >= 5)
bennofs1 2017-01-27 03:48:24
eh length ps >= 5
pavonia 2017-01-27 03:49:22
bennofs1: The fisrt one fails if the list is too short
lpaste 2017-01-27 03:49:38
bennofs pasted "Am I overlooking some typo" at http://lpaste.net/351704
bennofs1 2017-01-27 03:49:51
pavonia: yeah, that's why I said length ps >= 5
ertes 2017-01-27 03:49:54
and yes, i view lines starting with punctuation as a plague that needs to be wiped off this planet… every line that starts with a comma is a declaration of war to the land of aesthetics
bennofs1 2017-01-27 03:50:23
Please, can anyone tell me that I'm missing something really dumb in http://lpaste.net/351704?
bennofs1 2017-01-27 03:50:46
Both a and take 5 ps :: [Node]
MarcelineVQ 2017-01-27 03:51:01
ertes: isn't it a compromise to create more readable diffs
bennofs1 2017-01-27 03:51:25
If I'm not making some mistake, then this means that somehow, parseValue observes the difference between two equal values...
merijn 2017-01-27 03:51:41
bennofs1: Print both values after show
merijn 2017-01-27 03:51:47
bennofs1: Are they rendering the same?
ertes 2017-01-27 03:51:54
MarcelineVQ: it would be, if it were true… you're just moving the singularity from the bottom to the top
bennofs1 2017-01-27 03:52:30
merijn: λ: show (Project (take 5 ps)) == show (Project a)
bennofs1 2017-01-27 03:52:35
merijn: prints True...
MarcelineVQ 2017-01-27 03:52:47
ertes: I'm not sure what you mean
merijn 2017-01-27 03:53:20
bennofs1: odd...
bennofs1 2017-01-27 03:53:29
MarcelineVQ: and if I assign both shown values to a variable, then parseValue returns Nothing in both cases...
ertes 2017-01-27 03:53:33
MarcelineVQ: example with list syntax: a,\nb,\nc -- last line is a singularity (missing comma)
bennofs1 2017-01-27 03:53:53
merijn: so either ghc has a bug, or this library that parseValue comes from is doing something shady
ertes 2017-01-27 03:54:02
MarcelineVQ: \ \ a\n, b\n, c -- first line is a singularity
merijn 2017-01-27 03:54:16
Start a new session and try again?
bennofs1 2017-01-27 03:54:22
merijn: btw, the bug appears to only be triggered if building dynamically linked executables or from GHCi
MarcelineVQ 2017-01-27 03:54:29
ertes: if the the first line is [ and the last line is ] that isn't an issue right?
ertes 2017-01-27 03:55:18
MarcelineVQ: you mean like: [ a\n, b\n, c\n] -- ?
MarcelineVQ 2017-01-27 03:55:22
my issue I mean a factor in a messy diff
ertes 2017-01-27 03:55:37
or [] on separate lines?
MarcelineVQ 2017-01-27 03:56:40
[ and ] on their own lines, allthough now that I've said it that's not super relevant since it allows both comma styles
bennofs1 2017-01-27 03:56:45
merijn: look at http://lpaste.net/351705. I'm not blind and missing some silly typo, am I?
merijn 2017-01-27 03:57:24
bennofs1: Not that I can see?
ertes 2017-01-27 03:57:43
MarcelineVQ: correct… in fact i generally use a compact style with two singularities: [ a\n … \n z ] -- because i believe source code should always be optimised for humans, not for tools
bennofs1 2017-01-27 03:58:09
merijn: ok so this is indeed as strange as it seems to be. Thanks, just wanted to make really sure that this isn't some typo bug before I start investigating in that direction :)
ertes 2017-01-27 03:58:24
(add a missing comma there)
pavonia 2017-01-27 03:58:42
bennofs1: That show is the standard show?
dramforever 2017-01-27 03:58:55
What if you do 'parseValue (show p1)' twice?
MarcelineVQ 2017-01-27 03:59:29
bennofs1: Do you have a complete example people could try?
bennofs1 2017-01-27 04:01:17
MarcelineVQ: working on it
bennofs1 2017-01-27 04:01:19
pavonia: yes, should be
MarcelineVQ 2017-01-27 04:01:36
also what exactly is the issue? two lists both 'show'n don't parse the same?
dramforever 2017-01-27 04:02:03
but the 'show'n strings compare equal
bennofs1 2017-01-27 04:02:04
MarcelineVQ: two Strings which are equal don't parse the same
bennofs1 2017-01-27 04:02:18
also, the list should be equal
infandum 2017-01-27 04:07:01
Do you know what's silly? If I pass a (large) json string from haskell to R using haskellR and process it using jsonlite I get a sigsegv. If I first write it to a file, then use jsonlite on the file then it works. :(
bennofs1 2017-01-27 04:08:21
MarcelineVQ: not quite standalone, but checkout https://github.com/bennofs/docvim/tree/weird. Run `stack build`, followed by `stack exec runhaskell Test.hs`
MarcelineVQ 2017-01-27 04:19:44
well then... if you want to see somehting really interesting try parsing ps as well and reandomising the order you do the parses in
bennofs1 2017-01-27 04:21:32
MarcelineVQ: yeah I found that this is nondeterministic
MarcelineVQ 2017-01-27 04:21:33
just parsing p1 8 times in a row gives you different results, something is wicked off