Logs on 2023-03-02 (liberachat/#haskell)
| 00:00:17 | <remexre> | is there a trick for saying "a functor with the same shape as this value"? |
| 00:00:46 | <remexre> | e.g. I have a F a -> F b , where Functor F; I want to further say that the output needs to be the same constructor as the input |
| 00:01:15 | <remexre> | (so that I can zip it with something; if there's another way to do that, that'd work too) |
| 00:02:22 | <geekosaur> | that would be a functor |
| 00:02:41 | <geekosaur> | it's not allowed to change the constructor |
| 00:03:18 | <Clinton[m]> | geekosaur: Functors can change the constructor, they can't change the type |
| 00:03:43 | <remexre> | that'd be if the function were (Functor f => f a -> f b), not F a -> F b for a concrete F |
| 00:05:51 | <Clinton[m]> | remexre: if you can write a function `f :: a -> b`, then `fmap f :: F a -> F b` achieves what you want. |
| 00:05:59 | <monochrom> | "same shape" is already a pretty common way to say that. |
| 00:06:26 | × | xff0x quits (~xff0x@ai081074.d.east.v6connect.net) (Ping timeout: 252 seconds) |
| 00:06:42 | <remexre> | the transformation can't just be an fmap, it depends on what constructor the input is |
| 00:07:08 | × | zeenk quits (~zeenk@2a02:2f04:a20d:f900::7fe) (Quit: Konversation terminated!) |
| 00:07:15 | → | mauke_ joins (~mauke@user/mauke) |
| 00:07:54 | × | mechap quits (~mechap@user/mechap) (Ping timeout: 252 seconds) |
| 00:08:30 | → | xff0x joins (~xff0x@178.255.149.135) |
| 00:08:36 | × | mauke quits (~mauke@user/mauke) (Ping timeout: 255 seconds) |
| 00:08:37 | mauke_ | is now known as mauke |
| 00:09:30 | <jackdk> | If you ask for a function `a -> b` and fmap it yourself, you know that you won't change constructors. (If `fmap` changed constructors, it would fail the `fmap id = id` law.) |
| 00:09:31 | <geekosaur> | (then why does it matter that it's a functor?) |
| 00:10:06 | → | mechap joins (~mechap@user/mechap) |
| 00:10:11 | <Clinton[m]> | remexre: well then I think you're going to make your different constructors different types.... (full message at <https://libera.ems.host/_matrix/media/v3/download/libera.chat/de31471dd45b102c3e059ca0525c1579ad196bcc>) |
| 00:10:11 | <remexre> | in case there's a trick that only works for functors, iunno |
| 00:10:59 | <remexre> | Clinton[m]: ooh, that might do the trick |
| 00:11:13 | <Clinton[m]> | Of course pick your own data type, I just picked Maybe for illustration |
| 00:17:36 | × | foul_owl quits (~kerry@193.29.61.203) (Ping timeout: 255 seconds) |
| 00:18:57 | × | xff0x quits (~xff0x@178.255.149.135) (Ping timeout: 255 seconds) |
| 00:20:12 | → | foul_owl joins (~kerry@193.29.61.203) |
| 00:20:49 | → | xff0x joins (~xff0x@ai081074.d.east.v6connect.net) |
| 00:22:07 | × | Tuplanolla quits (~Tuplanoll@91-159-68-152.elisa-laajakaista.fi) (Quit: Leaving.) |
| 00:31:06 | → | johnw_ joins (~johnw@2600:1700:cf00:db0:a85a:aa58:c54c:551d) |
| 00:31:22 | × | acidjnk_new quits (~acidjnk@p200300d6e715c409795fa7f63fedb700.dip0.t-ipconnect.de) (Ping timeout: 252 seconds) |
| 00:33:05 | × | johnw quits (~johnw@2600:1700:cf00:db0:a85a:aa58:c54c:551d) (Ping timeout: 260 seconds) |
| 00:35:00 | → | bitdex joins (~bitdex@gateway/tor-sasl/bitdex) |
| 00:49:55 | × | Axman6 quits (~Axman6@user/axman6) (Ping timeout: 246 seconds) |
| 00:50:49 | × | ix quits (~ix@2a02:8010:674f:0:d65d:64ff:fe52:5efe) (Ping timeout: 252 seconds) |
| 00:51:33 | → | Square3 joins (~Square4@user/square) |
| 00:51:48 | × | kritzefitz quits (~kritzefit@debian/kritzefitz) (Ping timeout: 255 seconds) |
| 00:52:29 | → | kritzefitz joins (~kritzefit@debian/kritzefitz) |
| 00:54:03 | × | Square2 quits (~Square4@user/square) (Ping timeout: 255 seconds) |
| 00:56:19 | × | simeon quits (~pi@143.231.7.51.dyn.plus.net) (Ping timeout: 268 seconds) |
| 00:57:41 | → | simeon joins (~pi@170.231.7.51.dyn.plus.net) |
| 00:59:51 | × | Ranhir quits (~Ranhir@157.97.53.139) (Read error: Connection reset by peer) |
| 01:01:48 | → | ryanbooker joins (uid4340@id-4340.hampstead.irccloud.com) |
| 01:04:41 | × | califax quits (~califax@user/califx) (Remote host closed the connection) |
| 01:05:49 | → | califax joins (~califax@user/califx) |
| 01:09:23 | → | kenaryn joins (~aurele@cre71-h03-89-88-44-27.dsl.sta.abo.bbox.fr) |
| 01:10:22 | × | gmg quits (~user@user/gehmehgeh) (Remote host closed the connection) |
| 01:10:49 | × | albet70 quits (~xxx@2400:8902::f03c:92ff:fe60:98d8) (Remote host closed the connection) |
| 01:10:52 | → | Ranhir joins (~Ranhir@157.97.53.139) |
| 01:11:09 | → | wroathe joins (~wroathe@207-153-38-140.fttp.usinternet.com) |
| 01:11:10 | × | wroathe quits (~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host) |
| 01:11:10 | → | wroathe joins (~wroathe@user/wroathe) |
| 01:11:18 | → | gmg joins (~user@user/gehmehgeh) |
| 01:15:34 | × | kenaryn quits (~aurele@cre71-h03-89-88-44-27.dsl.sta.abo.bbox.fr) (Quit: leaving) |
| 01:16:57 | → | albet70 joins (~xxx@2400:8902::f03c:92ff:fe60:98d8) |
| 01:18:07 | × | chexum quits (~quassel@gateway/tor-sasl/chexum) (Remote host closed the connection) |
| 01:18:31 | → | chexum joins (~quassel@gateway/tor-sasl/chexum) |
| 01:22:00 | → | falafel joins (~falafel@2600:1700:3b2d:d010:fb97:9b4c:7fe7:93e0) |
| 01:24:33 | × | falafel quits (~falafel@2600:1700:3b2d:d010:fb97:9b4c:7fe7:93e0) (Remote host closed the connection) |
| 01:24:52 | → | falafel joins (~falafel@2600:1700:3b2d:d010:d106:c9d9:3547:5b31) |
| 01:25:11 | × | stackdroid18 quits (14094@de1.hashbang.sh) (Quit: hasta la vista... tchau!) |
| 01:27:03 | × | falafel quits (~falafel@2600:1700:3b2d:d010:d106:c9d9:3547:5b31) (Remote host closed the connection) |
| 01:27:23 | → | falafel joins (~falafel@2600:1700:3b2d:d010:9c00:d384:93c4:675d) |
| 01:40:59 | → | Axman6 joins (~Axman6@user/axman6) |
| 01:43:32 | × | gmg quits (~user@user/gehmehgeh) (Ping timeout: 255 seconds) |
| 01:43:59 | × | xff0x quits (~xff0x@ai081074.d.east.v6connect.net) (Ping timeout: 248 seconds) |
| 01:44:15 | × | td_ quits (~td@i53870923.versanet.de) (Ping timeout: 260 seconds) |
| 01:44:29 | → | td_ joins (~td@i53870923.versanet.de) |
| 01:44:35 | → | gmg joins (~user@user/gehmehgeh) |
| 01:53:19 | × | eggplantade quits (~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
| 01:56:20 | → | eggplantade joins (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) |
| 02:00:36 | × | meinside quits (uid24933@id-24933.helmsley.irccloud.com) (Quit: Connection closed for inactivity) |
| 02:13:10 | × | shapr quits (~user@68.54.166.125) (Ping timeout: 252 seconds) |
| 02:19:13 | × | falafel quits (~falafel@2600:1700:3b2d:d010:9c00:d384:93c4:675d) (Ping timeout: 252 seconds) |
| 02:20:00 | × | Lord_of_Life quits (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 255 seconds) |
| 02:20:29 | → | Lord_of_Life joins (~Lord@user/lord-of-life/x-2819915) |
| 02:21:22 | hammond__ | is now known as hammond |
| 02:21:30 | × | hammond quits (proscan@gateway02.insomnia247.nl) (Changing host) |
| 02:21:30 | → | hammond joins (proscan@user/hammond2) |
| 02:23:07 | × | vglfr quits (~vglfr@145.224.100.76) (Ping timeout: 248 seconds) |
| 02:30:10 | <mon_aaraj> | A few months ago, a MR of mine was merged: https://gitlab.haskell.org/ghc/ghc/-/merge_requests/9044... (full message at <https://libera.ems.host/_matrix/media/v3/download/libera.chat/c947da40c59515b21219630ab2e5670d394443b6>) |
| 02:31:08 | → | xff0x joins (~xff0x@125x103x176x34.ap125.ftth.ucom.ne.jp) |
| 02:31:36 | → | falafel joins (~falafel@2600:1700:3b2d:d010:2bc4:e2f2:1e12:d845) |
| 02:35:03 | → | razetime joins (~Thunderbi@117.193.7.114) |
| 02:36:48 | → | kupi joins (uid212005@id-212005.hampstead.irccloud.com) |
| 02:42:16 | <mon_aaraj> | in all honesty, I believe this change should be rolled back to all versions that had support for XDG_CONFIG_HOME, because my MR changes misinformation in the GHC user's guide that has gotten me confused before (and now too, i guess now that I'm writing this here) as well as other people. |
| 02:46:02 | → | vglfr joins (~vglfr@145.224.100.119) |
| 02:49:13 | × | sammelweis quits (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.) |
| 02:49:36 | × | opticblast quits (~Thunderbi@172.58.83.235) (Quit: opticblast) |
| 02:50:20 | × | bontaq quits (~user@ool-45779fe5.dyn.optonline.net) (Ping timeout: 252 seconds) |
| 02:51:44 | × | falafel quits (~falafel@2600:1700:3b2d:d010:2bc4:e2f2:1e12:d845) (Ping timeout: 248 seconds) |
| 02:52:00 | × | FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Remote host closed the connection) |
| 02:52:53 | → | FinnElija joins (~finn_elij@user/finn-elija/x-0085643) |
| 02:59:08 | × | jpds quits (~jpds@gateway/tor-sasl/jpds) (Ping timeout: 255 seconds) |
| 02:59:50 | → | sammelweis joins (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) |
| 03:01:10 | → | jpds joins (~jpds@gateway/tor-sasl/jpds) |
| 03:01:17 | × | thegeekinside quits (~thegeekin@189.141.115.134) (Ping timeout: 246 seconds) |
| 03:01:29 | × | slack1256 quits (~slack1256@186.11.13.167) (Remote host closed the connection) |
| 03:01:43 | × | hgolden quits (~hgolden@cpe-172-251-233-141.socal.res.rr.com) (Remote host closed the connection) |
| 03:03:40 | → | hgolden joins (~hgolden@cpe-172-251-233-141.socal.res.rr.com) |
| 03:04:10 | × | jero98772 quits (~jero98772@2800:484:1d80:d8ce:efcc:cbb3:7f2a:6dff) (Remote host closed the connection) |
| 03:07:50 | → | opticblast joins (~Thunderbi@172.58.85.161) |
| 03:08:54 | × | shailangsa_ quits (~shailangs@host165-120-169-78.range165-120.btcentralplus.com) (Remote host closed the connection) |
| 03:09:03 | × | machinedgod quits (~machinedg@d198-53-218-113.abhsia.telus.net) (Ping timeout: 255 seconds) |
| 03:11:22 | × | sammelweis quits (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.) |
| 03:12:51 | → | sammelweis joins (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) |
| 03:13:34 | → | mbuf joins (~Shakthi@49.204.136.4) |
| 03:18:36 | × | [itchyjunk] quits (~itchyjunk@user/itchyjunk/x-7353470) (Remote host closed the connection) |
| 03:23:11 | × | opticblast quits (~Thunderbi@172.58.85.161) (Quit: opticblast) |
| 03:23:47 | → | opticblast joins (~Thunderbi@172.58.82.223) |
| 03:24:23 | × | waleee quits (~waleee@2001:9b0:21c:4000:5bf9:6515:c030:57b7) (Ping timeout: 246 seconds) |
| 03:24:56 | → | gastus_ joins (~gastus@5.83.191.44) |
| 03:27:57 | × | gastus quits (~gastus@185.6.123.208) (Ping timeout: 255 seconds) |
| 03:28:02 | × | sammelweis quits (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.) |
| 03:30:11 | → | sammelweis joins (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) |
| 03:33:04 | × | chexum quits (~quassel@gateway/tor-sasl/chexum) (Remote host closed the connection) |
| 03:33:28 | → | chexum joins (~quassel@gateway/tor-sasl/chexum) |
| 03:33:49 | × | sammelweis quits (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Client Quit) |
| 03:34:46 | × | FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Killed (NickServ (Forcing logout FinnElija -> finn_elija))) |
| 03:34:46 | → | finn_elija joins (~finn_elij@user/finn-elija/x-0085643) |
| 03:34:46 | finn_elija | is now known as FinnElija |
| 03:37:42 | → | sammelweis joins (~quassel@c-68-48-18-140.hsd1.mi.comcast.net) |
| 03:37:53 | × | td_ quits (~td@i53870923.versanet.de) (Ping timeout: 268 seconds) |
| 03:39:00 | → | merijn joins (~merijn@86-86-29-250.fixed.kpn.net) |
| 03:39:29 | → | td_ joins (~td@i5387090D.versanet.de) |
| 03:40:04 | × | califax quits (~califax@user/califx) (Remote host closed the connection) |
| 03:40:30 | × | bitdex quits (~bitdex@gateway/tor-sasl/bitdex) (Remote host closed the connection) |
| 03:42:08 | × | terrorjack quits (~terrorjac@2a01:4f8:1c1e:4e8c::) (Quit: The Lounge - https://thelounge.chat) |
| 03:42:26 | → | bitdex joins (~bitdex@gateway/tor-sasl/bitdex) |
| 03:43:00 | → | califax joins (~califax@user/califx) |
| 03:43:29 | → | terrorjack joins (~terrorjac@2a01:4f8:1c1e:4e8c::) |
| 03:44:03 | × | merijn quits (~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 268 seconds) |
| 03:45:35 | × | razetime quits (~Thunderbi@117.193.7.114) (Ping timeout: 248 seconds) |
| 03:46:51 | × | vglfr quits (~vglfr@145.224.100.119) (Ping timeout: 255 seconds) |
| 03:50:20 | × | opticblast quits (~Thunderbi@172.58.82.223) (Ping timeout: 255 seconds) |
| 03:50:51 | → | opticblast joins (~Thunderbi@172.58.83.235) |
| 03:51:09 | → | dsrt^ joins (~dsrt@c-24-30-76-89.hsd1.ga.comcast.net) |
| 03:54:19 | → | shailangsa joins (~shailangs@host165-120-169-78.range165-120.btcentralplus.com) |
| 04:01:17 | × | sammelweis quits (~quassel@c-68-48-18-140.hsd1.mi.comcast.net) (Quit: No Ping reply in 180 seconds.) |
| 04:10:00 | → | Monster196883 joins (~hp@103.15.228.66) |
| 04:14:16 | → | sammelweis joins (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) |
| 04:15:10 | → | vglfr joins (~vglfr@145.224.100.119) |
| 04:17:00 | × | jpds quits (~jpds@gateway/tor-sasl/jpds) (Remote host closed the connection) |
| 04:17:37 | → | jpds joins (~jpds@gateway/tor-sasl/jpds) |
| 04:22:47 | × | 077AAMFUK quits (~mncheck@193.224.205.254) (Ping timeout: 260 seconds) |
| 04:26:02 | × | vglfr quits (~vglfr@145.224.100.119) (Ping timeout: 252 seconds) |
| 04:36:47 | × | sammelweis quits (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Ping timeout: 248 seconds) |
| 04:37:15 | × | Monster196883 quits (~hp@103.15.228.66) (Ping timeout: 255 seconds) |
| 04:40:09 | → | sammelweis joins (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) |
| 04:40:49 | → | trev joins (~trev@user/trev) |
| 04:40:51 | → | king_gs joins (~Thunderbi@187.201.41.239) |
| 04:41:52 | → | razetime joins (~Thunderbi@117.193.7.114) |
| 04:44:35 | × | use-value quits (~Thunderbi@2a00:23c6:8a03:2f01:75c2:a71f:beaa:29bf) (Remote host closed the connection) |
| 04:44:53 | → | use-value joins (~Thunderbi@2a00:23c6:8a03:2f01:75c2:a71f:beaa:29bf) |
| 04:49:17 | × | king_gs quits (~Thunderbi@187.201.41.239) (Quit: king_gs) |
| 04:49:28 | → | king_gs1 joins (~Thunderbi@187.201.41.239) |
| 04:49:42 | → | falafel joins (~falafel@2600:1700:3b2d:d010:40ff:d0e6:93aa:a1e7) |
| 04:51:46 | king_gs1 | is now known as king_gs |
| 04:55:41 | × | biberu quits (~biberu@user/biberu) (Read error: Connection reset by peer) |
| 04:56:36 | × | opticblast quits (~Thunderbi@172.58.83.235) (Ping timeout: 255 seconds) |
| 05:00:14 | → | biberu joins (~biberu@user/biberu) |
| 05:01:36 | × | ryanbooker quits (uid4340@id-4340.hampstead.irccloud.com) (Quit: Connection closed for inactivity) |
| 05:04:13 | × | wroathe quits (~wroathe@user/wroathe) (Ping timeout: 268 seconds) |
| 05:06:21 | × | polyphem_ quits (~rod@2a02:810d:840:8754:224e:f6ff:fe5e:bc17) (Ping timeout: 256 seconds) |
| 05:08:56 | → | harveypwca joins (~harveypwc@2601:246:c180:a570:3828:d8:e523:3f67) |
| 05:12:26 | → | vglfr joins (~vglfr@145.224.100.119) |
| 05:13:04 | × | codaraxis quits (~codaraxis@user/codaraxis) (Ping timeout: 248 seconds) |
| 05:16:48 | × | vglfr quits (~vglfr@145.224.100.119) (Read error: Connection reset by peer) |
| 05:18:02 | → | vglfr joins (~vglfr@145.224.100.119) |
| 05:25:48 | × | razetime quits (~Thunderbi@117.193.7.114) (Ping timeout: 268 seconds) |
| 05:28:35 | × | king_gs quits (~Thunderbi@187.201.41.239) (Read error: Connection reset by peer) |
| 05:28:38 | → | king_gs1 joins (~Thunderbi@2806:103e:29:1779:19a5:ca6b:2f79:45e7) |
| 05:29:51 | → | Guest76 joins (~Guest76@129.93.161.218) |
| 05:30:28 | <Guest76> | yo |
| 05:30:42 | × | vglfr quits (~vglfr@145.224.100.119) (Read error: Connection reset by peer) |
| 05:30:43 | × | bitdex quits (~bitdex@gateway/tor-sasl/bitdex) (Quit: = "") |
| 05:30:52 | × | Guest76 quits (~Guest76@129.93.161.218) (Client Quit) |
| 05:30:56 | king_gs1 | is now known as king_gs |
| 05:31:30 | → | vglfr joins (~vglfr@145.224.100.119) |
| 05:34:34 | → | opticblast joins (~Thunderbi@172.58.82.223) |
| 05:34:44 | × | mtjm quits (~mutantmel@2604:a880:2:d0::208b:d001) (Remote host closed the connection) |
| 05:35:59 | → | mtjm joins (~mutantmel@2604:a880:2:d0::208b:d001) |
| 05:36:01 | <Axman6> | oy |
| 05:38:00 | × | fryguybob quits (~fryguybob@cpe-24-94-51-210.stny.res.rr.com) (Ping timeout: 255 seconds) |
| 05:39:57 | → | fryguybob joins (~fryguybob@cpe-24-94-51-210.stny.res.rr.com) |
| 05:40:23 | × | Square3 quits (~Square4@user/square) (Ping timeout: 264 seconds) |
| 05:41:18 | → | razetime joins (~Thunderbi@117.193.7.114) |
| 05:42:01 | × | sammelweis quits (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.) |
| 05:48:17 | → | sammelweis joins (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) |
| 05:49:23 | × | king_gs quits (~Thunderbi@2806:103e:29:1779:19a5:ca6b:2f79:45e7) (Ping timeout: 264 seconds) |
| 05:54:12 | × | sammelweis quits (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.) |
| 06:01:50 | × | azimut quits (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 255 seconds) |
| 06:03:38 | × | califax quits (~califax@user/califx) (Ping timeout: 255 seconds) |
| 06:03:56 | → | sammelweis joins (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) |
| 06:05:22 | → | califax joins (~califax@user/califx) |
| 06:09:23 | → | mncheck joins (~mncheck@193.224.205.254) |
| 06:11:08 | × | bilegeek_ quits (~bilegeek@183.sub-174-208-230.myvzw.com) (Quit: Leaving) |
| 06:14:12 | → | takuan joins (~takuan@178-116-218-225.access.telenet.be) |
| 06:23:55 | → | king_gs joins (~Thunderbi@187.201.41.239) |
| 06:25:35 | × | Inst quits (~Inst@2601:6c4:4081:54f0:7069:999c:7e48:ff3b) (Read error: Connection reset by peer) |
| 06:27:51 | × | falafel quits (~falafel@2600:1700:3b2d:d010:40ff:d0e6:93aa:a1e7) (Ping timeout: 260 seconds) |
| 06:30:11 | × | opticblast quits (~Thunderbi@172.58.82.223) (Ping timeout: 260 seconds) |
| 06:31:57 | × | king_gs quits (~Thunderbi@187.201.41.239) (Quit: king_gs) |
| 06:32:19 | × | sammelweis quits (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.) |
| 06:34:22 | → | sammelweis joins (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) |
| 06:34:36 | × | caryhartline quits (~caryhartl@2600:1700:2d0:8d30:cdb3:8615:a2b3:ec7c) (Quit: caryhartline) |
| 06:37:38 | → | bgs joins (~bgs@212-85-160-171.dynamic.telemach.net) |
| 06:39:56 | → | mrcsno joins (~mrcsno@user/mrcsno) |
| 06:51:08 | × | phma quits (phma@2001:5b0:211f:30c8:d195:4c3:ddc4:3351) (Read error: Connection reset by peer) |
| 07:00:21 | → | tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 07:03:15 | → | codaraxis joins (~codaraxis@user/codaraxis) |
| 07:05:34 | → | phma joins (~phma@host-67-44-208-142.hnremote.net) |
| 07:05:36 | × | lieven quits (~mal@ns2.wyrd.be) (Quit: WeeChat 3.0) |
| 07:06:57 | → | YoungFrog joins (~youngfrog@2a02:a03f:ca07:f900:a8be:2d7b:23bb:d884) |
| 07:10:33 | → | mal1 joins (~mal@ns2.wyrd.be) |
| 07:10:50 | mal1 | is now known as lieven |
| 07:12:09 | × | harveypwca quits (~harveypwc@2601:246:c180:a570:3828:d8:e523:3f67) (Quit: Leaving) |
| 07:17:51 | × | vglfr quits (~vglfr@145.224.100.119) (Ping timeout: 248 seconds) |
| 07:18:06 | → | vglfr joins (~vglfr@145.224.100.119) |
| 07:21:07 | <dminuoso_> | jackdk: I think the FRP problems are beyond the "where do I place code" domain. FRP demands a fundamental different approach, uses lots of highly complicated combinators with strange type signatures. In a way one could say `reflex is to traditional haskell code as Haskell is to C`. |
| 07:22:47 | <dminuoso_> | Part of the success of React+Redux can be attributed to being really simple to learn, simple to explain and simple to use. Yes its discrete, yes its full with very explicit callbacks, its not perfectly composable, but with a bit of discipline these problems can be worked around. |
| 07:23:37 | <dminuoso_> | At the very least the reflex-frp documentation has improved much over the years. Before, most combinators didnt even have a haddock string, but I think for someone who isnt already well versed in reflex-frp, its mostly too short to really understand whats going on. |
| 07:24:14 | <dminuoso_> | workflow :: forall t m a. (Reflex t, Adjustable t m, MonadFix m, MonadHold t m) => Workflow t m a -> m (Dynamic t a) |
| 07:24:18 | <dminuoso_> | `Runs a Workflow and returns the Dynamic result of the Workflow (i.e., a Dynamic of the value produced by the current Workflow node, and whose update Event fires whenever one Workflow is replaced by another).` |
| 07:25:03 | × | tzh quits (~tzh@c-24-21-73-154.hsd1.wa.comcast.net) (Quit: zzz) |
| 07:25:16 | <dminuoso_> | Most of the documentation is documentation on a semantic level, which by itself is probably really cool and more useful for experts - but its also mostly useless for someone trying to absord how to solve simple problems with reflex. |
| 07:32:16 | → | gurkenglas joins (~gurkengla@dynamic-089-204-138-097.89.204.138.pool.telefonica.de) |
| 07:39:25 | → | kenran joins (~user@user/kenran) |
| 07:39:33 | → | merijn joins (~merijn@86-86-29-250.fixed.kpn.net) |
| 07:44:33 | × | merijn quits (~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 268 seconds) |
| 07:45:19 | → | merijn joins (~merijn@86-86-29-250.fixed.kpn.net) |
| 07:50:06 | × | merijn quits (~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 268 seconds) |
| 07:52:01 | → | lortabac joins (~lortabac@2a01:e0a:541:b8f0:ad66:d77d:1913:4102) |
| 07:53:33 | → | coot joins (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) |
| 08:00:52 | → | michalz joins (~michalz@185.246.207.217) |
| 08:01:41 | × | tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 08:05:23 | × | razetime quits (~Thunderbi@117.193.7.114) (Ping timeout: 260 seconds) |
| 08:06:33 | × | eggplantade quits (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) (Remote host closed the connection) |
| 08:08:11 | × | Sgeo quits (~Sgeo@user/sgeo) (Read error: Connection reset by peer) |
| 08:09:06 | → | tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 08:11:58 | → | acidjnk_new joins (~acidjnk@p200300d6e715c424d939d96a9ad2afa1.dip0.t-ipconnect.de) |
| 08:21:56 | → | Midjak joins (~Midjak@82.66.147.146) |
| 08:26:01 | × | kenran quits (~user@user/kenran) (Remote host closed the connection) |
| 08:26:46 | ← | hagbard parts (~hagbard@user/hagbard) (Leaving) |
| 08:28:35 | <chreekat> | ribosomerocker: I think what's going on is that the documentation on downloads.haskell.org is not yet automatically updated |
| 08:31:30 | → | razetime joins (~Thunderbi@117.193.7.114) |
| 08:34:22 | → | fserucas joins (~fserucas@2001:818:e376:a400:fb92:70c1:dd88:c7d7) |
| 08:36:31 | × | xkuru quits (~xkuru@user/xkuru) (Read error: Connection reset by peer) |
| 08:36:51 | × | ft quits (~ft@p3e9bc443.dip0.t-ipconnect.de) (Quit: leaving) |
| 08:36:58 | × | hpc quits (~juzz@ip98-169-35-163.dc.dc.cox.net) (Ping timeout: 246 seconds) |
| 08:38:57 | → | hpc joins (~juzz@ip98-169-35-163.dc.dc.cox.net) |
| 08:44:13 | → | chexum_ joins (~quassel@gateway/tor-sasl/chexum) |
| 08:47:53 | × | chexum quits (~quassel@gateway/tor-sasl/chexum) (Ping timeout: 255 seconds) |
| 08:48:12 | × | califax quits (~califax@user/califx) (Remote host closed the connection) |
| 08:49:00 | → | machinedgod joins (~machinedg@d198-53-218-113.abhsia.telus.net) |
| 08:49:14 | → | merijn joins (~merijn@195.114.232.94) |
| 08:49:35 | × | machinedgod quits (~machinedg@d198-53-218-113.abhsia.telus.net) (Remote host closed the connection) |
| 08:50:16 | → | califax joins (~califax@user/califx) |
| 08:52:02 | → | MajorBiscuit joins (~MajorBisc@c-001-019-034.client.tudelft.eduvpn.nl) |
| 08:54:43 | → | vpan joins (~0@212.117.1.172) |
| 08:55:39 | × | acidjnk_new quits (~acidjnk@p200300d6e715c424d939d96a9ad2afa1.dip0.t-ipconnect.de) (Ping timeout: 248 seconds) |
| 08:56:42 | × | shriekingnoise quits (~shrieking@186.137.175.87) (Ping timeout: 268 seconds) |
| 08:56:57 | → | machinedgod joins (~machinedg@d198-53-218-113.abhsia.telus.net) |
| 08:56:58 | → | mc47 joins (~mc47@xmonad/TheMC47) |
| 09:02:44 | × | gmg quits (~user@user/gehmehgeh) (Ping timeout: 255 seconds) |
| 09:05:11 | → | gmg joins (~user@user/gehmehgeh) |
| 09:07:02 | → | eggplantade joins (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) |
| 09:11:14 | × | eggplantade quits (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) (Ping timeout: 246 seconds) |
| 09:15:14 | → | cfricke joins (~cfricke@user/cfricke) |
| 09:19:05 | → | zeenk joins (~zeenk@2a02:2f04:a20d:f900::7fe) |
| 09:19:47 | × | Midjak quits (~Midjak@82.66.147.146) (Read error: Connection reset by peer) |
| 09:20:18 | → | Midjak joins (~Midjak@82.66.147.146) |
| 09:22:30 | → | razetime1 joins (~Thunderbi@117.254.35.192) |
| 09:23:20 | × | razetime quits (~Thunderbi@117.193.7.114) (Ping timeout: 255 seconds) |
| 09:23:21 | razetime1 | is now known as razetime |
| 09:32:00 | × | mrcsno quits (~mrcsno@user/mrcsno) (Quit: WeeChat 3.5) |
| 09:33:46 | → | ubert1 joins (~Thunderbi@2a02:8109:abc0:6434:f64b:825d:d5ca:2a04) |
| 09:34:01 | → | mrcsno joins (~mrcsno@user/mrcsno) |
| 09:41:01 | → | dhil joins (~dhil@78.45.150.83.ewm.ftth.as8758.net) |
| 09:41:52 | → | razetime1 joins (~Thunderbi@117.193.3.202) |
| 09:42:57 | × | razetime quits (~Thunderbi@117.254.35.192) (Ping timeout: 268 seconds) |
| 09:42:58 | razetime1 | is now known as razetime |
| 09:44:43 | × | ubert1 quits (~Thunderbi@2a02:8109:abc0:6434:f64b:825d:d5ca:2a04) (Remote host closed the connection) |
| 09:50:03 | → | M3kh3t joins (~Sh4it4n@2-239-18-159.ip247.fastwebnet.it) |
| 09:50:13 | ← | M3kh3t parts (~Sh4it4n@2-239-18-159.ip247.fastwebnet.it) () |
| 09:53:24 | → | enoq joins (~enoq@2a05:1141:1f5:5600:b9c9:721a:599:bfe7) |
| 09:53:47 | × | raym quits (~ray@user/raym) (Ping timeout: 248 seconds) |
| 09:55:13 | → | raym joins (~ray@user/raym) |
| 09:58:24 | × | coot quits (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) (Quit: coot) |
| 09:58:54 | → | coot joins (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) |
| 10:01:44 | → | teo joins (~teo@user/teo) |
| 10:02:09 | × | econo quits (uid147250@user/econo) (Quit: Connection closed for inactivity) |
| 10:02:53 | × | enoq quits (~enoq@2a05:1141:1f5:5600:b9c9:721a:599:bfe7) (Quit: enoq) |
| 10:04:47 | → | enoq joins (~enoq@2a05:1141:1f5:5600:b9c9:721a:599:bfe7) |
| 10:08:51 | × | xff0x quits (~xff0x@125x103x176x34.ap125.ftth.ucom.ne.jp) (Ping timeout: 268 seconds) |
| 10:14:00 | <jackdk> | dminuoso_: I have heard from several veterans that Haskell -> Reflex is a similar jump as Imperative Programming -> Haskell. I agree, but the state of docs and teaching aids are much better now (though I wish I could find somewhere to host the QFPL reflex workshop vm - I have it building with Nix but that's long and slow). |
| 10:14:01 | <jackdk> | But I do find myself feeling like I did when I first learned Haskell: I could write small programs, but had no idea how to decompose larger problems. |
| 10:15:44 | → | kuribas joins (~user@ip-188-118-57-242.reverse.destiny.be) |
| 10:18:55 | → | acidjnk_new joins (~acidjnk@p200300d6e715c424d939d96a9ad2afa1.dip0.t-ipconnect.de) |
| 10:26:28 | <Jade[m]1> | mhm |
| 10:26:46 | <Jade[m]1> | I want to try this, it seems interesting |
| 10:35:30 | × | razetime quits (~Thunderbi@117.193.3.202) (Remote host closed the connection) |
| 10:37:28 | × | gmg quits (~user@user/gehmehgeh) (Quit: Leaving) |
| 10:40:44 | → | Monster196883 joins (~hp@103.15.228.66) |
| 10:48:00 | → | raehik joins (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) |
| 10:49:49 | → | __monty__ joins (~toonn@user/toonn) |
| 10:57:02 | × | jpds quits (~jpds@gateway/tor-sasl/jpds) (Ping timeout: 255 seconds) |
| 10:57:25 | × | phma quits (~phma@host-67-44-208-142.hnremote.net) (Read error: Connection reset by peer) |
| 10:59:25 | → | jpds joins (~jpds@gateway/tor-sasl/jpds) |
| 11:00:05 | → | phma joins (~phma@2001:5b0:211f:2648:c269:c58d:a76b:f75) |
| 11:05:35 | × | Monster196883 quits (~hp@103.15.228.66) (Ping timeout: 248 seconds) |
| 11:09:53 | → | akegalj joins (~akegalj@93-137-16-116.adsl.net.t-com.hr) |
| 11:10:52 | → | xff0x joins (~xff0x@2405:6580:b080:900:c2b9:dbcf:a435:ee43) |
| 11:24:06 | → | azimut joins (~azimut@gateway/tor-sasl/azimut) |
| 11:25:17 | <L29Ah> | i'm trying to link my executable statically via cabal-install, but it fails to link some necessary libs apparently: https://0x0.st/Hz1M.txt |
| 11:25:20 | <L29Ah> | what am i doing wrong? |
| 11:25:30 | × | michalz quits (~michalz@185.246.207.217) (Ping timeout: 252 seconds) |
| 11:26:48 | → | michalz joins (~michalz@185.246.204.107) |
| 11:27:46 | <mauke> | that looks like it's trying to link C++ stuff as C |
| 11:28:37 | <geekosaur> | also it's repeatedly telling you that you pretty much can't link glibc statically |
| 11:30:51 | × | Alex_test quits (~al_test@94.233.240.140) (Ping timeout: 248 seconds) |
| 11:31:00 | × | AlexZenon quits (~alzenon@94.233.240.140) (Ping timeout: 252 seconds) |
| 11:32:08 | × | jpds quits (~jpds@gateway/tor-sasl/jpds) (Ping timeout: 255 seconds) |
| 11:32:22 | × | manwithluck quits (~manwithlu@hoeven.dossingday.ml) (Quit: ZNC - https://znc.in) |
| 11:32:36 | → | manwithluck joins (manwithluc@hoeven.dossingday.ml) |
| 11:32:55 | <L29Ah> | geekosaur: i don't care about libc for now |
| 11:34:07 | → | jpds joins (~jpds@gateway/tor-sasl/jpds) |
| 11:34:57 | <L29Ah> | although it would be nice if i could pass musl to ghc/cabal without having to rebuild ghc in musl chroot |
| 11:35:28 | <L29Ah> | or ask it to link libc dynamically and the other stuff statically |
| 11:36:11 | <geekosaur> | the linker makes that difficult 😕 |
| 11:36:30 | → | AlexZenon joins (~alzenon@94.233.240.140) |
| 11:36:36 | → | Alex_test joins (~al_test@94.233.240.140) |
| 11:40:31 | × | xff0x quits (~xff0x@2405:6580:b080:900:c2b9:dbcf:a435:ee43) (Ping timeout: 260 seconds) |
| 11:40:55 | → | xff0x joins (~xff0x@ai081074.d.east.v6connect.net) |
| 11:41:34 | × | vglfr quits (~vglfr@145.224.100.119) (Remote host closed the connection) |
| 11:42:46 | → | vglfr joins (~vglfr@145.224.100.119) |
| 11:46:22 | → | freeside joins (~mengwong@103.252.202.85) |
| 11:48:42 | → | CiaoSen joins (~Jura@p200300c9570e91002a3a4dfffe84dbd5.dip0.t-ipconnect.de) |
| 11:48:52 | × | use-value quits (~Thunderbi@2a00:23c6:8a03:2f01:75c2:a71f:beaa:29bf) (Remote host closed the connection) |
| 11:49:11 | → | use-value joins (~Thunderbi@2a00:23c6:8a03:2f01:75c2:a71f:beaa:29bf) |
| 11:50:56 | <freeside> | greetings. I'm trying to solve a problem which might be better tackled in Python ... but I'd like to try Haskell first. I *think* the algorithm I'm looking for is LSH, locality-sensitive hashing. The problem is that I'm trying to detect subsequence inversions, of the form 123aaa456bbb789 vs 123BBB456AAA789; I want to detect that the aaa/AAA and bbb/BBB sequences were flipped, even if the content of |
| 11:51:02 | <freeside> | those sequences is not 100% identical. |
| 11:51:29 | × | califax quits (~califax@user/califx) (Ping timeout: 255 seconds) |
| 11:51:31 | → | ub joins (~Thunderbi@p548c9fde.dip0.t-ipconnect.de) |
| 11:52:11 | <dminuoso_> | LSH is not a particular algorithm, its a technique. |
| 11:52:19 | <dminuoso_> | Do you have an algorithm you want to implement? |
| 11:52:56 | <freeside> | This is similar to a diff situation where you reorder a bunch of functions during a refactoring, and make minor changes along the way. It looks like diff doesn't do anything particularly intelligent, but for my app I want to be able to visualize changes, and in this case I need to draw a sort of X that shows the chunks have flipped. |
| 11:52:59 | <dminuoso_> | (Though what you described, doesnt sound like LSH really) |
| 11:53:15 | <dminuoso_> | Or you might be able to do it with the help of LSH perhaps |
| 11:53:19 | <freeside> | I haven't gotten to the point of implementation, I'm first trying to make sure I'm adopting the correct approach |
| 11:53:37 | → | califax joins (~califax@user/califx) |
| 11:54:07 | × | ubert quits (~Thunderbi@p548c9fde.dip0.t-ipconnect.de) (Ping timeout: 248 seconds) |
| 11:54:08 | ub | is now known as ubert |
| 11:54:13 | → | Monster196883 joins (~hp@103.15.228.66) |
| 11:54:23 | <dminuoso_> | I guess your first problem is that you need some fuzzy stemming |
| 11:55:15 | <freeside> | mmm |
| 11:55:49 | <dminuoso_> | With `diff` thats already sorted out, since it operates on lines separated by newline characters. |
| 11:56:36 | <dminuoso_> | freeside: asked differently:" |
| 11:56:51 | <dminuoso_> | Is it an alphanumerical string, where the alpha characters might have their case flipped? |
| 11:58:07 | <dminuoso_> | freeside: and do you need it to be exact, or is an estimate okay? |
| 11:58:32 | <freeside> | if i may share the unvarnished problem statement ... |
| 11:58:33 | <dminuoso_> | Also, what if you have something like `123aaa` vs `1234AAA`, is that a possibility |
| 11:58:38 | <freeside> | new zealand: https://www.enterprisesg.gov.sg/-/media/esg/files/non-financial-assistance/for-companies/free-trade-agreements/ANZSCEP/ANZSCEP_Chap_2.pdf |
| 11:58:39 | <dminuoso_> | Sure |
| 11:58:49 | <freeside> | australia: https://www.dfat.gov.au/sites/default/files/safta-chapter-2-171201.pdf |
| 11:59:17 | <freeside> | here we have two very similar documents, but one of them has decided to use (a) (b) (c) for paragraph lists, and the other has dispensed with it. |
| 11:59:38 | <freeside> | there are other minor difference on that order, like, one document might say e-mail, and another might say email |
| 11:59:46 | <dminuoso_> | For maximum fun, we have a PDF to start with. |
| 12:00:06 | <dminuoso_> | So that introduces a bazillion ways this can be tricky to analyze |
| 12:00:13 | <freeside> | i have a working pdf -> docx -> md workflow going, if we don't talk about it it won't stop working |
| 12:00:19 | <dminuoso_> | (But we can pretend that we render this, and OCR it back) |
| 12:00:32 | <dminuoso_> | Okay |
| 12:01:02 | <freeside> | the subsequence permutation problem here is that one document might have Article 3: Customs Duties, Article 4: Customs Value, while the other document might have Article 7: Customs Value, Article 8: Customs Duties |
| 12:01:42 | <dminuoso_> | freeside: so for some problems like `e-mail` vs `email` you might want to apply a stemmer to each word. |
| 12:01:54 | <dminuoso_> | (such that you can compare for stemmed equality) |
| 12:02:10 | <dminuoso_> | Given that this appear to be English, good stemmers can be found |
| 12:02:20 | <freeside> | i was hoping those differences would disappear with some kind of approximate hashing, if i look at sequences at article-level granularity rather than word-level |
| 12:02:32 | <dminuoso_> | (.e. use lspell) |
| 12:02:35 | × | gurkenglas quits (~gurkengla@dynamic-089-204-138-097.89.204.138.pool.telefonica.de) (Ping timeout: 260 seconds) |
| 12:02:56 | <dminuoso_> | yeah I think you wdant to do a word-wise stemmer normalization with lspell |
| 12:03:05 | <dminuoso_> | that will take care of slightly altered spelling of words |
| 12:03:10 | → | chele joins (~chele@user/chele) |
| 12:03:18 | → | mmhat joins (~mmh@p200300f1c70462d7ee086bfffe095315.dip0.t-ipconnect.de) |
| 12:03:30 | <freeside> | okay, i will look into that |
| 12:03:50 | <dminuoso_> | Sorry *Ipsell my bad |
| 12:04:07 | <freeside> | but what if i just chop up the documents into lists of articles, and then i run some approximate hashing at the article level, and then foreach article in one document, i seek closest match in the other |
| 12:04:40 | <dminuoso_> | freeside: there's far more options with regards to normaliszation, but I think Ispell is a good first step. |
| 12:04:48 | <dminuoso_> | freeside: you will have to do normalization first. |
| 12:05:00 | × | mmhat quits (~mmh@p200300f1c70462d7ee086bfffe095315.dip0.t-ipconnect.de) (Client Quit) |
| 12:05:15 | <dminuoso_> | the paragraph notation, I dont know of freely available software that can do this |
| 12:05:23 | <dminuoso_> | most open source software doesnt operate on that level |
| 12:05:41 | <freeside> | ok, i could normalize that away. |
| 12:05:54 | <dminuoso_> | good |
| 12:06:20 | <dminuoso_> | freeside: by the way, this problem is deeply related to full text search algorithms. |
| 12:06:41 | <dminuoso_> | which all rely on stemming/normalizing words from input |
| 12:06:53 | <freeside> | mmhm, i feel like i am about 30 years behind google here lol, and this is just for a quick one-of |
| 12:06:55 | × | Monster196883 quits (~hp@103.15.228.66) (Ping timeout: 248 seconds) |
| 12:07:09 | <freeside> | i'm reading this paper on AHBM: https://www.sciencedirect.com/science/article/pii/S1742287614000085#:~:text=Approximate%20Hash%20Based%20Matching%20(AHBM,from%20memory%20or%20deleted%20files. |
| 12:07:35 | <dminuoso_> | freeside: if youw ant to reuse technology |
| 12:07:42 | <freeside> | yes, please |
| 12:07:43 | <dminuoso_> | you could perhaps get quite far by using postgresql |
| 12:07:58 | <freeside> | oh, pgsql has all the algorithms inside now, does it |
| 12:08:06 | <dminuoso_> | turn things into tsvector, having no stop words |
| 12:08:15 | <dminuoso_> | then you just have to deal with comparing tsvectors |
| 12:08:24 | <dminuoso_> | (that's something you have to fill) |
| 12:08:54 | <dminuoso_> | even if stop words are used, its probably still fine |
| 12:08:59 | <dminuoso_> | (assuming you can live with that) |
| 12:09:10 | <dminuoso_> | freeside: the almost bigger problem is that tsvector doesnt keep original information around directly |
| 12:09:15 | <dminuoso_> | so it could be difficult |
| 12:09:32 | <dminuoso_> | (i.e. in a tsvector elements dont have their unnormalized form available) |
| 12:10:20 | <freeside> | that's fine, i will bust out the Schwartzian Transform |
| 12:10:43 | <dminuoso_> | But honestly, I think postgresql is a bit overkill |
| 12:11:15 | <dminuoso_> | https://snowballstem.org/ |
| 12:11:21 | <dminuoso_> | This might be an even better option than ispell |
| 12:12:16 | × | kuribas quits (~user@ip-188-118-57-242.reverse.destiny.be) (Remote host closed the connection) |
| 12:12:56 | <freeside> | the normalization will be insufficient in some cases, where a sentence in one doc might be "there shall be no tariffs on Koala fur made in Australia" while the other doc might be "there shall be no tariffs on Sheep fur made in New Zealand" |
| 12:13:09 | <freeside> | I was hoping the approximate hashing would handle that |
| 12:13:15 | <dminuoso_> | hold on, different problems ere, |
| 12:13:22 | <dminuoso_> | Im not saying normalization solves all your problems |
| 12:13:27 | <dminuoso_> | just that its a necessary step |
| 12:13:35 | <freeside> | ok |
| 12:14:25 | <dminuoso_> | you could just do split by word boundary, apply normalization (schwartzian style), and then do a diff algorithm on that |
| 12:14:45 | × | acidjnk_new quits (~acidjnk@p200300d6e715c424d939d96a9ad2afa1.dip0.t-ipconnect.de) (Ping timeout: 256 seconds) |
| 12:14:52 | <dminuoso_> | say myers |
| 12:15:57 | <dminuoso_> | such that the myers diff will consider the normalized strings, but print out non-normalized chunks |
| 12:16:29 | <freeside> | the schwartzian transform is really just an Arrow, isn't it |
| 12:16:41 | <dminuoso_> | Sure, if you want that interface. |
| 12:17:08 | <dminuoso_> | freeside: https://hackage.haskell.org/package/snowball |
| 12:17:13 | <dminuoso_> | Here, bindings even exist |
| 12:17:42 | <dminuoso_> | https://hackage.haskell.org/package/Diff |
| 12:17:48 | <dminuoso_> | I think with these two you can get quite far. |
| 12:18:13 | <dminuoso_> | And something like paragraph notation you can treat like stop words that you just elide |
| 12:19:06 | → | gurkenglas joins (~gurkengla@dynamic-089-204-138-097.89.204.138.pool.telefonica.de) |
| 12:23:49 | <dminuoso_> | freeside: let eqing f x y = f x == f y in getGroupedDiffBy (eqing snd) (id &&& stem English) |
| 12:24:19 | <dminuoso_> | Maybe with some `. T.words` at the end, done! |
| 12:24:51 | <dminuoso_> | oh hold on |
| 12:25:06 | <freeside> | mmm |
| 12:25:13 | <dminuoso_> | let eqing f x y = f x == f y in getGroupedDiffBy (eqing snd) . (id && stem English) . T.words |
| 12:25:17 | <dminuoso_> | Something like that |
| 12:26:37 | <dminuoso_> | Ah not quite given the signature of getGroupedDiffBy, needs some uncurry, but I think you get the idea. |
| 12:28:13 | × | tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 12:31:01 | <freeside> | thank you, i shall try this |
| 12:31:11 | <freeside> | i am going to pretend it is an AoC problem and just power through it |
| 12:33:00 | <freeside> | you know, my first language was Perl, and I am now going to demonstrate that one can write Perl in any language |
| 12:33:33 | <dminuoso_> | One of the few languages that were actually designed. :) |
| 12:42:27 | × | anpad quits (~pandeyan@user/anpad) (Quit: ZNC 1.8.2 - https://znc.in) |
| 12:44:53 | → | anpad joins (~pandeyan@user/anpad) |
| 12:55:39 | × | werneta quits (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 248 seconds) |
| 12:56:18 | → | cheater_ joins (~Username@user/cheater) |
| 12:58:51 | <hpc> | heh, yeah perl's the best |
| 12:59:25 | <hpc> | one of my only-half-jokes is that haskell's my favorite imperative language and perl's my favorite functional language |
| 12:59:27 | × | cheater quits (~Username@user/cheater) (Ping timeout: 255 seconds) |
| 12:59:33 | cheater_ | is now known as cheater |
| 13:02:25 | <gurkenglas> | aww, Copilot just wanted to use data in a where expression and it has a point |
| 13:03:18 | → | jtomas joins (~jtomas@81.172.17.107.dyn.user.ono.com) |
| 13:06:36 | → | acidjnk_new joins (~acidjnk@p200300d6e715c424d939d96a9ad2afa1.dip0.t-ipconnect.de) |
| 13:07:33 | → | lyle joins (~lyle@104.246.145.237) |
| 13:08:50 | <freeside> | is that something ocaml would allow? |
| 13:10:38 | → | eggplantade joins (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) |
| 13:11:22 | × | jtomas quits (~jtomas@81.172.17.107.dyn.user.ono.com) (Remote host closed the connection) |
| 13:15:03 | → | Guest35 joins (~Guest35@2a02:1210:7e50:ca00:6e96:c5da:4cf3:d7d5) |
| 13:15:30 | × | eggplantade quits (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) (Ping timeout: 260 seconds) |
| 13:16:18 | × | Guest35 quits (~Guest35@2a02:1210:7e50:ca00:6e96:c5da:4cf3:d7d5) (Client Quit) |
| 13:21:54 | → | Guest55 joins (~Guest55@150.254.83.188) |
| 13:22:39 | × | mechap quits (~mechap@user/mechap) (Ping timeout: 248 seconds) |
| 13:23:51 | <Guest55> | hi, would you recommend me some course on haskell and functional programming in general? i was lead here from the haskell mooc fi website |
| 13:24:28 | → | mechap joins (~mechap@user/mechap) |
| 13:26:33 | × | enoq quits (~enoq@2a05:1141:1f5:5600:b9c9:721a:599:bfe7) (Quit: enoq) |
| 13:26:35 | × | mrcsno quits (~mrcsno@user/mrcsno) (Ping timeout: 264 seconds) |
| 13:27:41 | <opqdonut> | was there something wrong with the haskell.mooc.fi course? |
| 13:27:59 | <opqdonut> | or are you looking for something more advanced? |
| 13:31:56 | <Guest55> | i just found it browsing through mooc courses where i landed from completely different reason, it wasnt really recommended to me so decided its worth a shot to ask someone experienced abt haskell courses&tutorials landscape |
| 13:33:09 | <Guest55> | are you familiar with that one or any particular other one? |
| 13:34:13 | × | stiell quits (~stiell@gateway/tor-sasl/stiell) (Remote host closed the connection) |
| 13:34:30 | <opqdonut> | I wrote haskell.mooc.fi, and I think it's a great course O:) |
| 13:34:45 | <opqdonut> | unlike many other courses (like Learn You A Haskell), it has lots of exercises |
| 13:34:56 | → | stiell joins (~stiell@gateway/tor-sasl/stiell) |
| 13:35:18 | <opqdonut> | student feedback has been really positive |
| 13:36:08 | <opqdonut> | over 700 students have finished part 1 by submitting their solutions to the course server |
| 13:36:28 | <opqdonut> | but the course can be worked on independently as well, so there might be many more students who just don't bother with the formalities |
| 13:38:33 | × | whatsupdoc quits (uid509081@id-509081.hampstead.irccloud.com) (Quit: Connection closed for inactivity) |
| 13:39:22 | <Guest55> | oh i see! I'm glad to have occasion to thank you for creating the course, I just started it, but i am looking forward to use further advance later, and also leave feedback as i i finish it. thank you for the response and cheers |
| 13:39:26 | × | Guest55 quits (~Guest55@150.254.83.188) (Quit: Client closed) |
| 13:40:33 | → | Lycurgus joins (~juan@user/Lycurgus) |
| 13:40:58 | × | dfg quits (~dfg@user/dfg) (Quit: I hate quit messages.) |
| 13:41:16 | → | dfg joins (~dfg@dfg.rocks) |
| 13:41:16 | × | dfg quits (~dfg@dfg.rocks) (Changing host) |
| 13:41:16 | → | dfg joins (~dfg@user/dfg) |
| 13:44:58 | → | tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 13:50:42 | × | infinity0 quits (~infinity0@pwned.gg) (Ping timeout: 252 seconds) |
| 13:53:00 | → | abhim joins (~abhim@238-197.wifi.nat.warwick.ac.uk) |
| 13:53:07 | × | lortabac quits (~lortabac@2a01:e0a:541:b8f0:ad66:d77d:1913:4102) (Quit: WeeChat 2.8) |
| 13:55:35 | <abhim> | Getting an error trying to install GHCup on WSL 2 |
| 13:55:36 | <abhim> | [GHCup-00841] Process "sh" with arguments ["./configure", |
| 13:55:36 | <abhim> | [ ... ] "--prefix=/home/abhim/.ghcup/ghc/9.2.5"] failed with exit code 1. |
| 13:55:37 | <abhim> | Any clue what it's about? |
| 13:55:37 | <abhim> | I also get: "ghcup --metadata-fetching-mode=Strict --cache install ghc recommended" failed! |
| 14:00:59 | × | gurkenglas quits (~gurkengla@dynamic-089-204-138-097.89.204.138.pool.telefonica.de) (Ping timeout: 255 seconds) |
| 14:03:21 | → | infinity0 joins (~infinity0@pwned.gg) |
| 14:04:32 | × | cfricke quits (~cfricke@user/cfricke) (Ping timeout: 246 seconds) |
| 14:06:53 | → | cfricke joins (~cfricke@user/cfricke) |
| 14:08:43 | <ph88> | how can i concat 4x Word8 into Word32 ? |
| 14:08:59 | <dminuoso_> | ph88: Data.Bits |
| 14:09:06 | <ph88> | thanks dminuoso_ :) |
| 14:09:21 | <dminuoso_> | ph88: Use shiftL and (.&.) |
| 14:09:41 | <dminuoso_> | Oh and fromIntegral obviously. |
| 14:09:58 | → | thegeekinside joins (~thegeekin@189.141.115.134) |
| 14:10:18 | <dminuoso_> | Or .|. I guess heh |
| 14:10:42 | <dminuoso_> | https://gist.github.com/dminuoso/8c4eb6a1d996f4e226f9ecce23c35895 |
| 14:14:17 | <mauke> | fromIntegral, * 256, + |
| 14:16:11 | × | abhim quits (~abhim@238-197.wifi.nat.warwick.ac.uk) (Quit: Connection closed) |
| 14:16:38 | × | Lycurgus quits (~juan@user/Lycurgus) (Quit: Exeunt: personae.ai-integration.biz) |
| 14:16:40 | <hololeap> | is darcs dead? |
| 14:16:55 | → | shriekingnoise joins (~shrieking@186.137.175.87) |
| 14:19:24 | <hololeap> | it just looks like no effort has been taken to let it build on ghc-9.2 |
| 14:20:54 | × | akegalj quits (~akegalj@93-137-16-116.adsl.net.t-com.hr) (Quit: leaving) |
| 14:20:55 | <dminuoso_> | mauke: Okay lets debate about that. Is multiplication and addition better suited than shift and OR? |
| 14:21:31 | <mauke> | depends |
| 14:21:41 | <dminuoso_> | A bit benefit of shift+or is that the relationship to the value is visually better tied to the type (shifting 8/26/24 bits for Word8 into Word32) |
| 14:21:57 | <dminuoso_> | With 256 its not as obvious whether its correct when looking at Word8 and Word32 |
| 14:22:05 | → | abhim joins (~abhim@238-197.wifi.nat.warwick.ac.uk) |
| 14:22:12 | <mauke> | why not? |
| 14:22:51 | <ph88> | cool gist dminuoso_ i will take it :) |
| 14:23:22 | <dminuoso_> | mauke: Because Word8 and Word32 have the number of bits in the type name itself already. |
| 14:23:32 | <mauke> | I mention the alternative because some people are more comfortable with "normal" arithmetic (+, -, *, /) |
| 14:23:43 | <dminuoso_> | With 256 you go from number of bits into a decimal representation of maximum value first |
| 14:23:49 | <mauke> | and it is occasionally useful to remember that that is what's actually happening |
| 14:24:04 | <dminuoso_> | Mmm |
| 14:24:19 | → | kuribas joins (~user@ip-188-118-57-242.reverse.destiny.be) |
| 14:24:30 | <dminuoso_> | Though if the problem is already formulated as "concatenating Word8 into Word32" that already suggests thinking about shift and or. |
| 14:24:43 | <dminuoso_> | The connection to multiplication is almost incidental, here. |
| 14:24:55 | <mauke> | all shifts are multiplications |
| 14:25:07 | × | abhim quits (~abhim@238-197.wifi.nat.warwick.ac.uk) (Client Quit) |
| 14:25:26 | <dminuoso_> | Thinking about multiplication by 256 is actually based on a base-256 level of thinking. |
| 14:25:26 | <mauke> | (doesn't have to be decimal, either: 256 could be written as 0xFF or whatever) |
| 14:25:37 | <dminuoso_> | (which seems very unintuitive) |
| 14:25:53 | <mauke> | eh? but that's what bytes are |
| 14:26:06 | <mauke> | machine words are effectively in base 256 |
| 14:27:04 | <dminuoso_> | Fair I guess. Its just that when I think of a Word8, I dont see a value range 0-255, I rather see just "8 bits of information" |
| 14:27:19 | <dminuoso_> | Which is equivalent of course, but the former isnt exactly what Id be thinking about |
| 14:28:25 | <mauke> | > foldl (\z x -> z * 256 + x) 0 [a, b, c, d] |
| 14:28:27 | <lambdabot> | (((0 * 256 + a) * 256 + b) * 256 + c) * 256 + d |
| 14:28:56 | <mauke> | > foldl (\z x -> z `shiftL` 8 .|. x) 0 [a, b, c, d] |
| 14:28:57 | <lambdabot> | error: |
| 14:28:57 | <lambdabot> | • No instance for (Bits Expr) arising from a use of ‘.|.’ |
| 14:28:57 | <lambdabot> | • In the expression: z `shiftL` 8 .|. x |
| 14:29:00 | <mauke> | aww |
| 14:29:37 | <dminuoso_> | % :t \a b c d -> foldl (\z x -> z `shiftL` 8 .|. x) 0 [a, b, c, d] |
| 14:29:37 | <yahb2> | <interactive>:1:30: error: ; Variable not in scope: shiftL :: t2 -> t0 -> t1 ; ; <interactive>:1:41: error: ; Variable not in scope: (.|.) :: t1 -> t -> t2 |
| 14:29:42 | <dminuoso_> | % import Data.Bits |
| 14:29:42 | <yahb2> | <no output> |
| 14:29:43 | <dminuoso_> | % :t \a b c d -> foldl (\z x -> z `shiftL` 8 .|. x) 0 [a, b, c, d] |
| 14:29:43 | <yahb2> | \a b c d -> foldl (\z x -> z `shiftL` 8 .|. x) 0 [a, b, c, d] ; :: (Bits b, Num b) => b -> b -> b -> b -> b |
| 14:30:18 | <mauke> | anyway, doing it as a fold reduces the number of magic numbers in the code :-) |
| 14:30:22 | <mauke> | whether it be 256 or 8 |
| 14:30:38 | <dminuoso_> | Yeah indeed |
| 14:30:42 | × | califax quits (~califax@user/califx) (Quit: ZNC 1.8.2 - https://znc.in) |
| 14:30:49 | <dminuoso_> | It's just a bit sad you cant do this cleanly in my gist. |
| 14:30:54 | <mauke> | (and nicely generalises to Word64) |
| 14:31:05 | <dminuoso_> | I mean yeah, you can do it for ipv4FromWord8s at least |
| 14:31:36 | <dminuoso_> | But this is trivial to write, tests are in place to ensure this is done correctly, and I get better guarantees about inlining. |
| 14:31:53 | <dminuoso_> | (not quite sure whether ghc can even unroll loops like that) |
| 14:31:59 | → | califax joins (~califax@user/califx) |
| 14:32:09 | <mauke> | yeah, this is more something I'd do in C |
| 14:34:32 | → | Monster196883 joins (~hp@103.15.228.66) |
| 14:37:20 | × | dhil quits (~dhil@78.45.150.83.ewm.ftth.as8758.net) (Ping timeout: 248 seconds) |
| 14:41:11 | <fbytez> | Could someone point me in the right direction for calling out to external linux processes, please. |
| 14:41:58 | <geekosaur> | look at the System.Process module |
| 14:42:08 | <Hecate> | fbytez: https://flora.pm/packages/@hackage/typed-process |
| 14:42:22 | <fbytez> | Thankyou. |
| 14:45:34 | × | Monster196883 quits (~hp@103.15.228.66) (Ping timeout: 252 seconds) |
| 14:47:45 | <dminuoso_> | Hecate: Mmm, know what we need? A full dependency diagram (cabal-plan dot-png or some such) for each package. |
| 14:48:30 | <dminuoso_> | Refreshed every day with whatever plan cabal can generate using the hackage state at that point |
| 14:48:39 | <dminuoso_> | What do you think about that? |
| 14:48:47 | <dminuoso_> | People might stop using aeson :> |
| 14:49:30 | <dminuoso_> | Though to fair, having more dependencies than it has versions has so far not stopped anyone but me yet |
| 14:51:45 | <mauke> | why would you release multiple versions? just get it perfect the first time :5head: |
| 14:54:32 | <Hecate> | dminuoso_: https://github.com/flora-pm/flora-server/discussions/new?category=feature-requests |
| 14:56:34 | → | Monster196883 joins (~hp@103.15.228.66) |
| 15:03:52 | <dminuoso_> | Ah perfect |
| 15:07:37 | <ph88> | How to go from Word32 to bytestring ? |
| 15:08:46 | <mauke> | depends on which bytestring |
| 15:08:50 | <lyxia> | ph88: https://hackage.haskell.org/package/bytestring-0.11.4.0/docs/Data-ByteString-Builder.html#v:word32BE |
| 15:09:05 | <ph88> | thanks lyxia :) |
| 15:19:16 | <fbytez> | In the examples for System.Process.Typed, what is "{-# LANGUAGE OverloadedStrings #-}" for? |
| 15:19:42 | <dminuoso_> | fbytez: https://ghc.gitlab.haskell.org/ghc/doc/users_guide/exts/overloaded_strings.html#extension-OverloadedStrings |
| 15:19:55 | <fbytez> | Right. |
| 15:20:40 | <dminuoso_> | runProcess :: MonadIO m => ProcessConfig stdin stdout stderr -> m ExitCode |
| 15:20:53 | <dminuoso_> | instance (stdin ~ (), stdout ~ (), stderr ~ ()) => IsString (ProcessConfig stdin stdout stderr) where ... |
| 15:21:31 | <ph88> | is there a version of Either that instead of returning the first error collect all the errors until the end of the monad ? |
| 15:21:32 | <geekosaur> | so in this case it lets you use a literal string as a Text or ByteString instead of a String, without requiring you to manually pack it |
| 15:21:43 | <mauke> | fbytez: https://www.stackage.org/haddock/nightly-2023-02-27/typed-process-0.2.11.0/System-Process-Typed.html#t:ProcessConfig |
| 15:22:00 | <mauke> | ph88: Writer? |
| 15:23:11 | <fbytez> | Thankyou. |
| 15:25:03 | <dminuoso_> | geekosaur: Not as a Text or ByteString, but a ProcessConfig in particualr. |
| 15:25:18 | <dminuoso_> | fromString s | any (== ' ') s = shell s | otherwise = proc s [] |
| 15:25:31 | <dminuoso_> | That's a highly dubious instance, in my opinion. |
| 15:25:45 | <dminuoso_> | That `any (== ' ')` branch uh. |
| 15:26:19 | <dminuoso_> | Something like `/exe/with space.sh` will not make you happy. |
| 15:26:28 | → | Sgeo joins (~Sgeo@user/sgeo) |
| 15:27:36 | → | polyphem_ joins (~rod@2a02:810d:840:8754:dafc:581f:2a59:730) |
| 15:28:01 | <mauke> | yeah, clearly should be `elem` |
| 15:28:07 | <fbytez> | It wouldn't be a problem if you still provide a `[]` argument too though, right? |
| 15:28:10 | × | cfricke quits (~cfricke@user/cfricke) (Quit: WeeChat 3.8) |
| 15:29:13 | <dminuoso_> | mauke: hah, that's not what I was getting at. :P |
| 15:29:20 | × | img quits (~img@user/img) (Quit: ZNC 1.8.2 - https://znc.in) |
| 15:29:22 | <mauke> | what's more interesting is that `ls|less` would not invoke the shell |
| 15:29:35 | <dminuoso_> | indeed, its an incredibly brittle and poor heuristic |
| 15:29:45 | <dminuoso_> | this should do either shell or proc (probably better just shell) |
| 15:29:53 | <dminuoso_> | not both |
| 15:29:58 | <mauke> | should've used perl instead :-D |
| 15:31:00 | <mauke> | (perl's system() scans the supplied string for shell meta-characters; if there are none, it splits on spaces and calls execv directly) |
| 15:31:24 | <dminuoso_> | mauke: and will it detect shell builtins? |
| 15:31:39 | <dminuoso_> | that is would it try and execve "pwd"? |
| 15:31:44 | <mauke> | no, that's the weak point |
| 15:31:46 | <fbytez> | I'm brand new to haskell and trying to decide how practical it is to use. The appealing part is strongly-typed functional static binaries. |
| 15:31:55 | <mauke> | pwd exists |
| 15:32:08 | <dminuoso_> | No, its a shell built-in |
| 15:32:13 | <dminuoso_> | at least on most distributoins |
| 15:32:14 | <mauke> | the issue is with stuff like cd or set |
| 15:32:26 | <mauke> | pwd is /usr/bin/pwd |
| 15:32:33 | <Unhammer> | how do I add to the "load path" of runhaskell? |
| 15:32:34 | <dminuoso_> | On your linux distribution perhaps |
| 15:32:36 | <geekosaur> | posix, for stupid reasons, required at one point that executables exist for all the shell builtins. not that e.g. `cd` is useful |
| 15:32:39 | → | img joins (~img@user/img) |
| 15:32:44 | <mauke> | (and also a shell builtin, but that doesn't hurt) |
| 15:33:03 | <dminuoso_> | geekosaur: do you happen to know the stupid reasons? |
| 15:33:05 | <Unhammer> | like, I can runhaskell app/Main.hs if I put Lib.hs in . but if it's in src, runhaskell claims Lib doesn't export myFunc |
| 15:33:14 | <dminuoso_> | fbytez: Okay, welcome then. |
| 15:33:18 | <geekosaur> | not off the top of my head any more |
| 15:33:24 | × | mc47 quits (~mc47@xmonad/TheMC47) (Remote host closed the connection) |
| 15:33:28 | → | enoq joins (~enoq@2a05:1141:1f5:5600:b9c9:721a:599:bfe7) |
| 15:33:31 | <Unhammer> | (which is confusing, when it seems like the real error is it just can't find Lib.hs) |
| 15:34:24 | <geekosaur> | I think `runhaskell -isrc` |
| 15:34:41 | <dminuoso_> | fbytez: How has your experience been, so far? |
| 15:35:10 | <mauke> | Unhammer: sounds like you have a different Lib elsewhere |
| 15:35:21 | <geekosaur> | and the reason you get "doesn't export" is https://downloads.haskell.org/ghc/9.2.5/docs/html/libraries/libiserv-9.2.5/Lib.html |
| 15:35:40 | <geekosaur> | probably |
| 15:36:03 | <geekosaur> | (I don't think I want to know whose bad idea that was) |
| 15:36:40 | <Unhammer> | ouch :( |
| 15:37:10 | <Unhammer> | had no idea Lib was a global module like that |
| 15:37:17 | <geekosaur> | well, it wouldn't bite with normal builds, but runhaskell uses ghci heuristics |
| 15:37:43 | <geekosaur> | so it is likely to search and find the global libiserv package |
| 15:38:02 | <Unhammer> | ok, makes sense |
| 15:38:30 | <Unhammer> | well, -isrc fixed my issue, thanks mauke & geekosaur |
| 15:40:41 | <fbytez> | dminuoso_, too little to say really. 'Awkward', perhaps. |
| 15:51:59 | <ph88> | how do i go from bytestring to Word32 ? |
| 15:52:58 | × | phma quits (~phma@2001:5b0:211f:2648:c269:c58d:a76b:f75) (Read error: Connection reset by peer) |
| 15:53:52 | → | phma joins (phma@2001:5b0:210d:7c18:f8fd:6f0e:6c01:c11a) |
| 15:53:56 | × | szkl quits (uid110435@id-110435.uxbridge.irccloud.com) (Quit: Connection closed for inactivity) |
| 15:54:29 | <dminuoso_> | ph88: That's a matter of parsing. |
| 15:54:37 | <dminuoso_> | What that means you must first define yourself |
| 15:55:01 | <dminuoso_> | What representation does the Word32 have in the bytestring? |
| 15:55:02 | × | tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 15:55:16 | <ph88> | it's a bytestring of 4 bytes |
| 15:55:42 | <dminuoso_> | Okay, little endian? big endian? |
| 15:55:42 | <ph88> | what do you mean representation ? it's just 32 bits to 32 bits on the value level |
| 15:55:46 | <ph88> | big endian |
| 15:56:23 | <dminuoso_> | ph88: A ByteString is just an arbitrary sequence of octets. To turn an arbitrary sequence of octets into a Word32 is a matter of parsing a representation of 32 in some particular bytes |
| 15:57:29 | <ph88> | any primitive function available to avoid having to use a parser library ? |
| 15:58:09 | <dminuoso_> | Well you can just use Data.ByteString directly |
| 15:58:22 | → | Pickchea joins (~private@user/pickchea) |
| 15:58:29 | <dminuoso_> | % import qualified Data.ByteString as BS |
| 15:58:29 | <yahb2> | <no output> |
| 15:58:32 | <dminuoso_> | % set -XOverloadedStrings |
| 15:58:32 | <yahb2> | <interactive>:22:1: error: ; • Variable not in scope: set ; • Perhaps you meant ‘seq’ (imported from Prelude) ; ; <interactive>:22:6: error: ; Data constructor not in scope: XOverloade... |
| 15:58:38 | <dminuoso_> | % :set -XOverloadedStrings |
| 15:58:38 | <yahb2> | <no output> |
| 15:59:25 | <dminuoso_> | % import Data.Bits |
| 15:59:25 | <yahb2> | <no output> |
| 16:00:36 | × | mbuf quits (~Shakthi@49.204.136.4) (Quit: Leaving) |
| 16:01:13 | <dminuoso_> | % import Data.Word (Word32) |
| 16:01:13 | <yahb2> | <no output> |
| 16:01:36 | <dminuoso_> | % parse :: BS.ByteString -> Maybe Word32; parse buf = case BS.unpack (BS.take 4 buf) of [a,b,c,d] -> Just (fromIntegral a `shiftL` 24 .|. fromIntegral b `shiftL` 16 .|. fromIntegral c `shiftL` 8 .|. fromIntegral d); _ -> Nothing |
| 16:01:36 | <yahb2> | <no output> |
| 16:01:39 | <dminuoso_> | % parse "abcd" |
| 16:01:39 | <yahb2> | Just 1633837924 |
| 16:01:43 | <dminuoso_> | fbytez: ^- how about this? |
| 16:01:49 | → | shapr joins (~user@68.54.166.125) |
| 16:02:29 | → | dhil joins (~dhil@78.45.150.83.ewm.ftth.as8758.net) |
| 16:02:40 | <dminuoso_> | % parse "\ff\ff\ff\ff" |
| 16:02:40 | <yahb2> | Just 208014438 |
| 16:03:02 | <dminuoso_> | % parse "\xFF\xFF\xFF\xFF" |
| 16:03:02 | <yahb2> | Just 4294967295 |
| 16:03:11 | → | eggplantade joins (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) |
| 16:03:39 | × | fnurglewitz quits (uid263868@id-263868.lymington.irccloud.com) (Quit: Connection closed for inactivity) |
| 16:03:57 | → | grnman_ joins (~michaelsc@c-66-176-3-51.hsd1.fl.comcast.net) |
| 16:04:12 | <fbytez> | I think you meant 'ph88'. |
| 16:04:27 | <dminuoso_> | Oh indeed. |
| 16:04:32 | × | FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Remote host closed the connection) |
| 16:05:04 | → | FinnElija joins (~finn_elij@user/finn-elija/x-0085643) |
| 16:05:58 | <ph88> | dminuoso_, thanks for the help, i could use that. I'm just thinking whether it can be done simpler. The primitive function is available it seems, so on a higher level (Word32 instead of Word#) maybe there is an opportunity to keep it as simple https://hackage.haskell.org/package/ghc-prim-0.5.0.0/docs/GHC-Prim.html#v:indexWord32Array-35- |
| 16:06:10 | → | tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 16:07:54 | <dminuoso_> | ph88: Nothing elegant, really |
| 16:08:23 | <ph88> | alright thanks |
| 16:09:29 | <dminuoso_> | ph88: The first problem you face is that you must ensure the buffer is long enough |
| 16:10:03 | <dminuoso_> | Then you must unwrap the bytestring to get hold of the internal ByteArray#, then you must use magic primitives to prevent the GC from reclaiming it too early |
| 16:10:16 | <dminuoso_> | Libraries like `flatparse` hide exactly that from you |
| 16:10:39 | <dminuoso_> | ph88: consider that library if you want a very minimalistic parser library and you have the need to do some bytestring parsing |
| 16:10:51 | <dminuoso_> | `binary` is also an option, as its a boot library (so its already installed anyway) |
| 16:12:15 | <ph88> | i am already using binary actually for some other parts of the code |
| 16:12:20 | → | jtza8 joins (~user@165.255.86.7) |
| 16:12:35 | → | cheater_ joins (~Username@user/cheater) |
| 16:13:01 | <dminuoso_> | https://hackage.haskell.org/package/binary-0.8.9.1/docs/Data-Binary-Get.html#v:getWord32be |
| 16:13:41 | <ph88> | <3 |
| 16:14:42 | → | king_gs joins (~Thunderbi@2806:103e:29:1779:19a5:ca6b:2f79:45e7) |
| 16:14:44 | × | CiaoSen quits (~Jura@p200300c9570e91002a3a4dfffe84dbd5.dip0.t-ipconnect.de) (Ping timeout: 246 seconds) |
| 16:14:45 | × | cheater quits (~Username@user/cheater) (Ping timeout: 255 seconds) |
| 16:14:50 | cheater_ | is now known as cheater |
| 16:15:56 | × | fserucas quits (~fserucas@2001:818:e376:a400:fb92:70c1:dd88:c7d7) (Quit: Leaving) |
| 16:20:55 | <jtza8> | Given smart constructor: https://paste.tomsmeding.com/PtrleZDQ |
| 16:22:46 | <jtza8> | It feels like a bad idea to automatically flip the two arguments because it allows for silent errors to go unchallenged. |
| 16:23:19 | × | ddellacosta quits (~ddellacos@146.70.166.10) (Quit: WeeChat 3.8) |
| 16:23:40 | <jtza8> | Any opinions? |
| 16:24:30 | <geekosaur> | depends on use case |
| 16:25:43 | <geekosaur> | in particular, if I have to do the test and swap everywhere before using it, it's less error prone to centralize it |
| 16:26:20 | → | ddellacosta joins (~ddellacos@146.70.166.10) |
| 16:28:30 | <jtza8> | Thanks for the good advice. I myopically neglected to consider the use case. |
| 16:28:48 | × | eggplantade quits (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) (Remote host closed the connection) |
| 16:31:11 | → | razetime joins (~Thunderbi@117.193.3.202) |
| 16:34:05 | × | chexum_ quits (~quassel@gateway/tor-sasl/chexum) (Ping timeout: 255 seconds) |
| 16:34:20 | → | gnalzo joins (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c) |
| 16:34:35 | → | chexum joins (~quassel@gateway/tor-sasl/chexum) |
| 16:35:33 | × | chele quits (~chele@user/chele) (Remote host closed the connection) |
| 16:40:07 | × | Monster196883 quits (~hp@103.15.228.66) (Ping timeout: 260 seconds) |
| 16:40:50 | × | ec quits (~ec@gateway/tor-sasl/ec) (Ping timeout: 255 seconds) |
| 16:42:25 | → | tzh joins (~tzh@c-24-21-73-154.hsd1.or.comcast.net) |
| 16:42:54 | → | ec joins (~ec@gateway/tor-sasl/ec) |
| 16:43:15 | × | grnman_ quits (~michaelsc@c-66-176-3-51.hsd1.fl.comcast.net) (Remote host closed the connection) |
| 16:43:22 | → | Guest|26 joins (~Guest|26@92.53.24.204) |
| 16:44:17 | <Guest|26> | Hey guys, I'm trying to install haskell through the powershell command on the installation page, but I'm getting this error "The revocation function was unable to check revocation for the certificate." |
| 16:45:33 | × | coot quits (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) (Quit: coot) |
| 16:45:58 | × | merijn quits (~merijn@195.114.232.94) (Ping timeout: 252 seconds) |
| 16:47:32 | → | Monster196883 joins (~hp@103.93.250.20) |
| 16:48:10 | → | shapr[m] joins (~shaprcofr@2001:470:69fc:105::2:d107) |
| 16:48:44 | <shapr> | shapr[m]: ?? |
| 16:51:02 | <c_wraith> | you're duplicating |
| 16:52:00 | <opqdonut> | unsafeDupablePerformShapr |
| 16:55:38 | <geekosaur> | @remember opqdonut * shapr[m] (~shaprcofr@2001:470:69fc:105::2:d107) has joined / <shapr> shapr[m]: ?? / <opqdonut> unsafeDupablePerformShapr |
| 16:55:38 | <lambdabot> | I will remember. |
| 16:56:57 | × | elkcl quits (~elkcl@broadband-37-110-27-252.ip.moscow.rt.ru) (Ping timeout: 255 seconds) |
| 16:57:39 | <mauke> | Guest|26: what command, what page? |
| 17:00:07 | → | codaraxis__ joins (~codaraxis@user/codaraxis) |
| 17:03:27 | × | codaraxis quits (~codaraxis@user/codaraxis) (Ping timeout: 260 seconds) |
| 17:04:27 | → | elkcl joins (~elkcl@broadband-37-110-27-252.ip.moscow.rt.ru) |
| 17:04:42 | → | eggplantade joins (~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net) |
| 17:05:58 | × | king_gs quits (~Thunderbi@2806:103e:29:1779:19a5:ca6b:2f79:45e7) (Remote host closed the connection) |
| 17:06:16 | → | king_gs joins (~Thunderbi@2806:103e:29:1779:19a5:ca6b:2f79:45e7) |
| 17:07:01 | × | MajorBiscuit quits (~MajorBisc@c-001-019-034.client.tudelft.eduvpn.nl) (Quit: WeeChat 3.6) |
| 17:09:29 | ← | jakalx parts (~jakalx@base.jakalx.net) (Error from remote client) |
| 17:09:53 | × | gnalzo quits (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c) (Quit: WeeChat 3.8) |
| 17:10:18 | <shapr> | opqdonut: haha! :-D |
| 17:14:06 | <Guest|26> | Set-ExecutionPolicy Bypass -Scope Process -Force;[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; try { Invoke-Command -ScriptBlock ([ScriptBlock]::Create((Invoke-WebRequest https://www.haskell.org/ghcup/sh/bootstrap-haskell.ps1 -UseBasicParsing))) -ArgumentList $true } catch { |
| 17:14:06 | <Guest|26> | Write-Error $_ } this command, I meant installing GHCup |
| 17:14:23 | <ph88> | is there a reverse class lookup possible on hackage ? i give a type and it shows me all the packages which implement an instance of something for this type ? |
| 17:14:52 | <Guest|26> | It throws that error while trying to install Msys2. |
| 17:15:33 | → | jakalx joins (~jakalx@base.jakalx.net) |
| 17:15:45 | <ph88> | Guest|26, try to open an administrative shell. Go to start menu find powershell, then right click execute as administrator |
| 17:15:55 | × | Sauvin quits (~sauvin@user/Sauvin) (Ping timeout: 248 seconds) |
| 17:16:20 | <ph88> | Run Get-ExecutionPolicy. If it returns Restricted, then run Set-ExecutionPolicy AllSigned or Set-ExecutionPolicy Bypass -Scope Process. |
| 17:16:50 | ← | jtza8 parts (~user@165.255.86.7) (ERC 5.4 (IRC client for GNU Emacs 28.2)) |
| 17:17:01 | <Guest|26> | It returns Bypass |
| 17:21:58 | <ph88> | ye ok so try again with administrative shell |
| 17:24:44 | × | pavonia quits (~user@user/siracusa) (Quit: Bye!) |
| 17:24:57 | <ph88> | you can also try curl on the script link to see if you get TLS certificate errors that way |
| 17:26:55 | × | polyphem_ quits (~rod@2a02:810d:840:8754:dafc:581f:2a59:730) (Ping timeout: 248 seconds) |
| 17:27:49 | → | polyphem_ joins (~rod@2a02:810d:840:8754:224e:f6ff:fe5e:bc17) |
| 17:28:55 | <Guest|26> | Same error in admin shell, installed msys2 manually and gave the path to the installer, when It opened the Mingw window, it threw and ssl error “failed to verify the legitimacy of the server” |
| 17:29:39 | <Guest|26> | curl https://www.haskell.org/ghcup/sh/bootstrap-haskell.ps1 returns 200 |
| 17:32:49 | × | kuribas quits (~user@ip-188-118-57-242.reverse.destiny.be) (Remote host closed the connection) |
| 17:33:31 | × | teo quits (~teo@user/teo) (Ping timeout: 248 seconds) |
| 17:34:29 | × | chexum quits (~quassel@gateway/tor-sasl/chexum) (Remote host closed the connection) |
| 17:34:53 | → | chexum joins (~quassel@gateway/tor-sasl/chexum) |
| 17:35:21 | × | eggplantade quits (~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
| 17:36:18 | → | eggplantade joins (~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net) |
| 17:37:15 | × | Guest|26 quits (~Guest|26@92.53.24.204) (Quit: Connection closed) |
| 17:38:53 | → | harveypwca joins (~harveypwc@2601:246:c180:a570:3828:d8:e523:3f67) |
| 17:39:00 | × | enoq quits (~enoq@2a05:1141:1f5:5600:b9c9:721a:599:bfe7) (Quit: enoq) |
| 17:42:14 | × | razetime quits (~Thunderbi@117.193.3.202) (Remote host closed the connection) |
| 17:47:23 | × | notzmv quits (~zmv@user/notzmv) (Ping timeout: 248 seconds) |
| 17:48:20 | × | azimut quits (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 255 seconds) |
| 17:52:02 | → | azimut joins (~azimut@gateway/tor-sasl/azimut) |
| 17:57:33 | → | wootehfoot joins (~wootehfoo@user/wootehfoot) |
| 17:57:53 | → | opticblast joins (~Thunderbi@172.58.83.235) |
| 17:59:01 | × | ec quits (~ec@gateway/tor-sasl/ec) (Remote host closed the connection) |
| 17:59:30 | → | ec joins (~ec@gateway/tor-sasl/ec) |
| 18:01:43 | × | eggplantade quits (~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
| 18:02:25 | × | dsrt^ quits (~dsrt@c-24-30-76-89.hsd1.ga.comcast.net) (Remote host closed the connection) |
| 18:05:48 | → | eggplantade joins (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) |
| 18:09:47 | → | werneta joins (~werneta@137.79.193.28) |
| 18:10:58 | <ph88> | can i make two versions of a function where one version has some additional typeclasses i can use ? |
| 18:11:21 | <Jade[m]1> | what do you mean by that? |
| 18:11:30 | <Jade[m]1> | An overloaded function? |
| 18:11:44 | <ph88> | ye |
| 18:11:57 | <Jade[m]1> | no, that's not possible in haskell |
| 18:11:57 | → | Tuplanolla joins (~Tuplanoll@91-159-68-152.elisa-laajakaista.fi) |
| 18:12:17 | <Jade[m]1> | because of currying it'd make the concept difficult |
| 18:12:24 | <monochrom> | Do you mind giving them two different names? |
| 18:12:25 | <Jade[m]1> | so it's not a feature whatsoever |
| 18:12:28 | → | econo joins (uid147250@user/econo) |
| 18:12:42 | <ph88> | monochrom, yes |
| 18:12:42 | <Jade[m]1> | consider using a 'prime' (`f'` |
| 18:12:46 | <Jade[m]1> | * 'prime' (`f'`) |
| 18:12:52 | <geekosaur> | well. it is possible to have a default implementation of a typeclass function which has different requirements; some typeclasses use this to specify a default using Generics |
| 18:13:12 | <ph88> | what if i make a typeclass just for running my function and then put the additional typeclasses on there ? |
| 18:13:15 | <Jade[m]1> | * 'prime' (`f`,`f'`, * '`) |
| 18:13:37 | <geekosaur> | https://downloads.haskell.org/ghc/9.6.1-alpha3/docs/users_guide/exts/default_signatures.html |
| 18:13:53 | → | Joao003 joins (~Joao003@2804:840:8301:cb00:8d33:1756:d85a:7970) |
| 18:13:59 | ph88 | reading |
| 18:14:04 | <monochrom> | Yeah default signatures is the closest I can think of, but it still doesn't look like your question. |
| 18:18:30 | × | wootehfoot quits (~wootehfoo@user/wootehfoot) (Ping timeout: 255 seconds) |
| 18:21:50 | → | ratapaca joins (~ratapaca@98.40.240.33) |
| 18:24:11 | × | king_gs quits (~Thunderbi@2806:103e:29:1779:19a5:ca6b:2f79:45e7) (Ping timeout: 264 seconds) |
| 18:24:18 | × | Joao003 quits (~Joao003@2804:840:8301:cb00:8d33:1756:d85a:7970) (Quit: Leaving) |
| 18:25:47 | × | ratapaca quits (~ratapaca@98.40.240.33) (Client Quit) |
| 18:27:41 | → | king_gs joins (~Thunderbi@187.201.41.239) |
| 18:28:40 | → | Sauvin joins (~sauvin@user/Sauvin) |
| 18:30:38 | × | tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 18:32:28 | × | eggplantade quits (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) (Remote host closed the connection) |
| 18:32:47 | × | hugo- quits (znc@verdigris.lysator.liu.se) (Ping timeout: 255 seconds) |
| 18:38:23 | × | polyphem_ quits (~rod@2a02:810d:840:8754:224e:f6ff:fe5e:bc17) (Ping timeout: 256 seconds) |
| 18:39:40 | × | vpan quits (~0@212.117.1.172) (Quit: Leaving.) |
| 18:40:27 | → | wootehfoot joins (~wootehfoo@user/wootehfoot) |
| 18:43:03 | → | merijn joins (~merijn@86-86-29-250.fixed.kpn.net) |
| 18:43:51 | → | hugo- joins (znc@verdigris.lysator.liu.se) |
| 18:45:21 | × | raehik quits (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Quit: Leaving) |
| 18:47:28 | × | merijn quits (~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 268 seconds) |
| 18:50:24 | → | polyphem_ joins (~rod@2a02:810d:840:8754:13ad:6ee2:a5fa:1da3) |
| 18:50:54 | × | dhil quits (~dhil@78.45.150.83.ewm.ftth.as8758.net) (Ping timeout: 255 seconds) |
| 18:52:21 | × | dcoutts_ quits (~duncan@cpc69403-oxfd27-2-0-cust285.4-3.cable.virginm.net) (Remote host closed the connection) |
| 18:52:44 | → | dcoutts_ joins (~duncan@cpc69403-oxfd27-2-0-cust285.4-3.cable.virginm.net) |
| 18:54:13 | × | harveypwca quits (~harveypwc@2601:246:c180:a570:3828:d8:e523:3f67) (Quit: Leaving) |
| 18:55:23 | × | FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Ping timeout: 255 seconds) |
| 18:57:39 | → | FinnElija joins (~finn_elij@user/finn-elija/x-0085643) |
| 18:57:44 | × | iteratee_ quits (~kyle@2001:470:4071:0:5054:e5ff:fe3b:2859) (Remote host closed the connection) |
| 18:59:12 | × | king_gs quits (~Thunderbi@187.201.41.239) (Ping timeout: 248 seconds) |
| 19:03:26 | → | dhil joins (~dhil@80.208.56.181.static.fibianet.dk) |
| 19:04:29 | → | waleee joins (~waleee@2001:9b0:21c:4000:5bf9:6515:c030:57b7) |
| 19:08:36 | × | jmdaemon quits (~jmdaemon@user/jmdaemon) (Ping timeout: 252 seconds) |
| 19:09:17 | → | tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 19:16:01 | → | mrcsno joins (~mrcsno@user/mrcsno) |
| 19:16:21 | → | eggplantade joins (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) |
| 19:16:43 | → | Guest58 joins (~textual@2603-7000-1203-4d7c-0cdc-f6ea-1da9-3494.res6.spectrum.com) |
| 19:23:15 | × | foul_owl quits (~kerry@193.29.61.203) (Ping timeout: 268 seconds) |
| 19:24:09 | → | ft joins (~ft@p3e9bc443.dip0.t-ipconnect.de) |
| 19:27:08 | → | foul_owl joins (~kerry@71.212.143.88) |
| 19:30:01 | × | dcoutts_ quits (~duncan@cpc69403-oxfd27-2-0-cust285.4-3.cable.virginm.net) (Ping timeout: 268 seconds) |
| 19:32:39 | × | micro quits (~micro@user/micro) (Ping timeout: 255 seconds) |
| 19:32:47 | × | Guest58 quits (~textual@2603-7000-1203-4d7c-0cdc-f6ea-1da9-3494.res6.spectrum.com) (Quit: My Mac has gone to sleep. ZZZzzz…) |
| 19:32:55 | → | micro joins (~micro@user/micro) |
| 19:33:59 | → | azimut_ joins (~azimut@gateway/tor-sasl/azimut) |
| 19:34:05 | × | azimut quits (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 255 seconds) |
| 19:34:08 | → | Guest58 joins (~textual@cpe-66-65-40-132.nyc.res.rr.com) |
| 19:39:50 | × | johnw_ quits (~johnw@2600:1700:cf00:db0:a85a:aa58:c54c:551d) (Quit: ZNC - http://znc.in) |
| 19:39:50 | × | jwiegley quits (~jwiegley@76-234-69-149.lightspeed.frokca.sbcglobal.net) (Quit: ZNC - http://znc.in) |
| 19:40:54 | → | jwiegley joins (~jwiegley@2600:1700:cf00:db0:240d:4ecd:e535:2c8f) |
| 19:41:18 | × | Monster196883 quits (~hp@103.93.250.20) (Ping timeout: 255 seconds) |
| 19:41:40 | → | johnw joins (~johnw@2600:1700:cf00:db0:240d:4ecd:e535:2c8f) |
| 19:41:55 | × | Guest58 quits (~textual@cpe-66-65-40-132.nyc.res.rr.com) (Quit: My Mac has gone to sleep. ZZZzzz…) |
| 19:45:11 | × | wootehfoot quits (~wootehfoo@user/wootehfoot) (Ping timeout: 264 seconds) |
| 20:05:50 | × | pwntips_ quits (~user@24-113-98-114.wavecable.com) (Quit: leaving) |
| 20:11:09 | → | Feuermagier joins (~Feuermagi@user/feuermagier) |
| 20:12:20 | → | pavonia joins (~user@user/siracusa) |
| 20:21:30 | → | wootehfoot joins (~wootehfoo@user/wootehfoot) |
| 20:22:42 | → | pwntips joins (~user@24-113-98-114.wavecable.com) |
| 20:28:10 | <monochrom> | https://dev.to/zelenya/there-is-no-tooling-issue-in-haskell-cal \∩/ |
| 20:31:30 | × | eggplantade quits (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) (Remote host closed the connection) |
| 20:32:05 | × | ddellacosta quits (~ddellacos@146.70.166.10) (Quit: WeeChat 3.8) |
| 20:33:35 | → | ddellacosta joins (~ddellacos@146.70.166.10) |
| 20:33:54 | → | nikkc joins (~nikkc@2603-7080-0101-3269-fccb-ad1f-3c7d-f525.res6.spectrum.com) |
| 20:37:21 | × | cheater quits (~Username@user/cheater) (Read error: Connection reset by peer) |
| 20:38:05 | → | cheater joins (~Username@user/cheater) |
| 20:41:58 | × | opticblast quits (~Thunderbi@172.58.83.235) (Ping timeout: 252 seconds) |
| 20:51:05 | × | polyphem_ quits (~rod@2a02:810d:840:8754:13ad:6ee2:a5fa:1da3) (Ping timeout: 260 seconds) |
| 20:51:46 | → | polyphem_ joins (~rod@2a02:810d:840:8754:224e:f6ff:fe5e:bc17) |
| 20:52:50 | → | opticblast joins (~Thunderbi@172.58.80.62) |
| 20:56:52 | <ph88> | when should one use Control.Monad.Trans.Except VS Control.Monad.Error.Class ? |
| 20:58:02 | → | gmg joins (~user@user/gehmehgeh) |
| 21:00:37 | → | fnurglewitz joins (uid263868@id-263868.lymington.irccloud.com) |
| 21:04:25 | → | Guest58 joins (~textual@2603-7000-1203-4d7c-0cdc-f6ea-1da9-3494.res6.spectrum.com) |
| 21:04:49 | × | wootehfoot quits (~wootehfoo@user/wootehfoot) (Read error: Connection reset by peer) |
| 21:05:26 | × | jpds quits (~jpds@gateway/tor-sasl/jpds) (Ping timeout: 255 seconds) |
| 21:06:15 | → | jpds joins (~jpds@gateway/tor-sasl/jpds) |
| 21:10:24 | <geekosaur> | you wouldn't normally use either, you'd use Control.Monad.Error (the higher level version of Control.Monad.Error.Class) or you would use an effect or type family-based or other implementation of Control.Monad.Trans.Except |
| 21:11:44 | <geekosaur> | the latter is the lowest level definition. Control.Monad.Error{,.Class} is from mtl. other monad implementations build on Control.Monad.Trans.Error in other ways than mtl does |
| 21:12:18 | <geekosaur> | (.Class would be used if you want to build your own monad that adheres to mtl's implementation of MonadError) |
| 21:12:58 | <geekosaur> | (if you're just stacking mtl errors, Control.Monad.Error is enough) |
| 21:13:04 | <geekosaur> | er mtl monads |
| 21:16:42 | × | thegeekinside quits (~thegeekin@189.141.115.134) (Ping timeout: 268 seconds) |
| 21:19:48 | <ddellacosta> | geekosaur: I think Control.Monad.Error in mtl is deprecated https://hackage.haskell.org/package/mtl-2.3.1/docs/Control-Monad-Error-Class.html#t:MonadError |
| 21:20:09 | <geekosaur> | yeh, I neglected to mention that all of them are deprecated |
| 21:20:28 | <geekosaur> | Control.Monad.Except is the preferred one |
| 21:20:45 | <geekosaur> | (and transformers equivalent) |
| 21:21:06 | <ddellacosta> | ah, okay. I'm still wrapping my head around errors/exception-handling in Haskell in general, I find it really challenging, and it seems like there are a lot of approaches to sift through |
| 21:22:40 | <geekosaur> | same rules apply there, though: the one from transformers is the basic definition shared by all implementations, .Class is mtl's core for use by other monads, C.M.Except is the standard mtl monad implementing the class |
| 21:23:46 | → | jmdaemon joins (~jmdaemon@user/jmdaemon) |
| 21:23:50 | <geekosaur> | you will find the mtl-tf package which implements the same mtl interfaces but using associated types instead of mtl's fundeps, and effect systems providing their own implementations of the basic transformer |
| 21:25:23 | → | lxi joins (~quassel@2a02:2f08:4d1c:400:416b:68b5:814f:ea80) |
| 21:27:05 | → | mmhat joins (~mmh@p200300f1c70462d7ee086bfffe095315.dip0.t-ipconnect.de) |
| 21:28:42 | × | lyle quits (~lyle@104.246.145.237) (Quit: WeeChat 3.8) |
| 21:32:00 | → | eggplantade joins (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) |
| 21:33:48 | × | jle` quits (~jle`@cpe-23-240-75-236.socal.res.rr.com) (Ping timeout: 255 seconds) |
| 21:35:55 | → | jle` joins (~jle`@cpe-23-240-75-236.socal.res.rr.com) |
| 21:36:32 | × | eggplantade quits (~Eggplanta@2600:1700:38c5:d800:8429:4ceb:8103:61ef) (Ping timeout: 248 seconds) |
| 21:38:42 | × | takuan quits (~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection) |
| 21:39:30 | <dminuoso_> | ddellacosta: I think we're just overequipped with different solutions. |
| 21:39:53 | <dminuoso_> | I find the best general exception mechanism is just plain IO exceptions. |
| 21:40:04 | × | trev quits (~trev@user/trev) (Remote host closed the connection) |
| 21:40:21 | <dminuoso_> | They are simple, no weird monad wizardry, no subtle gotchas with other effects |
| 21:40:42 | <dminuoso_> | And you get a builtin dynamically typed extensible exception hierarchy much like in Java |
| 21:40:45 | → | irrgit_ joins (~irrgit@176.113.74.130) |
| 21:41:15 | <dminuoso_> | Only price is that you need IO in those places, but I dont think IO is something we should be afraid of. |
| 21:41:25 | <dminuoso_> | Additional benefit, it works in MonadUnliftIO code. |
| 21:42:11 | <dminuoso_> | And they arent clearly communicatable in the type system (and sadly much IO code does not clearly document what exceptions can be thrown, and plenty of libraries that do throw exceptions dont organize them in hierarchies either). |
| 21:42:20 | <dminuoso_> | But thats for library code anyway, for code that you control its a different story |
| 21:43:11 | × | lxi quits (~quassel@2a02:2f08:4d1c:400:416b:68b5:814f:ea80) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) |
| 21:45:04 | × | dhil quits (~dhil@80.208.56.181.static.fibianet.dk) (Ping timeout: 268 seconds) |
| 21:48:38 | × | jpds quits (~jpds@gateway/tor-sasl/jpds) (Ping timeout: 255 seconds) |
| 21:50:22 | → | jpds joins (~jpds@gateway/tor-sasl/jpds) |
| 21:50:49 | × | infinity0 quits (~infinity0@pwned.gg) (Remote host closed the connection) |
| 21:52:56 | → | infinity0 joins (~infinity0@pwned.gg) |
| 21:54:34 | → | cheater_ joins (~Username@user/cheater) |
| 21:55:43 | → | Monster196883 joins (~hp@103.15.228.66) |
| 21:57:42 | × | hiredman quits (~hiredman@frontier1.downey.family) (Quit: Lost terminal) |
| 21:57:51 | × | cheater quits (~Username@user/cheater) (Ping timeout: 248 seconds) |
| 21:58:00 | cheater_ | is now known as cheater |
| 21:58:27 | <ph88> | geekosaur, from Control.Monad.Except when should i use MonadError VS Except/ExceptT ? |
| 21:58:39 | → | hiredman joins (~hiredman@frontier1.downey.family) |
| 22:00:38 | <geekosaur> | MonadError is the lower level one. are you building your own exception monad? then implement MonadError for it |
| 22:00:54 | <geekosaur> | if you aren't, you probably want Except/ExceptT |
| 22:01:54 | <ph88> | geekosaur, when to use Except/ExcepT only with existing exception monads ? |
| 22:02:07 | <geekosaur> | uh? |
| 22:02:50 | <geekosaur> | as before: if you are simply stacking monads, you want ExceptT. if you are building something like RWS that has an exception component, you want MonadError |
| 22:03:20 | <ph88> | ok thanks |
| 22:03:32 | → | masterbuilder joins (~masterbui@user/masterbuilder) |
| 22:04:25 | × | hiredman quits (~hiredman@frontier1.downey.family) (Quit: Lost terminal) |
| 22:05:17 | → | hiredman joins (~hiredman@frontier1.downey.family) |
| 22:05:18 | × | werneta quits (~werneta@137.79.193.28) (Ping timeout: 255 seconds) |
| 22:05:38 | <geekosaur[m]> | Put otherwise, MonadError is for implementors, Except for users |
| 22:07:04 | → | thegeekinside joins (~thegeekin@189.141.115.134) |
| 22:07:23 | × | m5zs7k quits (aquares@web10.mydevil.net) (Ping timeout: 264 seconds) |
| 22:07:47 | → | m5zs7k joins (aquares@web10.mydevil.net) |
| 22:10:08 | × | tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 22:10:52 | → | werneta joins (~werneta@137.79.212.16) |
| 22:17:52 | → | cheater_ joins (~Username@user/cheater) |
| 22:20:16 | × | cheater quits (~Username@user/cheater) (Ping timeout: 248 seconds) |
| 22:20:17 | cheater_ | is now known as cheater |
| 22:32:10 | × | __monty__ quits (~toonn@user/toonn) (Quit: leaving) |
| 22:32:21 | → | tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 22:37:15 | × | opticblast quits (~Thunderbi@172.58.80.62) (Ping timeout: 260 seconds) |
| 22:37:43 | → | Rafflesia271828 joins (~hp@103.15.228.66) |
| 22:39:03 | × | Monster196883 quits (~hp@103.15.228.66) (Ping timeout: 255 seconds) |
| 22:41:22 | × | michalz quits (~michalz@185.246.204.107) (Remote host closed the connection) |
| 22:43:28 | → | merijn joins (~merijn@86-86-29-250.fixed.kpn.net) |
| 22:45:13 | → | Monster196883 joins (~hp@103.15.228.66) |
| 22:46:42 | × | Rafflesia271828 quits (~hp@103.15.228.66) (Ping timeout: 255 seconds) |
| 22:47:50 | × | nikkc quits (~nikkc@2603-7080-0101-3269-fccb-ad1f-3c7d-f525.res6.spectrum.com) (Quit: Client closed) |
| 22:48:03 | × | merijn quits (~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 255 seconds) |
| 22:57:55 | → | emmanuelux joins (~emmanuelu@user/emmanuelux) |
| 23:01:19 | × | thaumavorio_ quits (~thaumavor@thaumavor.io) (Quit: ZNC 1.8.2 - https://znc.in) |
| 23:02:40 | × | Guest58 quits (~textual@2603-7000-1203-4d7c-0cdc-f6ea-1da9-3494.res6.spectrum.com) (Quit: ZZZzzz…) |
| 23:03:13 | → | thaumavorio joins (~thaumavor@thaumavor.io) |
| 23:07:26 | × | Sauvin quits (~sauvin@user/Sauvin) (Quit: Leaving) |
| 23:09:06 | → | bilegeek joins (~bilegeek@2600:1008:b011:7459:a819:7768:fb22:1ebd) |
| 23:09:08 | → | Sauvin joins (~sauvin@user/Sauvin) |
| 23:09:32 | × | gmg quits (~user@user/gehmehgeh) (Quit: Leaving) |
| 23:10:20 | × | fnurglewitz quits (uid263868@id-263868.lymington.irccloud.com) (Quit: Connection closed for inactivity) |
| 23:21:25 | × | jpds quits (~jpds@gateway/tor-sasl/jpds) (Remote host closed the connection) |
| 23:25:20 | × | werneta quits (~werneta@137.79.212.16) (Remote host closed the connection) |
| 23:26:47 | → | jpds joins (~jpds@gateway/tor-sasl/jpds) |
| 23:32:39 | × | acidjnk_new quits (~acidjnk@p200300d6e715c424d939d96a9ad2afa1.dip0.t-ipconnect.de) (Ping timeout: 260 seconds) |
| 23:34:05 | → | dekster joins (~dekster@2603-7000-1203-4d7c-0cdc-f6ea-1da9-3494.res6.spectrum.com) |
| 23:38:31 | → | bontaq joins (~user@ool-45779fe5.dyn.optonline.net) |
| 23:39:41 | × | azimut_ quits (~azimut@gateway/tor-sasl/azimut) (Remote host closed the connection) |
| 23:39:46 | × | califax quits (~califax@user/califx) (Remote host closed the connection) |
| 23:40:31 | → | azimut joins (~azimut@gateway/tor-sasl/azimut) |
| 23:40:45 | → | Square3 joins (~Square4@user/square) |
| 23:40:56 | → | califax joins (~califax@user/califx) |
| 23:47:54 | × | catern quits (~sbaugh@2604:2000:8fc0:b:a9c7:866a:bf36:3407) (Read error: Connection reset by peer) |
| 23:53:17 | × | califax quits (~califax@user/califx) (Ping timeout: 255 seconds) |
| 23:53:27 | → | califax_ joins (~califax@user/califx) |
| 23:53:44 | × | jpds quits (~jpds@gateway/tor-sasl/jpds) (Ping timeout: 255 seconds) |
| 23:54:42 | califax_ | is now known as califax |
| 23:55:06 | × | manwithluck quits (manwithluc@hoeven.dossingday.ml) (Quit: ZNC - https://znc.in) |
| 23:56:05 | × | tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 23:56:47 | → | jpds joins (~jpds@gateway/tor-sasl/jpds) |
All times are in UTC on 2023-03-02.