Home freenode/#haskell: Logs Calendar

Logs: freenode/#haskell

←Prev  Next→ 502,152 events total
2021-04-10 23:17:49 × tefter quits (~bmaxa@62.240.24.69) (Quit: WeeChat 3.1)
2021-04-10 23:18:49 × ep1ctetus quits (~epictetus@ip72-194-215-136.sb.sd.cox.net) (Ping timeout: 252 seconds)
2021-04-10 23:20:56 ep1ctetus_ joins (~epictetus@ip72-194-215-136.sb.sd.cox.net)
2021-04-10 23:21:46 nbloomf joins (~nbloomf@2600:1700:ad14:3020:f4c0:2592:d146:5f01)
2021-04-10 23:22:02 <edwardk> justsomeguy: it'll always peel off arguments from the right. Consider if you could do otherwise. e.g. I might want fmap to map over the left half of a pair or to map over the right half of a pair, and i just call 'fmap (+1) (2,3)' -- which fmap did i mean?
2021-04-10 23:22:29 falafel joins (~falafel@pool-96-255-70-50.washdc.fios.verizon.net)
2021-04-10 23:22:31 <edwardk> justsomeguy: to ensure that instance resolution is always unambiguous there are no 'type lambdas' that you can use for the instance descriptions.
2021-04-10 23:23:24 × ulfryk quits (~ulfryk@2a01:4b00:872d:e600:a55a:b8e3:54cc:d8d6) (Remote host closed the connection)
2021-04-10 23:23:25 <edwardk> Foldable :: (Type -> Type) -> Constraint -- is a way to say that it is a constraint that works on any type constructor of kind Type -> Type. (Type is another way to say *, you can import it from Data.Kind.
2021-04-10 23:23:48 <edwardk> It might be easier to start with something like Eq :: Type -> Constraint or Ord :: Type -> Constraint.
2021-04-10 23:24:08 × epicte7us quits (~epictetus@ip72-194-215-136.sb.sd.cox.net) (Ping timeout: 268 seconds)
2021-04-10 23:24:10 <edwardk> Int :: Type; so we can talk about Eq Int :: Constraint
2021-04-10 23:24:19 hendursaga joins (~weechat@gateway/tor-sasl/hendursaga)
2021-04-10 23:24:21 Guest_96 joins (18e9d4cb@d-24-233-212-203.nh.cpe.atlanticbb.net)
2021-04-10 23:24:38 <edwardk> that is the type of 'proofs' or 'dictionaries' that Int is an instance of Eq.
2021-04-10 23:24:50 <edwardk> you use those on the left of => to carry along the constraint.
2021-04-10 23:25:08 <edwardk> e.g. sort :: Ord a => [a] -> [a]
2021-04-10 23:25:30 × haskellstudent quits (~quassel@213-225-6-101.nat.highway.a1.net) (Ping timeout: 260 seconds)
2021-04-10 23:25:54 <edwardk> Going back to your "Three" type. you have Three :: Type -> Type -> Type -> Type; Three Int :: Type -> Type -> Type; Three Int Bool :: Type -> Type
2021-04-10 23:26:12 <edwardk> now you have something of the right form that you could pass it to Foldable or Functor or Traversable
2021-04-10 23:26:31 × nbloomf quits (~nbloomf@2600:1700:ad14:3020:f4c0:2592:d146:5f01) (Client Quit)
2021-04-10 23:28:04 nbloomf joins (~nbloomf@2600:1700:ad14:3020:f4c0:2592:d146:5f01)
2021-04-10 23:30:58 epicte7us joins (~epictetus@ip72-194-215-136.sb.sd.cox.net)
2021-04-10 23:31:31 × myShoggoth quits (~myShoggot@75.164.73.93) (Ping timeout: 268 seconds)
2021-04-10 23:33:03 fiedlr joins (~fiedlr@83.148.33.254)
2021-04-10 23:33:06 <justsomeguy> Ok, interesting.
2021-04-10 23:33:31 <justsomeguy> So why is that I can define an instance by ignoring the innermost type variables at all? Shouldn't I have to make a type alias, first, or something, to get rid of the unused type arguments?
2021-04-10 23:34:01 × ep1ctetus_ quits (~epictetus@ip72-194-215-136.sb.sd.cox.net) (Ping timeout: 252 seconds)
2021-04-10 23:34:11 <c_wraith> nah. types are curried, just like values
2021-04-10 23:34:41 <c_wraith> you can use `map show' without assigning it to a name
2021-04-10 23:37:16 kiweun joins (~kiweun@2607:fea8:2a62:9600:e006:3e43:5d26:4dc1)
2021-04-10 23:40:21 × snowflake quits (~snowflake@gateway/tor-sasl/snowflake) (Ping timeout: 240 seconds)
2021-04-10 23:40:38 Guest78317 joins (~laudiacay@67.176.215.84)
2021-04-10 23:40:56 snowflake joins (~snowflake@gateway/tor-sasl/snowflake)
2021-04-10 23:42:00 × kiweun quits (~kiweun@2607:fea8:2a62:9600:e006:3e43:5d26:4dc1) (Ping timeout: 258 seconds)
2021-04-10 23:43:01 × __minoru__shirae quits (~shiraeesh@46.34.207.175) (Ping timeout: 252 seconds)
2021-04-10 23:43:43 myShoggoth joins (~myShoggot@75.164.73.93)
2021-04-10 23:44:42 × Guest78317 quits (~laudiacay@67.176.215.84) (Ping timeout: 240 seconds)
2021-04-10 23:47:19 × Guest_96 quits (18e9d4cb@d-24-233-212-203.nh.cpe.atlanticbb.net) (Quit: Ping timeout (120 seconds))
2021-04-10 23:47:19 × Tario quits (~Tario@201.192.165.173) (Read error: Connection reset by peer)
2021-04-10 23:47:33 Tario joins (~Tario@201.192.165.173)
2021-04-10 23:48:45 × bitdex quits (~bitdex@gateway/tor-sasl/bitdex) (Ping timeout: 240 seconds)
2021-04-10 23:50:03 bitdex joins (~bitdex@gateway/tor-sasl/bitdex)
2021-04-10 23:50:22 cole-h joins (~cole-h@c-73-48-197-220.hsd1.ca.comcast.net)
2021-04-10 23:51:34 ulfryk joins (~ulfryk@2a01:4b00:872d:e600:a55a:b8e3:54cc:d8d6)
2021-04-10 23:52:10 <koz_> Does {Haskell, GHC} allow _prefix_ operators?
2021-04-10 23:52:22 <koz_> I assume 'no', but maybe there's some magic-AF extension which does.
2021-04-10 23:52:22 × Deide quits (~Deide@217.155.19.23) (Quit: Seeee yaaaa)
2021-04-10 23:54:08 × nbloomf quits (~nbloomf@2600:1700:ad14:3020:f4c0:2592:d146:5f01) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2021-04-10 23:54:16 × justanotheruser quits (~justanoth@unaffiliated/justanotheruser) (Ping timeout: 258 seconds)
2021-04-10 23:54:42 rekahsoft joins (~rekahsoft@cpe0008a20f982f-cm64777d666260.cpe.net.cable.rogers.com)
2021-04-10 23:56:07 × ulfryk quits (~ulfryk@2a01:4b00:872d:e600:a55a:b8e3:54cc:d8d6) (Ping timeout: 250 seconds)
2021-04-10 23:57:09 ulfryk joins (~ulfryk@2a01:4b00:872d:e600:a55a:b8e3:54cc:d8d6)
2021-04-10 23:57:26 × myShoggoth quits (~myShoggot@75.164.73.93) (Ping timeout: 240 seconds)
2021-04-10 23:58:17 × acidjnk_new quits (~acidjnk@p200300d0c72b9512392c48d8e031de92.dip0.t-ipconnect.de) (Ping timeout: 250 seconds)
2021-04-10 23:59:18 chenshen joins (~chenshen@2620:10d:c090:400::5:42e9)
2021-04-10 23:59:58 × nut quits (~user@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Ping timeout: 240 seconds)
2021-04-11 00:00:04 <justsomeguy> What would a prefix operator look like?
2021-04-11 00:00:33 <justsomeguy> Kind of like a function with symbols in the identifier?
2021-04-11 00:01:51 × ulfryk quits (~ulfryk@2a01:4b00:872d:e600:a55a:b8e3:54cc:d8d6) (Ping timeout: 260 seconds)
2021-04-11 00:02:29 × HannaM quits (~quassel@p54849510.dip0.t-ipconnect.de) (Quit: http://quassel-irc.org - Chat comfortably. Anywhere.)
2021-04-11 00:02:45 <DigitalKiwi> --koz_
2021-04-11 00:02:59 manicpolymath joins (49369f53@c-73-54-159-83.hsd1.ga.comcast.net)
2021-04-11 00:04:48 × carlomagno quits (~cararell@148.87.23.8) (Quit: Leaving.)
2021-04-11 00:08:06 <koz_> I'm imagining something like a prefix version of 'complement'.
2021-04-11 00:08:22 <koz_> So instead of writing 'complement foo', it'd be like, '.~. foo' or something.
2021-04-11 00:08:33 <koz_> But now that I look at it, I can see the issue, lol.
2021-04-11 00:10:36 <c_wraith> well, inasmuch as Haskell supports postfix operators, it supports prefix operators that return a function. :P
2021-04-11 00:11:29 <koz_> c_wraith: Wait I don't understand?
2021-04-11 00:12:22 locrian9 joins (~mike@99-153-255-194.lightspeed.irvnca.sbcglobal.net)
2021-04-11 00:13:03 <c_wraith> ghc has an extension for postfix operators... that work by slightly liberalizing the section rules such that (foo@#%) is parsed as a section, but need not return a function.
2021-04-11 00:13:19 × Iryon quits (~Iryon@185-12-21-77.sigma.jaslo.pl) (Remote host closed the connection)
2021-04-11 00:13:27 × Tario quits (~Tario@201.192.165.173) (Read error: Connection reset by peer)
2021-04-11 00:13:29 <c_wraith> You could always main ($*#foo) an expression now. it just has to return a function :)
2021-04-11 00:13:34 <c_wraith> *make
2021-04-11 00:14:40 × mouseghost quits (~draco@wikipedia/desperek) (Quit: mew wew)
2021-04-11 00:15:02 <koz_> OK, thanks.
2021-04-11 00:16:04 myShoggoth joins (~myShoggot@75.164.73.93)
2021-04-11 00:17:11 × frozenErebus quits (~frozenEre@37.231.244.249) (Ping timeout: 240 seconds)
2021-04-11 00:20:06 × Sorny quits (~Sornaensi@077213203030.dynamic.telenor.dk) (Ping timeout: 260 seconds)
2021-04-11 00:24:30 × manicpolymath quits (49369f53@c-73-54-159-83.hsd1.ga.comcast.net) (Quit: Ping timeout (120 seconds))
2021-04-11 00:25:10 olligobber joins (olligobber@gateway/vpn/privateinternetaccess/olligobber)
2021-04-11 00:25:11 × star_cloud quits (~star_clou@ec2-34-220-44-120.us-west-2.compute.amazonaws.com) (Ping timeout: 240 seconds)
2021-04-11 00:30:00 × Tuplanolla quits (~Tuplanoll@91-159-68-239.elisa-laajakaista.fi) (Quit: Leaving.)
2021-04-11 00:30:44 × myShoggoth quits (~myShoggot@75.164.73.93) (Ping timeout: 268 seconds)
2021-04-11 00:30:58 ep1ctetus_ joins (~epictetus@ip72-194-215-136.sb.sd.cox.net)
2021-04-11 00:31:20 manicpolymath joins (49369f53@c-73-54-159-83.hsd1.ga.comcast.net)
2021-04-11 00:33:54 kaction joins (~kaction@pool-96-255-101-159.washdc.fios.verizon.net)
2021-04-11 00:34:04 Tario joins (~Tario@201.192.165.173)
2021-04-11 00:34:04 × Tario quits (~Tario@201.192.165.173) (Read error: Connection reset by peer)
2021-04-11 00:34:10 × epicte7us quits (~epictetus@ip72-194-215-136.sb.sd.cox.net) (Ping timeout: 252 seconds)
2021-04-11 00:34:29 × manicpolymath quits (49369f53@c-73-54-159-83.hsd1.ga.comcast.net) (Client Quit)
2021-04-11 00:34:41 × falafel quits (~falafel@pool-96-255-70-50.washdc.fios.verizon.net) (Ping timeout: 240 seconds)
2021-04-11 00:37:12 × locrian9 quits (~mike@99-153-255-194.lightspeed.irvnca.sbcglobal.net) (Quit: Lost terminal)
2021-04-11 00:38:20 locrian9 joins (~mike@99-153-255-194.lightspeed.irvnca.sbcglobal.net)
2021-04-11 00:38:42 × jess quits (jess@freenode/staff/jess) (Quit: K-Lined)
2021-04-11 00:38:51 jess joins (jess@freenode/staff/jess)
2021-04-11 00:40:23 × hendursaga quits (~weechat@gateway/tor-sasl/hendursaga) (Remote host closed the connection)
2021-04-11 00:40:46 hendursaga joins (~weechat@gateway/tor-sasl/hendursaga)
2021-04-11 00:42:09 rprije joins (~rprije@59-102-63-15.tpgi.com.au)

All times are in UTC.