<    April 2017    >
Su Mo Tu We Th Fr Sa  
                   1  
 2  3  4  5  6  7  8  
 9 10 11 12 13 14 15  
16 17 18 19 20 21 22  
23 24 25 26 27 28 29  
30
00:04 malaclyps joined
00:08 peterbecich joined
00:15 eacameron joined
00:17 sigmundv joined
00:18 carlomagno joined
00:21 aarvar joined
00:36 baweaver joined
00:39 malaclyps joined
00:42 meandi joined
00:43 nicknovi1 joined
00:45 sigmundv joined
00:46 eacameron joined
00:47 <peterbecich> Hi, does "{..}" have a name? It's used in Yesod: return App {..}
00:49 <geekosaur> record wildcard
00:49 <peterbecich> Thanks!!
00:50 <geekosaur> in this case, it's taking the values of record fields from bindings of the same name that are in scope
00:50 acarrico joined
00:51 <peterbecich> cool, that helps. I will put a new value in the scope, then. Thanks!
00:52 Lokathor_ joined
00:54 vaibhavsagar joined
00:57 sigmundv joined
00:57 meandi_2 joined
00:57 newhoggy_ joined
00:58 watersoul_ joined
01:00 newhoggy_ joined
01:01 baweaver joined
01:02 brezel joined
01:02 cschneid_ joined
01:05 zerokarmaleft joined
01:11 skeet70 joined
01:12 lukky513 joined
01:14 cschneid_ joined
01:15 Rodya_ joined
01:20 moei joined
01:31 brezel joined
01:33 JoelMcCracken joined
01:34 eacameron joined
01:38 eacamero_ joined
01:45 eacameron joined
01:50 eacameron joined
01:51 nicknovi1 joined
01:51 conal joined
01:54 conal joined
01:54 eacamero_ joined
02:00 conal joined
02:02 eacameron joined
02:02 cschneid_ joined
02:02 twopoint718 joined
02:07 Youmu joined
02:12 newhoggy joined
02:13 newhoggy joined
02:17 Rodya_ joined
02:35 gothos joined
02:43 eacameron joined
02:45 takle joined
02:48 exferenceBot joined
02:52 hexagoxel joined
02:53 peterbecich joined
02:55 eacameron joined
02:55 bydo joined
02:55 cschneid_ joined
02:57 amatecha joined
02:58 cschneid_ joined
03:02 takle joined
03:13 newhoggy joined
03:18 Rodya_ joined
03:22 dni- joined
03:29 takle joined
03:35 texasmynsted joined
03:36 harfangk joined
03:39 jamin1001_ joined
03:42 takle joined
03:47 takle joined
03:50 hphuoc25 joined
03:55 takle joined
04:09 takle joined
04:15 shawn_lu joined
04:17 LiaoTao joined
04:19 Rodya_ joined
04:20 <shawn_lu> Hi friends, I’m looking at Parsing typeclass, just trying out Trifecta library, it puzzles me that a simple example like semiColon = char ';' will give me ambiguous type variable error.
04:20 pixelfog_ joined
04:20 <shawn_lu> http://hackage.haskell.org/package/parsers-0.12.4/docs/Text-Parser-Char.html#t:CharParsing
04:20 <shawn_lu> I’m just testing the example right at that page
04:21 <glguy> shawn_lu: Why does that puzzle you?
04:22 takle joined
04:22 <shawn_lu> the type signature says takeing a char, and ‘;’ is a char
04:22 <jle`> that's not the ambiguous part :)
04:22 systemfault joined
04:22 <jle`> it's the 'm' that's ambiguous
04:23 <jle`> char :: CharParsing m => Char -> m Char
04:23 <jle`> the type error should probably give this away
04:23 <glguy> Yeah, the type error says that • Ambiguous type variable ‘m0’ arising from a use of ‘char’ prevents the constraint ‘(CharParsing m0)’ from being solved.
04:24 <glguy> and that the relevant binding is semiColon :: m0 Char (bound at <interactive>:8:1)
04:25 vicfred joined
04:26 LiaoTao joined
04:28 <shawn_lu> thanks @jle` @glguy, so what should be the right expression then...
04:29 <glguy> you need to specify the type you want semiColon to have so that it won't be ambiguous
04:30 <glguy> because the inferred type requires a type class constraint, you have to specify. this is the monomorphism restriction
04:35 ysgard joined
04:39 <jamin1001_> anyone know how to change temp directory of "stack setup", since there is not enough room to install GHC on my Debian VM? I tried setting local-programs-path per the FAQ but I get: Warning: /home/vagrant/.stack/config.yaml: Unrecognized field in ConfigMonoid: local-programs-path
04:39 <shawn_lu> @glguy thanks for the tip, really haven’t got used to putting type constraint on a concrete value
04:39 <lambdabot> Unknown command, try @list
04:45 galderz joined
04:46 Levex joined
04:49 <glguy> what's a concrete value?
04:51 wedens joined
04:55 hazyPurple joined
05:02 newhoggy_ joined
05:05 <MarcelineVQ> jamin1001_: that error tends to mean you've put the flag in the wrong place in the yaml, or your stack version doesn't recognise it, you need at least stack 1.3.0 to use that line, what does your .yaml loook like?
05:11 dni- joined
05:12 <jamin1001_> thanks Marcel I only have 1.2.0, will upgrade it and then see
05:18 keutoi joined
05:20 Rodya_ joined
05:27 keutoi joined
05:28 vaibhavsagar joined
05:35 cschneid_ joined
05:39 newhoggy joined
05:40 nobodyzxc joined
05:43 newhoggy_ joined
05:51 takle joined
05:55 hazyPurple joined
06:03 hphuoc25 joined
06:05 eatman joined
06:12 <eatman> Hi!
06:15 <eatman> Hey tell me, is there a common way to "fake" the idris-like typedependent system using pattern matching?
06:16 <eatman> I've Trees with given depths level and I want to write a functin that combine them but it should not work unless the all are the same depth.
06:18 shawn_lu joined
06:19 <MarcelineVQ> Yes. https://www.youtube.com/watch?v=P4Io2CRpwyg
06:20 <eatman> MarcelineVQ: thanks, watching now.
06:20 <MarcelineVQ> there's other weaker ways as well but that talk is mostly about that question
06:20 Rodya_ joined
06:21 kritzcreek joined
06:27 <eatman> Well, I don't really have an hour right now, i'll look for textual explanations.
06:30 salva joined
06:37 govg joined
06:39 newhoggy joined
06:48 filostrato joined
06:55 filostrato joined
07:00 dni- joined
07:00 nacon joined
07:00 nacon joined
07:00 filostrato joined
07:03 filostrato joined
07:04 <LiaoTao> http://lpaste.net/354940
07:04 <LiaoTao> Managed to solve yesterday's problem with the tuple method!
07:04 <LiaoTao> It's a bit messy without using Sets, though
07:09 nickager joined
07:13 nickolay joined
07:17 binaryplease joined
07:19 Pupnik joined
07:21 Rodya_ joined
07:22 takle joined
07:23 mattyw joined
07:24 nobodyzx1 joined
07:24 Durz0 joined
07:25 nobodyzxc joined
07:28 thc202 joined
07:28 nobodyzxc joined
07:29 nobodyzxc joined
07:30 bvad joined
07:31 dni- joined
07:37 nobodyzxc joined
07:42 takle joined
07:47 hphuoc25 joined
07:52 mstruebing joined
07:52 shayan_ joined
08:04 madjestic joined
08:05 nil_ joined
08:12 gfixler joined
08:22 Rodya_ joined
08:22 colt44 joined
08:32 grdryn joined
08:34 cschneid_ joined
08:40 jgertm joined
08:40 mthek joined
08:53 zero_byte joined
08:56 nickager joined
08:59 Iceland_jack joined
09:01 eacameron joined
09:11 mthek joined
09:23 Rodya_ joined
09:41 pbrant joined
09:52 AndroUser joined
09:52 hphuoc25 joined
10:03 alqatari joined
10:05 fbergmann joined
10:11 hphuoc25 joined
10:19 uglyfigurine joined
10:26 newhoggy joined
10:37 m` joined
10:44 yellowj joined
10:52 xificurC joined
11:01 netheranthem joined
11:09 mengu joined
11:16 newhoggy joined
11:21 merijn joined
11:23 hphuoc25 joined
11:24 hphuoc25 joined
11:24 Rodya_ joined
11:45 <nickolay> saylu: may be this lib will help you
11:45 <nickolay> saylu: http://nikita-volkov.github.io/first-class-sums-and-products/
11:56 guampa joined
12:00 dni- joined
12:14 Iceland_jack joined
12:25 Rodya_ joined
12:33 newhoggy joined
12:35 cschneid_ joined
12:35 vmeson joined
12:41 newhoggy joined
12:51 takle joined
12:54 nickager joined
12:58 nobodyzxc joined
13:01 nobodyzxc joined
13:01 mthek joined
13:03 nobodyzxc joined
13:12 iAmerikan joined
13:21 jathan joined
13:26 Rodya_ joined
13:26 newhoggy joined
13:32 madjestic joined
13:34 newhoggy joined
13:34 fbergmann joined
13:34 <eatman> quit
13:35 cschneid_ joined
13:41 eacameron joined
13:43 pbrant joined
13:44 newhoggy joined
13:47 carlomagno1 joined
13:49 dni- joined
13:53 newhoggy joined
13:57 mizu_no_oto_work joined
13:58 chlong joined
14:01 grdryn joined
14:05 galderz joined
14:05 newhoggy joined
14:13 newhoggy joined
14:15 pungi-man joined
14:16 newhoggy joined
14:20 simendsjo joined
14:21 newhoggy joined
14:22 hphuoc25 joined
14:26 Rodya_ joined
14:28 vaibhavsagar joined
14:31 seangrove joined
14:34 ralu joined
14:34 plakband joined
14:38 senorchang joined
14:38 thang1 joined
14:41 govg joined
14:42 newhoggy joined
14:52 ghiro joined
14:57 nicknovi1 joined
14:58 newhoggy joined
14:58 senorchang joined
14:58 NeverDie joined
14:59 thang1 joined
15:00 senorchang joined
15:00 thang1 joined
15:04 newhoggy joined
15:08 bvad joined
15:11 xificurC joined
15:12 newhoggy joined
15:14 NeverDie joined
15:17 eacameron joined
15:21 cschneid_ joined
15:24 newhoggy joined
15:27 Rodya_ joined
15:31 vmeson joined
15:34 skeet70 joined
15:36 uglyfigurine joined
15:38 dni- joined
15:42 NeverDie joined
15:44 NeverDie joined
15:44 newhoggy joined
15:45 zero_byte joined
15:55 NeverDie joined
15:56 yellowj joined
16:00 newhoggy joined
16:03 meandi joined
16:11 newhoggy joined
16:12 meandi_2 joined
16:13 ysgard joined
16:20 iAmerikan joined
16:22 newhoggy joined
16:22 Rodya_ joined
16:27 harfangk joined
16:27 mthek joined
16:27 newhoggy joined
16:33 mizu_no_oto_work joined
16:35 newhoggy joined
16:38 vmeson joined
16:39 pbrant joined
16:41 mthek joined
16:43 pilne joined
16:47 newhoggy joined
16:49 baweaver left
16:50 crave joined
16:54 aarvar joined
16:54 aarvar left
16:56 binaryplease joined
17:01 conal joined
17:01 jrm joined
17:04 pixelfog_ joined
17:08 conal joined
17:09 newhoggy joined
17:24 newhoggy joined
17:25 tusj joined
17:27 dni- joined
17:27 colt44 joined
17:35 ploop joined
17:37 NeverDie joined
17:40 newhoggy joined
17:41 bvad joined
17:44 hazyPurple joined
17:47 newhoggy joined
17:53 newhoggy joined
17:58 takle joined
18:05 newhoggy joined
18:15 madjestic joined
18:19 newhoggy joined
18:28 kritzcreek joined
18:32 mac10688 joined
18:35 yellowj joined
18:36 malaclyps joined
18:38 <Squarism> i have a function (long and complex - so dont wanna rewrite to much) where i want to add a custom computation that is returned part of the result. Before f :: a1-> a2-> a3 -> r . So i wanna change it to f :: a1-> a2-> a3 -> s -> (r,s)
18:38 newhoggy joined
18:38 <Squarism> i hoped that state monad was perfect for this as i thought it both encapsulates a state and a function
18:39 <monochrom> State is s->(r,s)
18:40 <monochrom> In other words you can make it a1 -> a2 -> a3 -> State s r
18:41 <Squarism> f is reall : ... -> IO (GameContext a)
18:41 <Squarism> really
18:41 <monochrom> Then you're looking at StateT. a1 -> a2 -> a3 -> StateT s IO r
18:42 <Squarism> Id hoped i could change it to IO (GameContext a, State r a)
18:42 <monochrom> No, that's wrong intuition.
18:42 <Squarism> im sure it is! =D
18:43 <Squarism> Understand its my first state monad and ive never grasped its usefulness. So i thought id try it
18:43 <Squarism> wo changing my function to much
18:43 <Squarism> im not after "correct" or "beutiful" here
18:44 <monochrom> There is an alternative. Use an IORef.
18:44 <Squarism> i just hoped i could use State monad as a computational value
18:44 <Squarism> a probe really
18:49 texasmynsted joined
18:54 newhoggy joined
18:55 takle joined
18:55 texasmynsted joined
18:58 takle joined
19:00 ego joined
19:08 Brokenprogrammer joined
19:09 <Brokenprogrammer> Hello
19:10 newhoggy joined
19:12 Rodya_ joined
19:13 <monochrom> Squarism: The thing to note is that "S -> IO (R, S)" is very different from "IO (?, S -> (R,S))"
19:15 <Squarism> monochrom, to tell you the truth - right now im struggeling to understand what the purpose of and how to even use a single StateT/MonadState/State
19:15 <Squarism> i thought it could be used as an MVar
19:15 <Squarism> ...with an added computation
19:16 dni- joined
19:16 <Squarism> not really sure how i would even accomplish that
19:16 <monochrom> Cannot.
19:16 <Squarism> oh ok
19:16 delexi joined
19:17 <monochrom> A thread's updating an IORef or MVar can be seen from another thread. Not true for the so-called "state" of StateT.
19:17 <Squarism> ok.. that part i dont need
19:18 <monochrom> StateT fakes a stateful API but it does so by parameter passing. The illusion holds up in sequential programming only.
19:18 newhoggy joined
19:20 <Squarism> id would like something like : data CompValue a b = CompValue { apply :: a -> b -> b , currentValue :: b }
19:22 newhoggy_ joined
19:22 <Squarism> oh .. maybe more like :: data CompValue a b = CompValue { apply :: a -> CompValue a b -> CompValue a b, currentValue :: b }
19:25 peterbecich joined
19:29 mlehmk joined
19:31 <peterbecich> I'm working with Yesod and trying to get this model (https://github.com/patbecich/javascriptSandbox/blob/breakOutServer/gravityServer/config/models) into the scope of this handler (https://github.com/patbecich/javascriptSandbox/blob/breakOutServer/gravityServer/Handler/BreakOutLeaderboard.hs). The `Leaderboard` constructor is in the scope of Model
19:31 <peterbecich> (https://github.com/patbecich/javascriptSandbox/blob/breakOutServer/gravityServer/Model.hs), but not the handler.
19:31 filostrato joined
19:32 <peterbecich> If I import the `Model` module into the handler, I get this compiler error: "Failed to load interface for ‘Model’ Perhaps you haven't installed the "dyn" libraries for package ‘gravityServer-0.0.0’?"
19:32 <peterbecich>
19:33 <peterbecich> I did not use the yesod-postgres Stack template to set this up, so I'm probably missing something important. Any tips appreciated. Thanks
19:34 filostrato joined
19:34 newhoggy joined
19:39 conal joined
19:40 filostrato joined
19:41 Durbley joined
19:44 leothrix joined
19:46 filostrato joined
19:46 Deide joined
19:48 newhoggy joined
19:50 Durbley joined
19:51 filostrato joined
19:54 <houli> peterbecich: in import/NoFoundation.hs I think you'll want to import Model like this file does https://github.com/patbecich/javascriptSandbox/blob/breakOutServer/yesodBlog/Import/NoFoundation.hs
19:54 filostrato joined
19:54 <houli> that way model eventually gets reexported as Import
19:55 <houli> and you can reference the stuff in it in any module that imports Import
19:56 newhoggy joined
20:00 iAmerikan joined
20:03 filostrato joined
20:04 nicknovi1 joined
20:06 merijn joined
20:08 newhoggy joined
20:09 <peterbecich> houli: Thanks! That was exactly right
20:10 <houli> yesod does some import/reexport trickery to make everything to appear to come from the one module, can be tricky to spot the indirection at first
20:20 newhoggy joined
20:21 nicknovi1 joined
20:26 takle joined
20:28 newhoggy joined
20:33 newhoggy joined
20:34 Gurkenglas joined
20:43 zaquest joined
20:44 iAmerikan joined
20:51 newhoggy joined
20:53 mattyw joined
20:56 mengu joined
20:57 newhoggy joined
21:04 malaclyps joined
21:04 dni- joined
21:11 texasmynsted joined
21:19 <peterbecich> houli: Thanks
21:28 NeverDie joined
21:38 uglyfigurine joined
21:48 pixelfog joined
21:51 ysgard joined
21:52 hiratara joined
21:57 newhoggy joined
21:58 conal joined
21:59 vmeson joined
22:01 kaorti joined
22:04 yellowj joined
22:04 sigmundv joined
22:10 pixelfog joined
22:24 Gurkenglas joined
22:28 iAmerikan joined
22:31 hiratara joined
22:39 mattyw_ joined
22:45 conal joined
22:47 aarvar joined
22:53 dni- joined
22:56 newhoggy joined
22:58 binaryplease joined
23:06 xacktm joined
23:07 ljc joined
23:08 seanparsons joined
23:09 newhoggy_ joined
23:16 Rodya_ joined
23:22 crave joined
23:22 conal joined
23:26 newhoggy joined
23:30 newhoggy_ joined
23:35 mizu_no_oto_work joined
23:39 louispan joined
23:40 Axman6 joined
23:50 Rodya_ joined
23:52 louispan joined
23:57 cschneid_ joined
23:59 <Squarism> Gah, state monad is very abstract to me