Home freenode/#haskell: Logs Calendar

Logs: freenode/#haskell

←Prev  Next→
Page 1 .. 829 830 831 832 833 834 835 836 837 838 839 .. 5022
502,152 events total
2020-10-23 22:03:48 × ulidtko quits (~ulidtko@193.111.48.79) (Remote host closed the connection)
2020-10-23 22:03:55 <maerwald> what are you reading?
2020-10-23 22:03:55 fendor joins (~fendor@178.115.130.82.wireless.dyn.drei.com)
2020-10-23 22:04:03 ulidtko joins (~ulidtko@193.111.48.79)
2020-10-23 22:04:05 <crestfallen> so I'm confused about Nothing as non/effectual
2020-10-23 22:04:09 <dminuoso> an "effect" is really just a handwavy and very non-precise idea that comes from already existing intuition
2020-10-23 22:04:32 <dminuoso> "effect" is not something useful for understanding what all of this means, it's rather the *result* of having gained some understanding, and making some analogies
2020-10-23 22:04:37 <maerwald> This sounds like lecture notes :p
2020-10-23 22:05:34 × conal quits (~conal@64.71.133.70) (Quit: Computer has gone to sleep.)
2020-10-23 22:05:35 <crestfallen> one moment pls
2020-10-23 22:05:39 × britva quits (~britva@2a02:aa13:7240:2980:15e:53b7:85f5:d29f) (Quit: This computer has gone to sleep)
2020-10-23 22:06:12 <maerwald> crestfallen: you can think of `Maybe Int` as having an effect flow (Nothing and Just) and a value flow (Int)
2020-10-23 22:06:13 × Varis quits (~Tadas@unaffiliated/varis) (Remote host closed the connection)
2020-10-23 22:06:18 conal joins (~conal@64.71.133.70)
2020-10-23 22:06:21 × conal quits (~conal@64.71.133.70) (Client Quit)
2020-10-23 22:06:43 × LKoen quits (~LKoen@lstlambert-657-1-123-43.w92-154.abo.wanadoo.fr) (Quit: “It’s only logical. First you learn to talk, then you learn to think. Too bad it’s not the other way round.”)
2020-10-23 22:07:03 conal joins (~conal@64.71.133.70)
2020-10-23 22:07:08 × conal quits (~conal@64.71.133.70) (Client Quit)
2020-10-23 22:07:18 <maerwald> `join` just combines the effects... it's actually pretty boring
2020-10-23 22:07:19 <maerwald> :p
2020-10-23 22:07:21 <crestfallen> so if we extract Nothing from Just -- join Just Nothing -- what is the result, Nothing, there? just out of curiosity
2020-10-23 22:07:49 conal joins (~conal@64.71.133.70)
2020-10-23 22:07:50 <maerwald> crestfallen: https://hackage.haskell.org/package/base-4.14.0.0/docs/src/GHC.Base.html#line-1005
2020-10-23 22:07:55 × conal quits (~conal@64.71.133.70) (Client Quit)
2020-10-23 22:08:35 <maerwald> maybe would be nicer to show the pattern matching for join
2020-10-23 22:08:36 conal joins (~conal@64.71.133.70)
2020-10-23 22:08:37 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
2020-10-23 22:08:43 × conal quits (~conal@64.71.133.70) (Client Quit)
2020-10-23 22:08:47 × ech quits (~user@gateway/tor-sasl/ech) (Remote host closed the connection)
2020-10-23 22:09:03 ech joins (~user@gateway/tor-sasl/ech)
2020-10-23 22:09:09 <crestfallen> not sure I follow, if Just and Nothing are both in the effect flow..
2020-10-23 22:09:50 <crestfallen> because my notes have Nothing as effectual, but in this case Nothing is in the parameter
2020-10-23 22:11:11 <maerwald> crestfallen: https://paste.tomsmeding.com/lJ9EjYAJ
2020-10-23 22:11:37 <maerwald> pretty boring right?
2020-10-23 22:11:37 × p8m quits (p8m@gateway/vpn/protonvpn/p8m) (Ping timeout: 264 seconds)
2020-10-23 22:11:43 × fendor quits (~fendor@178.115.130.82.wireless.dyn.drei.com) (Remote host closed the connection)
2020-10-23 22:12:18 p8m joins (p8m@gateway/vpn/protonvpn/p8m)
2020-10-23 22:13:05 <crestfallen> its boring but then I read about effects .. once again .. and have to be content without understanding it.
2020-10-23 22:13:42 <maerwald> that's just jargon... what matters is the typeclass
2020-10-23 22:13:43 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 246 seconds)
2020-10-23 22:13:56 <maerwald> and that it applies for many more stuff
2020-10-23 22:14:23 × Franciman quits (~francesco@host-82-54-10-114.retail.telecomitalia.it) (Quit: Leaving)
2020-10-23 22:14:28 <maerwald> > join [[1,2,3]]
2020-10-23 22:14:31 <lambdabot> [1,2,3]
2020-10-23 22:15:17 <crestfallen> join == concat
2020-10-23 22:16:41 <maerwald> > join (+) 8
2020-10-23 22:16:44 <lambdabot> 16
2020-10-23 22:16:45 <maerwald> xD
2020-10-23 22:16:52 <maerwald> ignore that one
2020-10-23 22:17:05 <crestfallen> ??
2020-10-23 22:17:10 <crestfallen> > join (+) 8
2020-10-23 22:17:12 <lambdabot> 16
2020-10-23 22:18:26 <maerwald> > join (\x -> \y -> x + y) 8
2020-10-23 22:18:28 <lambdabot> 16
2020-10-23 22:18:36 <maerwald> so functions are monads too
2020-10-23 22:19:15 <crestfallen> god I have notes that seem to be conflicting.. maddening
2020-10-23 22:20:26 <maerwald> here's the definition https://hackage.haskell.org/package/base-4.14.0.0/docs/src/GHC.Base.html#line-979
2020-10-23 22:21:27 × GyroW quits (~GyroW@unaffiliated/gyrow) (Quit: Someone ate my pie)
2020-10-23 22:21:45 GyroW joins (~GyroW@ptr-48ujrfd1ztq5fjywfw3.18120a2.ip6.access.telenet.be)
2020-10-23 22:21:45 × GyroW quits (~GyroW@ptr-48ujrfd1ztq5fjywfw3.18120a2.ip6.access.telenet.be) (Changing host)
2020-10-23 22:21:45 GyroW joins (~GyroW@unaffiliated/gyrow)
2020-10-23 22:22:20 <maerwald> Also see this in-depth answer: https://stackoverflow.com/a/5316690
2020-10-23 22:22:39 <crestfallen> maerwald, I have this: An 'm a' is an effect; Nothing is not an 'm a'
2020-10-23 22:22:55 <maerwald> > Nothing :: Maybe Int
2020-10-23 22:22:57 <lambdabot> Nothing
2020-10-23 22:23:00 <maerwald> why not?
2020-10-23 22:23:52 <crestfallen> > Nothing :: Maybe Bool
2020-10-23 22:23:54 <lambdabot> Nothing
2020-10-23 22:24:12 <crestfallen> interesting.
2020-10-23 22:24:19 × chaosmasttter quits (~chaosmast@p200300c4a7138f0100d84ef38a79333e.dip0.t-ipconnect.de) (Quit: WeeChat 2.9)
2020-10-23 22:24:22 <maerwald> stop thinking about effects
2020-10-23 22:24:43 <crestfallen> ok that's interesting thanks , I'll read that SO. appreciate it!
2020-10-23 22:24:50 <maerwald> it's just a class: Monad
2020-10-23 22:25:24 <crestfallen> maerwald, let me show you one thing...
2020-10-23 22:26:11 × mimi_vx quits (mimi1vx@nat/suse/x-mbferublenzmdqyh) (Quit: ZNC 1.7.5 - https://znc.in)
2020-10-23 22:29:43 × tromp quits (~tromp@dhcp-077-249-230-040.chello.nl) (Remote host closed the connection)
2020-10-23 22:29:59 DataComputist joins (~lumeng@static-50-43-26-251.bvtn.or.frontiernet.net)
2020-10-23 22:32:32 <crestfallen> "effect" acquired a second meaning broader than that of "side-effect" -- namely, whatever is introduced through a type constructor which is a Monad instance.
2020-10-23 22:33:00 <maerwald> I'm getting headache reading that :D
2020-10-23 22:33:07 <crestfallen> :)
2020-10-23 22:33:10 <crestfallen> sorry
2020-10-23 22:33:20 <maerwald> Is it lecture notes?
2020-10-23 22:33:50 <crestfallen> it's SO but it's referring to a Wadler paper
2020-10-23 22:34:15 <maerwald> He's maybe a bit too smart to explain it simply :p
2020-10-23 22:34:38 <maerwald> "side-effect" is an even more confusing term too
2020-10-23 22:34:44 <maerwald> even haskellers get confused about it
2020-10-23 22:34:55 × alp quits (~alp@2a01:e0a:58b:4920:80f:b0e:18f1:7b3) (Ping timeout: 272 seconds)
2020-10-23 22:35:16 <crestfallen> monads encapsulate effects.. so it's something I'll just ignore for a while I gues
2020-10-23 22:35:17 <crestfallen> s
2020-10-23 22:35:28 hackage capnp 0.7.0.0 - Cap'n Proto for Haskell https://hackage.haskell.org/package/capnp-0.7.0.0 (isd)
2020-10-23 22:35:39 <maerwald> did you remeber the Monad instance of Maybe?
2020-10-23 22:35:50 <maerwald> It starts like this: "instance Monad Maybe where"
2020-10-23 22:36:06 <maerwald> not "instance Monad Maybe a where"
2020-10-23 22:36:11 × justanotheruser quits (~justanoth@unaffiliated/justanotheruser) (Ping timeout: 272 seconds)
2020-10-23 22:36:31 <maerwald> and in the definition we know nothing about the value
2020-10-23 22:36:32 constR joins (uid58205@gateway/web/irccloud.com/x-kmhanpixnsfkszux)
2020-10-23 22:36:36 <maerwald> and just do stuff with constructors
2020-10-23 22:37:00 <maerwald> if you call constructors effects, then yeah, sure
2020-10-23 22:37:35 <crestfallen> maerwald, thanks I'll sort it out
2020-10-23 22:37:58 hackage gopro-plus 0.4.1.1 - GoPro Plus Client API. https://hackage.haskell.org/package/gopro-plus-0.4.1.1 (dustin)

All times are in UTC.