2022-02-04 00:00:48 +0100 | azimut | (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 276 seconds) |
2022-02-04 00:01:42 +0100 | MatthiasG2 | (~matthias@i6DFA038C.versanet.de) (Quit: Lost terminal) |
2022-02-04 00:02:23 +0100 | burnsidesLlama | (~burnsides@dhcp168-042.wadham.ox.ac.uk) (Ping timeout: 256 seconds) |
2022-02-04 00:03:31 +0100 | kojo5551 | (~kojo5551@fep.grid.pub.ro) (Ping timeout: 256 seconds) |
2022-02-04 00:03:58 +0100 | adnaahm | (~adnaahm@host-251-net-64-160-119.mobilinkinfinity.net.pk) (Remote host closed the connection) |
2022-02-04 00:04:08 +0100 | kojo5551 | (~kojo5551@fep.grid.pub.ro) |
2022-02-04 00:04:59 +0100 | wroathe | (~wroathe@user/wroathe) (Ping timeout: 256 seconds) |
2022-02-04 00:07:15 +0100 | pgib | (~textual@173.38.117.89) (Ping timeout: 256 seconds) |
2022-02-04 00:09:01 +0100 | phma | (phma@2001:5b0:211c:a988:8f1d:f7a6:3d8d:dc0c) (Quit: Konversation terminated!) |
2022-02-04 00:09:31 +0100 | tavares | (~tavares@user/tavares) (Ping timeout: 256 seconds) |
2022-02-04 00:10:04 +0100 | phma | (phma@2001:5b0:211c:a988:4657:1b6d:fa0b:fae3) |
2022-02-04 00:12:19 +0100 | alx741 | (~alx741@157.100.197.240) |
2022-02-04 00:12:37 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 240 seconds) |
2022-02-04 00:13:57 +0100 | <ski> | @undo do {Just x <- return Nothing; return x} |
2022-02-04 00:13:57 +0100 | <lambdabot> | return Nothing >>= \ a -> case a of { Just x -> return x; _ -> fail ""} |
2022-02-04 00:14:45 +0100 | burnsidesLlama | (~burnsides@dhcp168-042.wadham.ox.ac.uk) |
2022-02-04 00:15:35 +0100 | Axma76527 | Axman6 |
2022-02-04 00:15:37 +0100 | machinedgod | (~machinedg@24.105.81.50) (Ping timeout: 240 seconds) |
2022-02-04 00:22:34 +0100 | alx741 | (~alx741@157.100.197.240) (Read error: Connection reset by peer) |
2022-02-04 00:22:52 +0100 | phma | (phma@2001:5b0:211c:a988:4657:1b6d:fa0b:fae3) (Read error: Connection reset by peer) |
2022-02-04 00:23:17 +0100 | phma | (~phma@host-67-44-208-91.hnremote.net) |
2022-02-04 00:23:35 +0100 | <janus> | awpr: something i forgot is that GHC 9.2 sets PolyKinds by default since it is part of GHC2021. so that may have played a role |
2022-02-04 00:24:00 +0100 | <janus> | awpr: swamp-agr let me know https://github.com/GetShopTV/swagger2/pull/233#issuecomment-1029474729 |
2022-02-04 00:24:15 +0100 | Guest83 | (~Guest83@181.229.128.244) (Ping timeout: 256 seconds) |
2022-02-04 00:25:17 +0100 | Gurkenglas | (~Gurkengla@dslb-090-186-104-244.090.186.pools.vodafone-ip.de) (Ping timeout: 240 seconds) |
2022-02-04 00:25:34 +0100 | <monochrom> | Interesting. Maybe add {-# language NoPolyKinds #-} and see what happens. |
2022-02-04 00:28:47 +0100 | jgeerds | (~jgeerds@55d4a547.access.ecotel.net) (Ping timeout: 256 seconds) |
2022-02-04 00:28:47 +0100 | <janus> | yeah i did, and then it finds the instance. even if it is explicitly derived... |
2022-02-04 00:29:09 +0100 | nitrix | (~nitrix@user/nitrix) |
2022-02-04 00:29:44 +0100 | wyrd | (~wyrd@gateway/tor-sasl/wyrd) |
2022-02-04 00:29:58 +0100 | <janus> | i am confused since the existence of an instance shouldn't affect whether PolyKinds is enabled or not |
2022-02-04 00:30:10 +0100 | <janus> | but anyway, there is that other compiler bug that makes the impossible happen |
2022-02-04 00:30:13 +0100 | dcoutts | (~duncan@109.144.215.134) |
2022-02-04 00:30:30 +0100 | <janus> | so 9.2 is unusable for this project anyway, it seems |
2022-02-04 00:32:19 +0100 | AlexNoo_ | (~AlexNoo@94.233.241.94) |
2022-02-04 00:32:59 +0100 | Topsi | (~Tobias@dyndsl-037-138-064-017.ewe-ip-backbone.de) (Read error: Connection reset by peer) |
2022-02-04 00:33:53 +0100 | Alex_test | (~al_test@178.34.151.37) (Ping timeout: 256 seconds) |
2022-02-04 00:34:14 +0100 | chenqisu1 | (~chenqisu1@183.217.200.249) |
2022-02-04 00:34:41 +0100 | AlexZenon | (~alzenon@178.34.151.37) (Ping timeout: 256 seconds) |
2022-02-04 00:36:02 +0100 | AlexNoo | (~AlexNoo@178.34.151.37) (Ping timeout: 250 seconds) |
2022-02-04 00:36:50 +0100 | <janus> | well, for it's test suite at least... |
2022-02-04 00:37:40 +0100 | eggplantade | (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
2022-02-04 00:38:52 +0100 | Alex_test | (~al_test@94.233.241.94) |
2022-02-04 00:39:04 +0100 | AlexZenon | (~alzenon@94.233.241.94) |
2022-02-04 00:41:00 +0100 | alx741 | (~alx741@157.100.197.240) |
2022-02-04 00:42:27 +0100 | max22- | (~maxime@2a01cb08833598004d3ba66ae954fefa.ipv6.abo.wanadoo.fr) (Remote host closed the connection) |
2022-02-04 00:43:43 +0100 | alx741 | (~alx741@157.100.197.240) (Read error: Connection reset by peer) |
2022-02-04 00:43:54 +0100 | alp | (~alp@user/alp) |
2022-02-04 00:45:07 +0100 | CiaoSen | (~Jura@p200300c95737a2002a3a4dfffe84dbd5.dip0.t-ipconnect.de) (Ping timeout: 250 seconds) |
2022-02-04 00:50:57 +0100 | <Axman6> | just check in a DeferredTypeErrors if it's a test suite >_> |
2022-02-04 00:51:04 +0100 | <Axman6> | chuck* |
2022-02-04 01:01:46 +0100 | lavaman | (~lavaman@98.38.249.169) |
2022-02-04 01:01:56 +0100 | alx741 | (~alx741@157.100.197.240) |
2022-02-04 01:06:31 +0100 | lavaman | (~lavaman@98.38.249.169) (Ping timeout: 256 seconds) |
2022-02-04 01:07:03 +0100 | Akiva | (~Akiva@user/Akiva) |
2022-02-04 01:09:44 +0100 | alx741 | (~alx741@157.100.197.240) (Read error: Connection reset by peer) |
2022-02-04 01:13:11 +0100 | HotblackDesiato | (~HotblackD@gateway/tor-sasl/hotblackdesiato) (Remote host closed the connection) |
2022-02-04 01:13:17 +0100 | Erutuon | (~Erutuon@user/erutuon) (Ping timeout: 240 seconds) |
2022-02-04 01:13:31 +0100 | HotblackDesiato | (~HotblackD@gateway/tor-sasl/hotblackdesiato) |
2022-02-04 01:15:57 +0100 | raehik | (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 240 seconds) |
2022-02-04 01:16:31 +0100 | Erutuon | (~Erutuon@user/erutuon) |
2022-02-04 01:16:35 +0100 | shapr | (~user@pool-173-73-44-186.washdc.fios.verizon.net) (Remote host closed the connection) |
2022-02-04 01:16:51 +0100 | shapr | (~user@pool-173-73-44-186.washdc.fios.verizon.net) |
2022-02-04 01:17:48 +0100 | dut | (~dut@user/dut) |
2022-02-04 01:20:05 +0100 | shapr` | (~user@pool-173-73-44-186.washdc.fios.verizon.net) |
2022-02-04 01:21:43 +0100 | shapr | (~user@pool-173-73-44-186.washdc.fios.verizon.net) (Ping timeout: 256 seconds) |
2022-02-04 01:22:24 +0100 | machinedgod | (~machinedg@24.105.81.50) |
2022-02-04 01:23:35 +0100 | [itchyjunk] | (~itchyjunk@user/itchyjunk/x-7353470) |
2022-02-04 01:23:36 +0100 | oscurochu | (~oscurochu@097-096-050-227.res.spectrum.com) (Remote host closed the connection) |
2022-02-04 01:26:17 +0100 | alx741 | (~alx741@157.100.197.240) |
2022-02-04 01:29:40 +0100 | x_kuru | (~xkuru@user/xkuru) (Read error: Connection reset by peer) |
2022-02-04 01:29:57 +0100 | emf | (~emf@2620:10d:c090:400::5:e4c1) (Ping timeout: 240 seconds) |
2022-02-04 01:31:09 +0100 | alx741 | (~alx741@157.100.197.240) (Read error: Connection reset by peer) |
2022-02-04 01:31:10 +0100 | emf | (~emf@163.114.132.4) |
2022-02-04 01:35:53 +0100 | emf | (~emf@163.114.132.4) (Ping timeout: 256 seconds) |
2022-02-04 01:36:47 +0100 | tatarqa | (~kli@ip-89-177-122-45.net.upcbroadband.cz) (Read error: Connection reset by peer) |
2022-02-04 01:38:09 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:a019:43b1:3d96:a258) |
2022-02-04 01:42:14 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:a019:43b1:3d96:a258) (Remote host closed the connection) |
2022-02-04 01:42:29 +0100 | eggplantade | (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
2022-02-04 01:44:41 +0100 | Midjak | (~Midjak@may53-1-78-226-116-92.fbx.proxad.net) (Quit: This computer has gone to sleep) |
2022-02-04 01:47:26 +0100 | alx741 | (~alx741@157.100.197.240) |
2022-02-04 01:48:00 +0100 | pretty_dumm_guy | (trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655) (Quit: WeeChat 3.4) |
2022-02-04 01:51:30 +0100 | wroathe | (~wroathe@user/wroathe) |
2022-02-04 01:51:35 +0100 | mvk | (~mvk@2607:fea8:5cdc:bf00::80f1) |
2022-02-04 01:52:12 +0100 | alx741 | (~alx741@157.100.197.240) (Read error: Connection reset by peer) |
2022-02-04 01:59:15 +0100 | oscurochu | (~oscurochu@097-096-050-227.res.spectrum.com) |
2022-02-04 01:59:57 +0100 | dcoutts | (~duncan@109.144.215.134) (Ping timeout: 240 seconds) |
2022-02-04 02:00:37 +0100 | vglfr | (~vglfr@88.155.40.186) (Ping timeout: 240 seconds) |
2022-02-04 02:01:26 +0100 | <awpr> | I'm not sure I follow. I thought you said removing the redundant standalone Typeable instances fixed the problem? |
2022-02-04 02:01:32 +0100 | vglfr | (~vglfr@88.155.40.186) |
2022-02-04 02:01:57 +0100 | machinedgod | (~machinedg@24.105.81.50) (Ping timeout: 256 seconds) |
2022-02-04 02:02:10 +0100 | califax | (~califax@user/califx) (Remote host closed the connection) |
2022-02-04 02:02:52 +0100 | <awpr> | oh, is it that fixing it required both NoPolyKinds _and_ removing the instances? |
2022-02-04 02:03:10 +0100 | califax | (~califax@user/califx) |
2022-02-04 02:07:29 +0100 | miremeister | (uid387155@id-387155.uxbridge.irccloud.com) |
2022-02-04 02:08:17 +0100 | oscurochu | (~oscurochu@097-096-050-227.res.spectrum.com) (Ping timeout: 256 seconds) |
2022-02-04 02:08:36 +0100 | alx741 | (~alx741@157.100.197.240) |
2022-02-04 02:09:49 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) |
2022-02-04 02:10:46 +0100 | alx741 | (~alx741@157.100.197.240) (Read error: Connection reset by peer) |
2022-02-04 02:10:51 +0100 | shapr` | (~user@pool-173-73-44-186.washdc.fios.verizon.net) (Remote host closed the connection) |
2022-02-04 02:11:01 +0100 | alp | (~alp@user/alp) (Remote host closed the connection) |
2022-02-04 02:11:20 +0100 | alp | (~alp@user/alp) |
2022-02-04 02:14:37 +0100 | doxen | (~bbrahms@pool-173-54-217-168.nwrknj.fios.verizon.net) (Ping timeout: 240 seconds) |
2022-02-04 02:15:17 +0100 | califax- | (~califax@user/califx) |
2022-02-04 02:16:24 +0100 | vicfred | (~vicfred@user/vicfred) (Quit: Leaving) |
2022-02-04 02:16:39 +0100 | califax | (~califax@user/califx) (Ping timeout: 276 seconds) |
2022-02-04 02:16:40 +0100 | califax- | califax |
2022-02-04 02:17:37 +0100 | ec | (~ec@gateway/tor-sasl/ec) (Quit: ec) |
2022-02-04 02:28:41 +0100 | Merfont | (~Kaiepi@156.34.47.253) (Ping timeout: 245 seconds) |
2022-02-04 02:29:05 +0100 | alx741 | (~alx741@157.100.197.240) |
2022-02-04 02:30:37 +0100 | Erutuon | (~Erutuon@user/erutuon) (Ping timeout: 240 seconds) |
2022-02-04 02:33:21 +0100 | dut | (~dut@user/dut) (Read error: Connection reset by peer) |
2022-02-04 02:33:43 +0100 | Erutuon | (~Erutuon@user/erutuon) |
2022-02-04 02:33:57 +0100 | alx741 | (~alx741@157.100.197.240) (Read error: Connection reset by peer) |
2022-02-04 02:34:34 +0100 | alx741 | (~alx741@157.100.197.240) |
2022-02-04 02:36:16 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) (Quit: WeeChat 3.4) |
2022-02-04 02:36:57 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) |
2022-02-04 02:43:13 +0100 | lbseale | (~ep1ctetus@user/ep1ctetus) (Read error: Connection reset by peer) |
2022-02-04 02:43:14 +0100 | alx741 | (~alx741@157.100.197.240) (Read error: Connection reset by peer) |
2022-02-04 02:43:37 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 240 seconds) |
2022-02-04 02:51:15 +0100 | hyiltiz | (~quassel@31.220.5.250) (Ping timeout: 256 seconds) |
2022-02-04 02:52:59 +0100 | hyiltiz | (~quassel@31.220.5.250) |
2022-02-04 02:59:03 +0100 | eggplantade | (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
2022-02-04 03:02:22 +0100 | jao | (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Remote host closed the connection) |
2022-02-04 03:02:52 +0100 | kimjetwav | (~user@2607:fea8:2363:8f00:8299:55f4:a45f:d9c3) |
2022-02-04 03:03:21 +0100 | jao | (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) |
2022-02-04 03:09:37 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:a019:43b1:3d96:a258) |
2022-02-04 03:10:49 +0100 | rusrushal13 | (~rusrushal@2409:4056:9:1708:2c2:74fb:7af9:78dc) |
2022-02-04 03:11:21 +0100 | vysn | (~vysn@user/vysn) |
2022-02-04 03:13:37 +0100 | mmhat | (~mmh@55d48978.access.ecotel.net) (Ping timeout: 240 seconds) |
2022-02-04 03:14:38 +0100 | brettgilio | (~brettgili@x-node.gq) (Ping timeout: 268 seconds) |
2022-02-04 03:16:15 +0100 | lavaman | (~lavaman@98.38.249.169) |
2022-02-04 03:19:54 +0100 | califax- | (~califax@user/califx) |
2022-02-04 03:20:24 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:a019:43b1:3d96:a258) (Remote host closed the connection) |
2022-02-04 03:21:59 +0100 | eggplantade | (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
2022-02-04 03:24:15 +0100 | califax | (~califax@user/califx) (Ping timeout: 276 seconds) |
2022-02-04 03:24:16 +0100 | califax- | califax |
2022-02-04 03:27:17 +0100 | xff0x | (~xff0x@2001:1a81:53e8:2500:a7da:afdc:1a91:3063) (Ping timeout: 240 seconds) |
2022-02-04 03:29:18 +0100 | xff0x | (~xff0x@2001:1a81:5224:e000:4717:65df:57b3:7708) |
2022-02-04 03:30:56 +0100 | jinsun__ | (~quassel@user/jinsun) (Read error: Connection reset by peer) |
2022-02-04 03:32:37 +0100 | jinsun | (~quassel@user/jinsun) |
2022-02-04 03:32:45 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) (Quit: WeeChat 3.4) |
2022-02-04 03:33:25 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) |
2022-02-04 03:38:33 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) (Quit: WeeChat 3.4) |
2022-02-04 03:39:32 +0100 | ProfSimm | (~ProfSimm@87.227.196.109) (Remote host closed the connection) |
2022-02-04 03:39:53 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) |
2022-02-04 03:40:54 +0100 | rusrushal13 | (~rusrushal@2409:4056:9:1708:2c2:74fb:7af9:78dc) (Ping timeout: 256 seconds) |
2022-02-04 03:42:37 +0100 | Erutuon | (~Erutuon@user/erutuon) (Ping timeout: 240 seconds) |
2022-02-04 03:43:43 +0100 | razetime | (~quassel@49.207.209.26) |
2022-02-04 03:45:56 +0100 | Erutuon | (~Erutuon@user/erutuon) |
2022-02-04 03:47:59 +0100 | alp | (~alp@user/alp) (Ping timeout: 250 seconds) |
2022-02-04 03:49:08 +0100 | andreabedini | (~andreabed@8s8kj6nrww5p5nzkz2zz.ip6.superloop.com) |
2022-02-04 04:00:10 +0100 | asivitz | (uid178348@tinside.irccloud.com) (Quit: Connection closed for inactivity) |
2022-02-04 04:06:29 +0100 | Ssorjkokhn | (~Ssorjkokh@65.155.193.58) |
2022-02-04 04:10:23 +0100 | unyu | (~pyon@user/pyon) (Quit: brb) |
2022-02-04 04:11:49 +0100 | dsrt^ | (~dsrt@128-092-185-170.biz.spectrum.com) |
2022-02-04 04:16:48 +0100 | rusrushal13 | (~rusrushal@2401:4900:5d15:a022:862f:921f:d1a9:883d) |
2022-02-04 04:18:51 +0100 | lavaman | (~lavaman@98.38.249.169) (Ping timeout: 256 seconds) |
2022-02-04 04:23:38 +0100 | cynomys | (~cynomys@user/cynomys) |
2022-02-04 04:28:49 +0100 | waleee | (~waleee@2001:9b0:21d:fc00:398f:b003:b90d:acf4) (Ping timeout: 256 seconds) |
2022-02-04 04:31:46 +0100 | phma | (~phma@host-67-44-208-91.hnremote.net) (Read error: Connection reset by peer) |
2022-02-04 04:32:40 +0100 | Ssorjkokhn | (~Ssorjkokh@65.155.193.58) (Quit: Client closed) |
2022-02-04 04:37:34 +0100 | phma | (~phma@host-67-44-208-198.hnremote.net) |
2022-02-04 04:39:35 +0100 | cynomys | (~cynomys@user/cynomys) (Ping timeout: 256 seconds) |
2022-02-04 04:40:49 +0100 | modnar | (~modnar@shell.sonic.net) (Quit: farewell) |
2022-02-04 04:41:10 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) |
2022-02-04 04:41:14 +0100 | modnar | (~modnar@shell.sonic.net) |
2022-02-04 04:41:57 +0100 | td_ | (~td@94.134.91.183) (Ping timeout: 240 seconds) |
2022-02-04 04:43:51 +0100 | miremeister | (uid387155@id-387155.uxbridge.irccloud.com) (Quit: Connection closed for inactivity) |
2022-02-04 04:44:03 +0100 | terrorjack | (~terrorjac@2a01:4f8:1c1e:509a::1) (Quit: The Lounge - https://thelounge.chat) |
2022-02-04 04:44:10 +0100 | td_ | (~td@muedsl-82-207-238-085.citykom.de) |
2022-02-04 04:45:16 +0100 | terrorjack | (~terrorjac@2a01:4f8:1c1e:509a::1) |
2022-02-04 04:49:22 +0100 | mbuf | (~Shakthi@122.174.58.23) |
2022-02-04 04:49:27 +0100 | vglfr | (~vglfr@88.155.40.186) (Ping timeout: 256 seconds) |
2022-02-04 04:50:21 +0100 | mon_aaraj | (~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 256 seconds) |
2022-02-04 04:52:06 +0100 | mon_aaraj | (~MonAaraj@user/mon-aaraj/x-4416475) |
2022-02-04 04:55:55 +0100 | hippoid | (~hippoid@184.105.3.82) |
2022-02-04 04:56:08 +0100 | hippoid | (~hippoid@184.105.3.82) (Client Quit) |
2022-02-04 05:00:01 +0100 | haasn | (~nand@haasn.dev) (Quit: ZNC 1.7.5+deb4 - https://znc.in) |
2022-02-04 05:01:21 +0100 | haasn | (~nand@haasn.dev) |
2022-02-04 05:03:46 +0100 | oscurochu | (~oscurochu@097-096-050-227.res.spectrum.com) |
2022-02-04 05:03:57 +0100 | wroathe | (~wroathe@user/wroathe) (Ping timeout: 240 seconds) |
2022-02-04 05:06:59 +0100 | wroathe | (~wroathe@206-55-188-8.fttp.usinternet.com) |
2022-02-04 05:06:59 +0100 | wroathe | (~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host) |
2022-02-04 05:06:59 +0100 | wroathe | (~wroathe@user/wroathe) |
2022-02-04 05:07:57 +0100 | oscurochu | (~oscurochu@097-096-050-227.res.spectrum.com) (Ping timeout: 240 seconds) |
2022-02-04 05:08:15 +0100 | nunggu | (~q@user/nunggu) (Ping timeout: 276 seconds) |
2022-02-04 05:10:56 +0100 | nunggu | (~q@user/nunggu) |
2022-02-04 05:12:24 +0100 | doxen | (~bbrahms@pool-173-54-217-168.nwrknj.fios.verizon.net) |
2022-02-04 05:14:03 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 256 seconds) |
2022-02-04 05:14:40 +0100 | retroid_ | (~retro@2e40edd9.skybroadband.com) (Ping timeout: 250 seconds) |
2022-02-04 05:18:20 +0100 | phma | (~phma@host-67-44-208-198.hnremote.net) (Read error: Connection reset by peer) |
2022-02-04 05:21:03 +0100 | retroid_ | (~retro@2e40edd9.skybroadband.com) |
2022-02-04 05:22:54 +0100 | burnsidesLlama | (~burnsides@dhcp168-042.wadham.ox.ac.uk) (Remote host closed the connection) |
2022-02-04 05:23:26 +0100 | burnsidesLlama | (~burnsides@client-8-80.eduroam.oxuni.org.uk) |
2022-02-04 05:23:41 +0100 | phma | (~phma@2001:0:c38c:c38c:146a:837a:bcd3:2f88) |
2022-02-04 05:27:39 +0100 | burnsidesLlama | (~burnsides@client-8-80.eduroam.oxuni.org.uk) (Ping timeout: 256 seconds) |
2022-02-04 05:31:07 +0100 | phma | (~phma@2001:0:c38c:c38c:146a:837a:bcd3:2f88) (Ping timeout: 250 seconds) |
2022-02-04 05:31:13 +0100 | phma_ | (phma@2001:5b0:210d:a008:2b93:5e3e:cefa:7af9) |
2022-02-04 05:35:33 +0100 | nunggu | (~q@user/nunggu) (Ping timeout: 276 seconds) |
2022-02-04 05:37:27 +0100 | nunggu | (~q@user/nunggu) |
2022-02-04 05:39:17 +0100 | chenqisu1 | (~chenqisu1@183.217.200.249) (Ping timeout: 240 seconds) |
2022-02-04 05:40:30 +0100 | modnar | (~modnar@shell.sonic.net) (Quit: No Ping reply in 180 seconds.) |
2022-02-04 05:40:52 +0100 | modnar | (~modnar@shell.sonic.net) |
2022-02-04 05:59:57 +0100 | doxen | (~bbrahms@pool-173-54-217-168.nwrknj.fios.verizon.net) (Ping timeout: 256 seconds) |
2022-02-04 06:07:23 +0100 | yaroot | (~yaroot@57.48.30.125.dy.iij4u.or.jp) (Remote host closed the connection) |
2022-02-04 06:08:07 +0100 | yaroot | (~yaroot@57.48.30.125.dy.iij4u.or.jp) |
2022-02-04 06:08:23 +0100 | zebrag | (~chris@user/zebrag) |
2022-02-04 06:11:51 +0100 | Lord_of_Life | (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 256 seconds) |
2022-02-04 06:12:53 +0100 | wavemode | (~wavemode@c-98-223-145-19.hsd1.il.comcast.net) |
2022-02-04 06:14:00 +0100 | jinsun | (~quassel@user/jinsun) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) |
2022-02-04 06:14:17 +0100 | Lord_of_Life | (~Lord@user/lord-of-life/x-2819915) |
2022-02-04 06:14:50 +0100 | jinsun | (~quassel@user/jinsun) |
2022-02-04 06:16:34 +0100 | zebrag | (~chris@user/zebrag) (Quit: Konversation terminated!) |
2022-02-04 06:16:49 +0100 | sharky2 | (~bc8147f2@cerf.good1.com) |
2022-02-04 06:19:00 +0100 | <sharky2> | hi. I'm trying to read haskell show string from a file, and it works fine, except I get "Exception: Prelude.read: no parse" if the line is invalid. this shouldn't happen in practice, since file is computer generated, but I still want to handle it |
2022-02-04 06:19:17 +0100 | wroathe | (~wroathe@user/wroathe) (Ping timeout: 240 seconds) |
2022-02-04 06:19:52 +0100 | <ski> | > (reads :: ReadS Integer) "123abc" |
2022-02-04 06:19:53 +0100 | <lambdabot> | [(123,"abc")] |
2022-02-04 06:20:01 +0100 | <ski> | > (reads :: ReadS Integer) "abc" |
2022-02-04 06:20:03 +0100 | <lambdabot> | [] |
2022-02-04 06:20:42 +0100 | <ski> | > case [n | (n,s) <- (reads :: ReadS Integer) " 123 ",("","") <- lex s] of [n] -> Just n; _ -> Nothing |
2022-02-04 06:20:44 +0100 | <lambdabot> | Just 123 |
2022-02-04 06:21:03 +0100 | [itchyjunk] | (~itchyjunk@user/itchyjunk/x-7353470) (Remote host closed the connection) |
2022-02-04 06:21:38 +0100 | <sharky2> | thanks. ReadS Integer is a bit confusing. is that required or can haskell figure out the types |
2022-02-04 06:21:41 +0100 | <ski> | > Text.Read.readMaybe " 123 " :: Maybe Integer |
2022-02-04 06:21:42 +0100 | <lambdabot> | Just 123 |
2022-02-04 06:22:44 +0100 | <ski> | > case [ns | (ns,s) <- replicateM 3 (StateT (reads :: ReadS Integer)) `runStateT` " 123 45 6 ",("","") <- lex s] of [ns] -> Just ns; _ -> Nothing |
2022-02-04 06:22:46 +0100 | <lambdabot> | Just [123,45,6] |
2022-02-04 06:22:50 +0100 | <ski> | > case [ns | (ns,s) <- many (StateT (reads :: ReadS Integer)) `runStateT` " 123 45 6 ",("","") <- lex s] of [ns] -> Just ns; _ -> Nothing |
2022-02-04 06:22:51 +0100 | <lambdabot> | Just [123,45,6] |
2022-02-04 06:24:01 +0100 | <sharky2> | :t readMaybe |
2022-02-04 06:24:02 +0100 | <lambdabot> | Read a => String -> Maybe a |
2022-02-04 06:25:37 +0100 | cynomys | (~cynomys@user/cynomys) |
2022-02-04 06:27:02 +0100 | <ski> | "is that required or can haskell figure out the types" -- usually/commonly the context determines which type of value you want to read (and then you don't need the type ascriptions). but sometimes it doesn't pin it down .. |
2022-02-04 06:27:34 +0100 | <Axman6> | sometimes there are an infinite number of possible types, and GHC finds that a bit much |
2022-02-04 06:28:23 +0100 | <sharky2> | out of curiosity, there's no way to catch exception returned by read? |
2022-02-04 06:28:37 +0100 | <ski> | you're better of using `reads' or `readMaybe' |
2022-02-04 06:28:58 +0100 | <Axman6> | you can use evaluate (read foo) `catch` \e -> ... but don't do that |
2022-02-04 06:29:12 +0100 | <Axman6> | because we have pure ways to finding out if it failed to parse or not |
2022-02-04 06:29:21 +0100 | <Axman6> | readMay is probably the best way to go |
2022-02-04 06:29:24 +0100 | <ski> | (you can catch evaluation exceptions in `IO', but it's clunky .. only if you really need to) |
2022-02-04 06:29:32 +0100 | <Axman6> | you can't catch exceptions in pure code |
2022-02-04 06:31:18 +0100 | deadmarshal | (~deadmarsh@95.38.114.73) |
2022-02-04 06:34:19 +0100 | <ski> | type ReadS a = String -> [(a,String)] -- fwiw |
2022-02-04 06:34:38 +0100 | wroathe | (~wroathe@206-55-188-8.fttp.usinternet.com) |
2022-02-04 06:34:38 +0100 | wroathe | (~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host) |
2022-02-04 06:34:38 +0100 | wroathe | (~wroathe@user/wroathe) |
2022-02-04 06:34:57 +0100 | bontaq | (~user@ool-45779fe5.dyn.optonline.net) (Ping timeout: 240 seconds) |
2022-02-04 06:35:59 +0100 | deadmarshal | (~deadmarsh@95.38.114.73) (Ping timeout: 256 seconds) |
2022-02-04 06:36:21 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) (Remote host closed the connection) |
2022-02-04 06:41:10 +0100 | <sharky2> | since I'm mostly just learning, how would I go about catching read's exception? catch seems to require exception type, what do I put as the type? |
2022-02-04 06:41:21 +0100 | <dsal> | :t readMaybe |
2022-02-04 06:41:22 +0100 | <lambdabot> | Read a => String -> Maybe a |
2022-02-04 06:42:02 +0100 | <dsal> | sharky2: Exceptions are for IO kinds of things. The thing you're thinking of is a sort of exception, but it's the result of a partial function. Best to just avoid partial functions altogether. :) |
2022-02-04 06:42:33 +0100 | <dibblego> | if you insist on using catch, try readFile |
2022-02-04 06:44:10 +0100 | ski | . o O ( `readsFile' ) |
2022-02-04 06:44:48 +0100 | <Axman6> | I would pretty strongly recommend against learning about exceptions if you are trying to learn Haskell. I don't think I've ever written any code that threw them, and only rarely needed to catch them. They are something to know about the existance of, but not a fundamental topic |
2022-02-04 06:46:02 +0100 | deadmarshal | (~deadmarsh@95.38.114.73) |
2022-02-04 06:48:27 +0100 | wroathe | (~wroathe@user/wroathe) (Ping timeout: 256 seconds) |
2022-02-04 06:50:10 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) |
2022-02-04 06:50:33 +0100 | <monochrom> | Please use Text.Read's readMaybe. |
2022-02-04 06:53:03 +0100 | <monochrom> | I use partial functions sometimes, but only when I have already vetted the input somehow, never because I have the obvious XY problem of waiting for it to bomb and picking up the pieces later. |
2022-02-04 06:53:39 +0100 | Jing | (~hedgehog@240e:390:7c53:a7e1:8d1b:5472:3cae:e50c) |
2022-02-04 06:56:03 +0100 | ski | . o O ( "Parse, don't validate" in 2019-11-05 at <https://lexi-lambda.github.io/blog/2019/11/05/parse-don-t-validate/> ) |
2022-02-04 07:00:28 +0100 | <monochrom> | Exceptions make sense when and only when you're dealing with the cruel outside world where for example you want to open a file but what if the system doesn't let you and it makes no sense to ask to ask you just have to try and see if it fails. |
2022-02-04 07:01:16 +0100 | <monochrom> | Note that "if the system lets me then open it" makes no sense in this case because race conditions. |
2022-02-04 07:02:16 +0100 | <monochrom> | Whereas "if x=0 then I can do 5/x else I can't" makes more sense than "let me just try 5/x and let it fail". It is quite the opposite. |
2022-02-04 07:05:46 +0100 | <monochrom> | Err if x/=0 ! |
2022-02-04 07:05:57 +0100 | <ski> | > 7 `mod_` 0 |
2022-02-04 07:05:58 +0100 | <lambdabot> | 7 |
2022-02-04 07:06:48 +0100 | wroathe | (~wroathe@206-55-188-8.fttp.usinternet.com) |
2022-02-04 07:06:48 +0100 | wroathe | (~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host) |
2022-02-04 07:06:48 +0100 | wroathe | (~wroathe@user/wroathe) |
2022-02-04 07:07:44 +0100 | <sharky2> | okay. I thought would be simple enough to catch exception, but I already know how to use readMaybe |
2022-02-04 07:09:45 +0100 | jao | (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Ping timeout: 256 seconds) |
2022-02-04 07:10:43 +0100 | <EvanR> | sharky2, the thing is, stuff like 1/0, head [], and read "blub" :: Int aren't designed to be caught. It's possible but normally you would only catch exceptions caused by an explicit throw or IO error |
2022-02-04 07:11:11 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) |
2022-02-04 07:11:29 +0100 | takuan | (~takuan@178-116-218-225.access.telenet.be) |
2022-02-04 07:11:39 +0100 | <EvanR> | specifically, you'd need to know the exceptions type so you can name it using the dynamically typed exception system |
2022-02-04 07:11:55 +0100 | wroathe | (~wroathe@user/wroathe) (Ping timeout: 256 seconds) |
2022-02-04 07:12:46 +0100 | <EvanR> | if you wanted to catch one |
2022-02-04 07:13:15 +0100 | <EvanR> | those three examples are just things you don't want to happen in the first place |
2022-02-04 07:29:47 +0100 | img_ | (~img@user/img) (Quit: ZNC 1.8.2 - https://znc.in) |
2022-02-04 07:31:31 +0100 | Erutuon | (~Erutuon@user/erutuon) (Ping timeout: 256 seconds) |
2022-02-04 07:33:37 +0100 | <EvanR> | also the AOL keyword to bypass all that and read up on it is "Control.Exception" |
2022-02-04 07:34:08 +0100 | Erutuon | (~Erutuon@user/erutuon) |
2022-02-04 07:35:03 +0100 | notzmv | (~zmv@user/notzmv) (Ping timeout: 250 seconds) |
2022-02-04 07:36:05 +0100 | img | (~img@user/img) |
2022-02-04 07:39:25 +0100 | echoreply | (~echoreply@2001:19f0:9002:1f3b:5400:ff:fe6f:8b8d) (Quit: WeeChat 2.8) |
2022-02-04 07:40:43 +0100 | echoreply | (~echoreply@45.32.163.16) |
2022-02-04 07:41:05 +0100 | slowButPresent | (~slowButPr@user/slowbutpresent) (Quit: leaving) |
2022-02-04 07:41:49 +0100 | <dsal> | But you should probably have an idea of when the exception will get raised, because it may not be until after you try to catch it. |
2022-02-04 07:42:52 +0100 | <EvanR> | try (return (read "blub")) vs try (return $! (read "blub")) -- xD |
2022-02-04 07:43:41 +0100 | <EvanR> | (haskell, not the best imperative language) |
2022-02-04 07:44:20 +0100 | <ski> | or `evaluate (read "blub")' |
2022-02-04 07:45:07 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 256 seconds) |
2022-02-04 07:45:30 +0100 | arjun | (~arjun@user/arjun) |
2022-02-04 07:47:23 +0100 | deadmarshal | (~deadmarsh@95.38.114.73) (Ping timeout: 256 seconds) |
2022-02-04 07:47:28 +0100 | <arjun> | is it only me or associated type families look a bit like OO programming ? : P |
2022-02-04 07:47:49 +0100 | <EvanR> | hmm... in what way |
2022-02-04 07:48:33 +0100 | <arjun> | like a set of related functionality bunched together and then you make new instances (objects) for each type and use them |
2022-02-04 07:48:55 +0100 | <arjun> | but that's probably true for a lot of things i guess, heh |
2022-02-04 07:49:16 +0100 | <ski> | how do you make new instances (objects), with associated type families ? |
2022-02-04 07:49:23 +0100 | <arjun> | but ATF a little more so |
2022-02-04 07:49:57 +0100 | <arjun> | i've come across a Graph example |
2022-02-04 07:50:37 +0100 | <ski> | (also, i'd think that sending a message to an object is a bit more primary) |
2022-02-04 07:53:43 +0100 | <arjun> | ski, something like this https://pastebin.com/xbyNk1bx |
2022-02-04 07:54:16 +0100 | <arjun> | but while writing this i realized, this is just a regular typeclass and the whole thing is not an associated type family, just the first two things : P |
2022-02-04 07:54:37 +0100 | <arjun> | guess talking to other people really does help, huh. |
2022-02-04 07:55:18 +0100 | <EvanR> | it can be hard to recover from OOP brainwashing xD |
2022-02-04 07:55:40 +0100 | <ski> | still not seeing what'd be so OO about this |
2022-02-04 07:55:49 +0100 | <EvanR> | ellipses, unicorns, multiple inheritance o my |
2022-02-04 07:55:54 +0100 | <arjun> | ski's out of the matrix |
2022-02-04 07:56:13 +0100 | vysn | (~vysn@user/vysn) (Ping timeout: 256 seconds) |
2022-02-04 07:56:17 +0100 | <ski> | where are the instances (objects) ? |
2022-02-04 07:56:44 +0100 | <EvanR> | knee jerk reaction is that type classes type family or not, doesn't give you internal mutable state. Which may we never wanted to associate with OOP but |
2022-02-04 07:56:47 +0100 | <ski> | where are the messages ? where are the methods giving the behaviour of a message, as received by an object ? |
2022-02-04 07:57:33 +0100 | <ski> | where are the classes (aka object factories) ? |
2022-02-04 07:57:54 +0100 | <EvanR> | there's at most 1 instance of a type class for a given type, so you can't even 'new' them xD |
2022-02-04 07:58:03 +0100 | <EvanR> | everything's a singleton |
2022-02-04 07:58:20 +0100 | <arjun> | ski, This place is not a place of honor... no highly esteemed deed is commemorated here... nothing valued is here. |
2022-02-04 07:58:23 +0100 | Erutuon | (~Erutuon@user/erutuon) (Ping timeout: 256 seconds) |
2022-02-04 07:58:48 +0100 | <arjun> | context for the joke -> https://en.wikipedia.org/wiki/Long-time_nuclear_waste_warning_messages |
2022-02-04 07:58:59 +0100 | <ski> | (anyway .. one can well do OO stuff in Haskell .. i just don't see how any of this example is related to OO) |
2022-02-04 07:59:54 +0100 | <Axman6> | needs more glowing cats |
2022-02-04 08:01:37 +0100 | ski | . o O ( <https://lambdacats.github.io/extensible/> ) |
2022-02-04 08:01:47 +0100 | <EvanR> | aliens / planet of the apes dudes eventually make it through the levels of complexity and finally find out about the nuclear waste |
2022-02-04 08:02:01 +0100 | <EvanR> | "why didn't they just say so" |
2022-02-04 08:03:00 +0100 | <ski> | weren't monads supposedly like radiation suits ? |
2022-02-04 08:03:09 +0100 | <arjun> | i'm half expecting we'd land in a timeline where people will build NFT's out of nuclear warnings |
2022-02-04 08:03:10 +0100 | <EvanR> | I think that was comonads |
2022-02-04 08:03:42 +0100 | ski | glares at Dick Kieburtz |
2022-02-04 08:03:58 +0100 | <arjun> | guess that's a topic for haskell-offtopic |
2022-02-04 08:05:52 +0100 | alp | (~alp@user/alp) |
2022-02-04 08:06:59 +0100 | Inst | (~delicacie@c-98-208-218-119.hsd1.fl.comcast.net) (Ping timeout: 256 seconds) |
2022-02-04 08:11:37 +0100 | alp | (~alp@user/alp) (Ping timeout: 240 seconds) |
2022-02-04 08:14:24 +0100 | <sharky2> | so I know I was told not to catch read exception, but curiosity got the better out of me, and I googled a solution that seems to work pretty well (it uses unsafePerformIO). what do you think? https://paste.tomsmeding.com/HBZShTDG |
2022-02-04 08:14:42 +0100 | <EvanR> | what why ... |
2022-02-04 08:14:43 +0100 | <ski> | don't use `unsafePerformIO' |
2022-02-04 08:14:46 +0100 | <EvanR> | ^ |
2022-02-04 08:14:58 +0100 | <ski> | (or `unsafeCoerce' ..) |
2022-02-04 08:15:22 +0100 | michalz | (~michalz@185.246.204.75) |
2022-02-04 08:15:25 +0100 | <sharky2> | ski, it allows us to catch undefined outside of IO though |
2022-02-04 08:15:32 +0100 | <ski> | that's a bad thing |
2022-02-04 08:15:42 +0100 | <EvanR> | catching undefined... |
2022-02-04 08:15:51 +0100 | <EvanR> | specifically... |
2022-02-04 08:16:17 +0100 | shriekingnoise | (~shrieking@201.231.16.156) (Quit: Quit) |
2022-02-04 08:16:25 +0100 | <sharky2> | if we only had read, and alternative was to make readMaybe return IO a, wouldn't this be better? is there anything unsafe about it? |
2022-02-04 08:16:27 +0100 | lavaman | (~lavaman@98.38.249.169) |
2022-02-04 08:16:57 +0100 | kaph | (~kaph@net-2-47-208-144.cust.vodafonedsl.it) (Ping timeout: 240 seconds) |
2022-02-04 08:17:12 +0100 | <EvanR> | read is an example of a function with a bad interface, don't make it worse xD |
2022-02-04 08:18:14 +0100 | <EvanR> | use it correctly (hard to do in the context of parsing unknown data) or use a better interface |
2022-02-04 08:18:37 +0100 | <sharky2> | sure. but if that is all we had, isn't this good and safe? I made "undefinedToMaybe :: a -> Maybe a" too :) |
2022-02-04 08:18:42 +0100 | wyrd | (~wyrd@gateway/tor-sasl/wyrd) (Ping timeout: 276 seconds) |
2022-02-04 08:18:59 +0100 | <EvanR> | that's a weird thing to only have |
2022-02-04 08:19:12 +0100 | <sharky2> | I got it from here: https://stackoverflow.com/questions/9392129/detect-bottom-value-in-haskell/17652042 |
2022-02-04 08:19:19 +0100 | <EvanR> | there's an old package called spoon that does what you are talking about |
2022-02-04 08:19:29 +0100 | <EvanR> | haven't heard of it in a while thankfully xD |
2022-02-04 08:19:48 +0100 | <sharky2> | is there anything inherently unsafe with this though? |
2022-02-04 08:20:02 +0100 | <EvanR> | basically it came about because someone said "what if we want to catch undefined in pure code" |
2022-02-04 08:20:02 +0100 | <dminuoso> | Yes |
2022-02-04 08:20:37 +0100 | lavaman | (~lavaman@98.38.249.169) (Ping timeout: 240 seconds) |
2022-02-04 08:20:48 +0100 | <dminuoso> | You start on a road where you lose some of the reasoning abilities of haskell if you are trying to catch pure exceptions in pure code. |
2022-02-04 08:21:09 +0100 | <dminuoso> | And it's very unidiomatic |
2022-02-04 08:21:29 +0100 | <dminuoso> | read has a simpler form `readMaybe` that lets you handle failed parses if you insist on using Read. |
2022-02-04 08:21:46 +0100 | <dminuoso> | If this is a problem you experience from upstream libraries, file a bug report or fix it upstream. `read` should be banned. |
2022-02-04 08:22:52 +0100 | <EvanR> | when two bads combine to form a "works doesn't it?" you become a baby web xD |
2022-02-04 08:23:08 +0100 | <sharky2> | can you show me when it would fail? I don't know what I'm doing, I just copy pasted code from stackoverflow, and it works well. full code and example in ghci: https://paste.tomsmeding.com/n6jrXxhi |
2022-02-04 08:23:10 +0100 | <ski> | an expression whose evaluation triggers an exception is semantically a "bottom" value (meaning "no answer/result"). another example of a bottom value is an infinite loop. denotationally, we treat all bottom values as indistinguishable from each other. that is, we like to use refactorings that may sometimes turn one form of a bottom value into another form |
2022-02-04 08:23:41 +0100 | <dminuoso> | You lose monotonicity of definedness |
2022-02-04 08:23:50 +0100 | <dminuoso> | Something you really dont want to toss out |
2022-02-04 08:24:05 +0100 | <ski> | (e.g., if you're running GHC in single-threaded mode, it can, sometimes, catch infinite loops, and will throw an exception. but it can't always, and we'd prefer not attempting to distinguish, at the user level, when it can, and when it can't) |
2022-02-04 08:24:13 +0100 | <EvanR> | could catching an undefined change the result of lub |
2022-02-04 08:24:21 +0100 | <EvanR> | in a bad way |
2022-02-04 08:24:47 +0100 | wyrd | (~wyrd@gateway/tor-sasl/wyrd) |
2022-02-04 08:24:48 +0100 | <sharky2> | ok. but when used with read specifically, this is guaranteed to work? |
2022-02-04 08:24:58 +0100 | <dminuoso> | No. |
2022-02-04 08:25:00 +0100 | <sharky2> | or anything that returns error/undefined, and doesn't infinite loop |
2022-02-04 08:25:02 +0100 | <dminuoso> | That's the beginning of the problem |
2022-02-04 08:25:13 +0100 | <ski> | you're really using `unsafeCoerce' there in an unsafe way |
2022-02-04 08:25:27 +0100 | <dminuoso> | First you cant distinguish between errors properly, we have imprecise exception semantics, next up you have the loss of monotonicity. |
2022-02-04 08:25:31 +0100 | <dminuoso> | Really, use `readMaybe` |
2022-02-04 08:25:34 +0100 | <dminuoso> | That's the way to do it. |
2022-02-04 08:25:40 +0100 | <ski> | (or `reads') |
2022-02-04 08:26:14 +0100 | ski | . o O ( coercing from `a' to `IO ()', then executing .. what could go wrong ? ) |
2022-02-04 08:26:27 +0100 | <EvanR> | read will throw an ErrorCall, which you can catch in IO |
2022-02-04 08:26:48 +0100 | <EvanR> | but readMaybe can be used without IO |
2022-02-04 08:26:56 +0100 | <EvanR> | win win vs lose lose |
2022-02-04 08:27:35 +0100 | <sharky2> | I understand. but I'm talking about hypothetical example where the only interface was read. I'm just wondering when undefinedToMaybe would fail, because I can't make it fail with read, in ghci or ghc |
2022-02-04 08:27:45 +0100 | <ski> | anyway, monotonicity is a big deal |
2022-02-04 08:27:50 +0100 | <EvanR> | another thing is that read takes a [Char], anything in that string could throw an ErrorCall |
2022-02-04 08:28:05 +0100 | <EvanR> | you'd be masking that error |
2022-02-04 08:28:28 +0100 | <dminuoso> | sharky2: The problems are way more fundamental than "might not work" |
2022-02-04 08:29:17 +0100 | <ski> | @free undefinedToMaybe :: a -> Maybe a |
2022-02-04 08:29:17 +0100 | <lambdabot> | $map_Maybe f . undefinedToMaybe = undefinedToMaybe . f |
2022-02-04 08:30:07 +0100 | lortabac | (~lortabac@2a01:e0a:541:b8f0:56b3:2a4c:af18:8385) |
2022-02-04 08:30:21 +0100 | <ski> | this law claims that `fmap (const c) (undefinedToMaybe x) = undefinedToMaybe (const c x)' .. which is not the case, for your `undefinedToMaybe' .. so, it breaks parametricity ("free theorems") |
2022-02-04 08:30:33 +0100 | <EvanR> | sharky2, on your code specifically, why are you even using unsafeCoerce... |
2022-02-04 08:30:56 +0100 | <ski> | because they don't know how to use `evaluate' or `return $!' |
2022-02-04 08:30:57 +0100 | <sharky2> | EvanR I got the code from stackoverflow link I pasted above |
2022-02-04 08:31:00 +0100 | <EvanR> | if all you want to do is catch the exception that happens when trying to read, using catch within unsafePerformIO |
2022-02-04 08:31:07 +0100 | mikoto-chan | (~mikoto-ch@213.177.151.239) |
2022-02-04 08:31:11 +0100 | <awpr> | er, how did that not crash? IO is a newtype of `State# _ -> (a, State# _)`, and it's coercing some non-function type to IO |
2022-02-04 08:31:23 +0100 | <EvanR> | sharky2, so we might want to understand what it even does before even asking xD |
2022-02-04 08:31:32 +0100 | <sharky2> | if you it can be written better then please tell me how. |
2022-02-04 08:31:47 +0100 | <c_wraith> | if you see a stackoverflow answer that recommends unsafeCoerce, find a different answer. :) |
2022-02-04 08:31:55 +0100 | <awpr> | can be written better as `import Text.Read (readMaybe)` :) |
2022-02-04 08:31:59 +0100 | <dminuoso> | sharky2: We told you, the only reasonable better way is to straight up use readMaybe. |
2022-02-04 08:32:05 +0100 | <EvanR> | you only want a half-fixed version xD |
2022-02-04 08:32:07 +0100 | <EvanR> | weird |
2022-02-04 08:32:13 +0100 | <dminuoso> | sharky2: It's not about how you can implement `unsafeCatch` better, the mere presence of such a primitive is the problem. |
2022-02-04 08:32:16 +0100 | <c_wraith> | (not that unsafeCoerce is always wrong - it exists for a reason. but if you don't know exactly why you're using it, you shouldn't be) |
2022-02-04 08:32:19 +0100 | deadmarshal | (~deadmarsh@95.38.114.73) |
2022-02-04 08:32:23 +0100 | <EvanR> | you're better served understanding what those bits do, instead of doing "read" wrong |
2022-02-04 08:32:27 +0100 | <sharky2> | dminuoso, what if readMaybe didn't exist? |
2022-02-04 08:32:40 +0100 | <awpr> | then write it in terms of `reads` |
2022-02-04 08:32:45 +0100 | <dminuoso> | heh |
2022-02-04 08:32:52 +0100 | <EvanR> | it must exist, since it's a construction of the mind |
2022-02-04 08:32:53 +0100 | <sharky2> | and if read was the only function that existed? |
2022-02-04 08:33:02 +0100 | <ski> | generally (as for `eval' in other languages), `unsafePerformIO' and `unsafeCoerce' should not be used, unless you know why they should not be used (and even then you need to be doubly careful, and know safeguards and stuff) |
2022-02-04 08:33:03 +0100 | <awpr> | then the library in question should not be used |
2022-02-04 08:33:04 +0100 | <EvanR> | you can implement readMaybe yourself |
2022-02-04 08:33:16 +0100 | <dminuoso> | sharky2: Your line of thinking is flawed in its premise, in that `read` is a sensible primitive to begin with. |
2022-02-04 08:33:19 +0100 | <dminuoso> | It's not. |
2022-02-04 08:33:20 +0100 | <EvanR> | it's like asking if the integers did not exist |
2022-02-04 08:33:24 +0100 | <EvanR> | you construct the integers |
2022-02-04 08:33:26 +0100 | <dminuoso> | `read` is the proper mistake here. |
2022-02-04 08:33:31 +0100 | <dminuoso> | It shouldn't exist. |
2022-02-04 08:33:37 +0100 | <dminuoso> | It's a historical accient |
2022-02-04 08:33:52 +0100 | eggplantade | (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
2022-02-04 08:33:57 +0100 | <sharky2> | dminuoso, and yet it still exists.. in base no less. I'm sure there are libraries where a function returning error is the only interface they provide. and "don't use that library" is not a useful practical advice |
2022-02-04 08:34:25 +0100 | <EvanR> | it goes exactly like that a lot, which is good |
2022-02-04 08:34:25 +0100 | ski | sometimes passes `StateT reads' to `replicateM n' or `many'/`some' |
2022-02-04 08:34:30 +0100 | <dminuoso> | sharky2: My advice earlier was: file a bug report or fix those upstream libraries if you encounter them |
2022-02-04 08:34:33 +0100 | <dminuoso> | :) |
2022-02-04 08:34:47 +0100 | ski | agrees |
2022-02-04 08:34:50 +0100 | <EvanR> | libraries with a terrible error interface usually don't get a lot of traction |
2022-02-04 08:35:06 +0100 | <EvanR> | (base is an outlier) |
2022-02-04 08:35:16 +0100 | _ht | (~quassel@231-169-21-31.ftth.glasoperator.nl) |
2022-02-04 08:35:50 +0100 | <EvanR> | e.g. Aeson for json doesn't throw error and except you to catch it |
2022-02-04 08:35:52 +0100 | <dminuoso> | sharky2: But yes, you are absolutely right that it exists in base. We are bad at making backwards breaking changes in `base`, we have a multitude of things that, in hindsight, should have never gone into base. |
2022-02-04 08:35:57 +0100 | zmt00 | (~zmt00@user/zmt00) (Ping timeout: 240 seconds) |
2022-02-04 08:36:40 +0100 | <ski> | sharky2 : if you put in more information, you shouldn't get less, or different, information out. that's a big deal (monotonicity) |
2022-02-04 08:37:21 +0100 | <dminuoso> | And perhaps we should make more of an effort to document these things in base, pointing out to beginners which things to stay clear of. |
2022-02-04 08:37:29 +0100 | <dminuoso> | And this should propagate to learning resources as well |
2022-02-04 08:37:41 +0100 | <sharky2> | this is interesting.. not something I expected. it works even if undefined is passed to read. undefinedToMaybe (read (error "hehe")) :: Maybe Int |
2022-02-04 08:37:47 +0100 | <dminuoso> | Who knows, perhaps you could make this adventure and improve the situation. |
2022-02-04 08:38:24 +0100 | <ski> | (hm, this seems related to the property of "steadfastness", in Prolog, where if you put in more information, you'll get more information in solutions that you get, but solutions may also be dropped. in any case the new set of concrete instantiations of the solutions will be a subset of the old such set) |
2022-02-04 08:38:27 +0100 | <EvanR> | also, undefinedToMaybe (read ("123" ++ undefined ++ "5") :: Int) |
2022-02-04 08:39:09 +0100 | <EvanR> | undefinedToMaybe (read ("123" ++ (let x = x in x) ++ "5") :: Int) on the other hand |
2022-02-04 08:39:56 +0100 | <sharky2> | anyway I understand that this is pretty horrible, and shouldn't be used if at all possible. but EvanR you said something about a better way of writing undefinedToMaybe. how would you write it instead? |
2022-02-04 08:40:08 +0100 | <sharky2> | and in what way would it be better? |
2022-02-04 08:40:09 +0100 | <EvanR> | there's no reason to use unsafeCoerce |
2022-02-04 08:40:14 +0100 | <EvanR> | go ahead and figure out why |
2022-02-04 08:40:20 +0100 | <c_wraith> | sharky2: if you really must, the spoon library exists |
2022-02-04 08:40:20 +0100 | deadmarshal_ | (~deadmarsh@95.38.113.90) |
2022-02-04 08:40:25 +0100 | <dminuoso> | Im not entirely sure teaching how to write bad things with other bad or notoriously unsafe primitives is a useful thing |
2022-02-04 08:40:35 +0100 | <c_wraith> | at least let someone else write the horrible code |
2022-02-04 08:40:37 +0100 | <EvanR> | uhg I mentioned spoon but in a way to diminish it xD |
2022-02-04 08:40:59 +0100 | <sharky2> | spoon looks nice. I'll check the source |
2022-02-04 08:41:04 +0100 | <EvanR> | uhg |
2022-02-04 08:41:14 +0100 | rusrushal13 | (~rusrushal@2401:4900:5d15:a022:862f:921f:d1a9:883d) (Ping timeout: 256 seconds) |
2022-02-04 08:41:17 +0100 | deadmarshal | (~deadmarsh@95.38.114.73) (Ping timeout: 240 seconds) |
2022-02-04 08:41:32 +0100 | <EvanR> | dminuoso, well unsafePerformIO and unsafeCoerce need to be spoken of in the proper context, like sex education xD |
2022-02-04 08:41:35 +0100 | <dminuoso> | sharky2: The alternative would involve primitives that are even more notoriously dangerous - because a misuse of unsafeCoerce almost assuredly gives crashes or memory corruption on misuse, but misuses of the alternate primitives give the appearance of working at the cost of completely unexpected behavior. |
2022-02-04 08:41:38 +0100 | <EvanR> | spoon on the other hand... |
2022-02-04 08:41:51 +0100 | <EvanR> | might be beyond obscene |
2022-02-04 08:42:27 +0100 | <dminuoso> | sharky2: That other primitive is `unsafePerformIO`, which seems more benign which is a dangerous illusion. |
2022-02-04 08:42:29 +0100 | <ski> | @quote please.talk |
2022-02-04 08:42:29 +0100 | <lambdabot> | Dave_Benjamin says: please talk to your son or daughter about parametric polymorphism |
2022-02-04 08:43:31 +0100 | <ski> | (you can implement `unsafeCoerce', using `unsafePerformIO', and `IORef' ops) |
2022-02-04 08:43:45 +0100 | andreabedini | (~andreabed@8s8kj6nrww5p5nzkz2zz.ip6.superloop.com) (Quit: WeeChat 3.3) |
2022-02-04 08:43:47 +0100 | <EvanR> | uhg |
2022-02-04 08:44:10 +0100 | <ski> | (which is the reason why the value restriction is a thing, in the MLs) |
2022-02-04 08:44:17 +0100 | <dminuoso> | ski: We had a production bug a few months ago due to my misuse of unsafePerformIO, which after pondering a fair few hours I considered perfectly safe. Then GHC proceeded to alias a bunch of mutable buffers. |
2022-02-04 08:44:33 +0100 | <dminuoso> | Err sorry, that was supposed to hilight sharky2. |
2022-02-04 08:44:59 +0100 | <EvanR> | safePerformIO = no IO at all (abstinence) |
2022-02-04 08:45:12 +0100 | <dminuoso> | That was the final nail in the coffin for me to realize even as an advanced Haskeller it's very difficult to understand how unsafePerformIO interacts with your code - all your assumptions about what code does are tossed out of the window. |
2022-02-04 08:46:12 +0100 | <sharky2> | dminuoso, spoon should be safe though, no? |
2022-02-04 08:46:20 +0100 | <ski> | no |
2022-02-04 08:46:26 +0100 | vpan | (~0@212.117.1.172) |
2022-02-04 08:46:32 +0100 | <dminuoso> | No, because of the monotonicity reasons I pointed out. |
2022-02-04 08:46:56 +0100 | <dminuoso> | Like I said, the mere existence of such a primitive ruins reasoning abilities/properties about your code - and anything that transitively depends on it. |
2022-02-04 08:46:57 +0100 | <EvanR> | leave spoon to the trash heap of history xD |
2022-02-04 08:47:03 +0100 | ski | misses mmorrow .. |
2022-02-04 08:47:07 +0100 | <dminuoso> | `readMaybe` is the solution |
2022-02-04 08:47:10 +0100 | <ski> | preflex: xseen mmorrow |
2022-02-04 08:47:37 +0100 | <sharky2> | it seems to be that problem is that undefined/error even exists, and not that spoon exists |
2022-02-04 08:47:40 +0100 | <sharky2> | to me* |
2022-02-04 08:47:48 +0100 | <EvanR> | yeah |
2022-02-04 08:47:59 +0100 | <EvanR> | there are languages where undefined is not a thing |
2022-02-04 08:48:19 +0100 | <ski> | at least with catching of `error's from `IO', you can blame it one `IO' indeterminacy |
2022-02-04 08:48:29 +0100 | machinedgod | (~machinedg@24.105.81.50) |
2022-02-04 08:48:35 +0100 | <dminuoso> | What ski refers to is using `evaluate :: a -> IO a` |
2022-02-04 08:48:51 +0100 | <dminuoso> | But note, you still have imprecise exception semantics with this. |
2022-02-04 08:49:00 +0100 | <dminuoso> | https://www.microsoft.com/en-us/research/wp-content/uploads/1999/05/except.pdf |
2022-02-04 08:49:26 +0100 | <EvanR> | in those languages, you would probably see readMaybe xD |
2022-02-04 08:49:28 +0100 | <ski> | for `error "foo" + error "bar"', it'll nondeterministically choose which of those to yield |
2022-02-04 08:49:36 +0100 | gehmehgeh | (~user@user/gehmehgeh) |
2022-02-04 08:50:00 +0100 | <energizer> | is there a "resource locator/identfier" type that encompasses filesystem paths and uris and other stuff like that? |
2022-02-04 08:50:29 +0100 | <dminuoso> | energizer: Yes, UrI. |
2022-02-04 08:50:32 +0100 | <dminuoso> | URI, even. |
2022-02-04 08:50:45 +0100 | <dminuoso> | URI has the `file` scheme giving you filesystem path access |
2022-02-04 08:50:59 +0100 | <dminuoso> | How portable that actually ends up, I have no idea. |
2022-02-04 08:51:36 +0100 | <dminuoso> | (i.e. can URI with a file scheme represent arbitrary bytesequences for say windows filesystems?) |
2022-02-04 08:52:16 +0100 | <sharky2> | heh. undefinedToMaybe "foo" <interactive>: internal error: stg_ap_v_ret (GHC version 8.0.2 for x86_64_unknown_mingw32) Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug |
2022-02-04 08:52:26 +0100 | <awpr> | aha! |
2022-02-04 08:52:39 +0100 | ski | 's not surprised |
2022-02-04 08:52:41 +0100 | <EvanR> | so it was never working |
2022-02-04 08:52:47 +0100 | <awpr> | that's what I expected when I said "er, how did that not crash?" |
2022-02-04 08:53:04 +0100 | <sharky2> | it works with read though. odd |
2022-02-04 08:53:15 +0100 | <dminuoso> | That's unsafe primitives for you., |
2022-02-04 08:53:20 +0100 | <ski> | UB |
2022-02-04 08:53:42 +0100 | <dminuoso> | Perhaps they crash, perhaps not - who knows. `unsafe` really means "you're holding a shotgun loaded with dynamite. you have been warned" |
2022-02-04 08:53:43 +0100 | <EvanR> | oh right, you tried to write a function that converted *any* undefined to maybe, but kept insisting it was for read only |
2022-02-04 08:53:53 +0100 | <EvanR> | was very confuesd |
2022-02-04 08:54:17 +0100 | <dminuoso> | Hah, though recently Ive been using unsafeChr a lot - but these are actually benign. |
2022-02-04 08:54:31 +0100 | AlexNoo_ | AlexNoo |
2022-02-04 08:54:49 +0100 | <EvanR> | for badly catching the error from read, you do not need unsafeCoerce |
2022-02-04 08:54:56 +0100 | <dminuoso> | If you do this on Word8 anyway |
2022-02-04 08:55:05 +0100 | <ski> | (as is `unsafeInterleaveIO' (but not `unsafeInterleaveST') .. perhaps considered ill-advised, though) |
2022-02-04 08:55:40 +0100 | <awpr> | now I'm curious. does it crash on `undefinedToMaybe (42 :: Int)`? and on `undefinedToMaybe (21 + 21 :: Int)`? I have a theory. |
2022-02-04 08:56:50 +0100 | <awpr> | namely that if the argument happens to be a thunk, the coercion to IO just... accidentally doesn't cause problems, but if it's already a data constructor, it dies |
2022-02-04 08:57:00 +0100 | <sharky2> | awpr, it doesn't crash on those |
2022-02-04 08:57:42 +0100 | <EvanR> | that might not be a good thing |
2022-02-04 08:57:53 +0100 | <EvanR> | not crashing immediately but later on after corruption catches up with you |
2022-02-04 08:57:57 +0100 | <awpr> | huh, weird. gonna try some experiments |
2022-02-04 08:58:16 +0100 | <EvanR> | stuff we don't usually have to deal with because this isn't C |
2022-02-04 08:58:32 +0100 | <awpr> | I mean, if it crashes it's definitely broken. I'm just interested in how it ever manages not to crash |
2022-02-04 08:58:43 +0100 | <sharky2> | spoon "foo" works fine! |
2022-02-04 08:58:44 +0100 | <awpr> | if it crashes on some inputs* |
2022-02-04 08:59:08 +0100 | <EvanR> | I'm paranoid saying "not crashing doesn't definitely mean not broken" |
2022-02-04 08:59:22 +0100 | <ski> | presumably `spoon' doesn't use `unsafeCoerce' |
2022-02-04 08:59:36 +0100 | <dminuoso> | `spoon` uses unsafePerformIO |
2022-02-04 08:59:45 +0100 | <ski> | yea, obviously :) |
2022-02-04 09:01:43 +0100 | michalz2 | (~michalz2@185.246.204.89) |
2022-02-04 09:01:58 +0100 | alp | (~alp@user/alp) |
2022-02-04 09:02:25 +0100 | chele | (~chele@user/chele) |
2022-02-04 09:03:19 +0100 | Guest69 | (~Guest69@4.53.152.194.mga.com.pl) |
2022-02-04 09:04:27 +0100 | jonathanx_ | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Remote host closed the connection) |
2022-02-04 09:04:54 +0100 | <ski> | @wiki Error vs. Exception |
2022-02-04 09:04:54 +0100 | <lambdabot> | https://wiki.haskell.org/Error_vs._Exception |
2022-02-04 09:05:19 +0100 | <ski> | "A program should work as well when all `error's and `undefined's are replaced by infinite loops." |
2022-02-04 09:06:26 +0100 | <EvanR> | sharky2, unsafeCoerce causes GHC to "trust you" and consider whatever thing to be whatever type you want, regardless of whatever the eventual runtime object will look like. This is only safe for limited circumstances, even then, you have a burden of proof that no one helps you with |
2022-02-04 09:06:45 +0100 | razetime | (~quassel@49.207.209.26) (Remote host closed the connection) |
2022-02-04 09:06:57 +0100 | Gurkenglas | (~Gurkengla@dslb-090-186-104-244.090.186.pools.vodafone-ip.de) |
2022-02-04 09:07:10 +0100 | <EvanR> | the consequences of being wrong are pretty scary to me, having spent so many hours chasing memory corruption in C programs |
2022-02-04 09:08:01 +0100 | <EvanR> | so using it when you don't need it seems ridiculous |
2022-02-04 09:08:55 +0100 | <EvanR> | also, where *do* you need it |
2022-02-04 09:09:10 +0100 | <ski> | (re above link, another useful distinction is between faults and errors (and exceptions). a fault is a limitation in the implementation, e.g. an out-of-memory condition. a fault is the implementation admitting that it's failed to live up to its expectations) |
2022-02-04 09:09:45 +0100 | Ariakenom | (~Ariakenom@h-82-196-111-63.NA.cust.bahnhof.se) |
2022-02-04 09:10:43 +0100 | fendor | (~fendor@91.141.44.253.wireless.dyn.drei.com) |
2022-02-04 09:11:11 +0100 | <ski> | EvanR : i've seen it used when composing a function with an, operationally, identity/no-op function |
2022-02-04 09:11:13 +0100 | <sharky2> | difference between spoon and teaspoon is that spoon forces evaluation? |
2022-02-04 09:11:50 +0100 | <ski> | yea |
2022-02-04 09:12:16 +0100 | <ski> | (or, rather, `spoon' does deep evaluation, `teaspoon' doesn't) |
2022-02-04 09:12:49 +0100 | <EvanR> | I dislike spoon even more now |
2022-02-04 09:13:03 +0100 | <sharky2> | is the difference only noticeable when used in IO? ie, is readMaybe = spoon . read the same as readMaybe = teaspoon . read |
2022-02-04 09:13:36 +0100 | <c_wraith> | those behave very differently for some types |
2022-02-04 09:14:00 +0100 | Erutuon | (~Erutuon@user/erutuon) |
2022-02-04 09:16:21 +0100 | <EvanR> | you don't need IO to see difference between shallow and deep evaluation |
2022-02-04 09:16:38 +0100 | <ski> | "(1 % 0,-1 % 0)" |
2022-02-04 09:18:18 +0100 | Guest69 | (~Guest69@4.53.152.194.mga.com.pl) (Quit: Client closed) |
2022-02-04 09:18:45 +0100 | kukimik | (~kukimik@4.53.152.194.mga.com.pl) |
2022-02-04 09:21:12 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) |
2022-02-04 09:23:29 +0100 | cfricke | (~cfricke@user/cfricke) |
2022-02-04 09:24:40 +0100 | jgeerds | (~jgeerds@55d4a547.access.ecotel.net) |
2022-02-04 09:26:53 +0100 | Akiva | (~Akiva@user/Akiva) (Ping timeout: 256 seconds) |
2022-02-04 09:26:57 +0100 | _ht | (~quassel@231-169-21-31.ftth.glasoperator.nl) (Remote host closed the connection) |
2022-02-04 09:27:01 +0100 | mc47 | (~mc47@xmonad/TheMC47) |
2022-02-04 09:28:21 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) |
2022-02-04 09:30:55 +0100 | Sgeo | (~Sgeo@user/sgeo) (Read error: Connection reset by peer) |
2022-02-04 09:34:16 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:a019:43b1:3d96:a258) |
2022-02-04 09:36:05 +0100 | tzh | (~tzh@c-24-21-73-154.hsd1.or.comcast.net) (Quit: zzz) |
2022-02-04 09:38:17 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:a019:43b1:3d96:a258) (Ping timeout: 240 seconds) |
2022-02-04 09:39:24 +0100 | dcoutts | (~duncan@109.144.31.214) |
2022-02-04 09:42:13 +0100 | dcoutts_ | (~duncan@host86-187-229-255.range86-187.btcentralplus.com) |
2022-02-04 09:42:39 +0100 | noiobeforebed | (~noiobefor@2001:470:69fc:105::1:3c2d) |
2022-02-04 09:43:13 +0100 | Erutuon | (~Erutuon@user/erutuon) (Ping timeout: 256 seconds) |
2022-02-04 09:44:37 +0100 | dcoutts | (~duncan@109.144.31.214) (Ping timeout: 240 seconds) |
2022-02-04 09:46:44 +0100 | notzmv | (~zmv@user/notzmv) |
2022-02-04 09:47:10 +0100 | allbery_b | (~geekosaur@xmonad/geekosaur) |
2022-02-04 09:47:10 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b))) |
2022-02-04 09:47:11 +0100 | jgeerds_ | (~jgeerds@55d4a547.access.ecotel.net) |
2022-02-04 09:47:13 +0100 | allbery_b | geekosaur |
2022-02-04 09:47:57 +0100 | dcoutts_ | (~duncan@host86-187-229-255.range86-187.btcentralplus.com) (Ping timeout: 240 seconds) |
2022-02-04 09:48:31 +0100 | noiobeforebed | (~noiobefor@2001:470:69fc:105::1:3c2d) (Quit: issued !quit command) |
2022-02-04 09:49:13 +0100 | kukimik | (~kukimik@4.53.152.194.mga.com.pl) (Ping timeout: 256 seconds) |
2022-02-04 09:50:07 +0100 | jgeerds | (~jgeerds@55d4a547.access.ecotel.net) (Ping timeout: 256 seconds) |
2022-02-04 09:50:41 +0100 | deadmarshal_ | (~deadmarsh@95.38.113.90) (Ping timeout: 256 seconds) |
2022-02-04 09:54:53 +0100 | akegalj | (~akegalj@18-45.dsl.iskon.hr) |
2022-02-04 09:56:02 +0100 | MajorBiscuit | (~MajorBisc@wlan-145-94-218-48.wlan.tudelft.nl) |
2022-02-04 09:57:04 +0100 | kukimik | (~kukimik@4.53.152.194.mga.com.pl) |
2022-02-04 09:58:00 +0100 | noiobeforebed | (~noiobefor@2001:470:69fc:105::1:3c2d) |
2022-02-04 10:00:11 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) |
2022-02-04 10:00:51 +0100 | noiobeforebed | (~noiobefor@2001:470:69fc:105::1:3c2d) (Client Quit) |
2022-02-04 10:01:04 +0100 | noiobeforebed | (~noiobefor@2001:470:69fc:105::1:3c2d) |
2022-02-04 10:01:21 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) (Remote host closed the connection) |
2022-02-04 10:01:49 +0100 | Lord_of_Life | (~Lord@user/lord-of-life/x-2819915) (Excess Flood) |
2022-02-04 10:02:42 +0100 | maerwald | (~maerwald@user/maerwald) (Quit: gone) |
2022-02-04 10:03:00 +0100 | maerwald | (~maerwald@mail.hasufell.de) |
2022-02-04 10:03:15 +0100 | coot | (~coot@213.134.190.95) |
2022-02-04 10:03:43 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) |
2022-02-04 10:04:10 +0100 | Lord_of_Life | (~Lord@user/lord-of-life/x-2819915) |
2022-02-04 10:04:45 +0100 | zaquest | (~notzaques@5.130.79.72) (Remote host closed the connection) |
2022-02-04 10:04:45 +0100 | shachaf | (~shachaf@user/shachaf) (Ping timeout: 250 seconds) |
2022-02-04 10:04:57 +0100 | Inst | (~delicacie@c-98-208-218-119.hsd1.fl.comcast.net) |
2022-02-04 10:05:38 +0100 | shachaf | (~shachaf@user/shachaf) |
2022-02-04 10:05:43 +0100 | econo | (uid147250@user/econo) (Quit: Connection closed for inactivity) |
2022-02-04 10:07:11 +0100 | razetime | (~quassel@49.207.209.26) |
2022-02-04 10:08:10 +0100 | kukimik | (~kukimik@4.53.152.194.mga.com.pl) (Quit: Client closed) |
2022-02-04 10:09:53 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) (Quit: WeeChat 3.4) |
2022-02-04 10:11:17 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) |
2022-02-04 10:14:04 +0100 | max22- | (~maxime@2a01cb0883359800f5b23c2351d98307.ipv6.abo.wanadoo.fr) |
2022-02-04 10:16:17 +0100 | n3rdy1 | (~n3rdy1@2600:1700:4570:3480:1b88:50f:dae0:9293) (Ping timeout: 240 seconds) |
2022-02-04 10:17:41 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b))) |
2022-02-04 10:17:41 +0100 | allbery_b | (~geekosaur@xmonad/geekosaur) |
2022-02-04 10:17:44 +0100 | allbery_b | geekosaur |
2022-02-04 10:18:07 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) (Ping timeout: 256 seconds) |
2022-02-04 10:19:29 +0100 | adnaahm | (~adnaahm@host-57-net-67-160-119.mobilinkinfinity.net.pk) |
2022-02-04 10:19:35 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Remote host closed the connection) |
2022-02-04 10:20:04 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) |
2022-02-04 10:20:23 +0100 | <dminuoso> | I mean at its face value, I can see why `spoon` might seem appearing - Ive had my share of bottoms blow up inside nested data structures in the wrong places of code before |
2022-02-04 10:21:11 +0100 | desantra | (~skykanin@user/skykanin) |
2022-02-04 10:21:27 +0100 | <dminuoso> | It's very frustrating to have have some `parseConfig` hand you a timebomb |
2022-02-04 10:21:33 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 10:21:36 +0100 | <dminuoso> | Honestly, Im not sure how to address this correctly in the general case |
2022-02-04 10:23:15 +0100 | xkuru | (~xkuru@user/xkuru) |
2022-02-04 10:23:27 +0100 | Inst | (~delicacie@c-98-208-218-119.hsd1.fl.comcast.net) (Ping timeout: 256 seconds) |
2022-02-04 10:24:58 +0100 | <c_wraith> | in general? stop using libraries that do that |
2022-02-04 10:25:20 +0100 | Graham31415 | (~Graham314@5.33.56.252) |
2022-02-04 10:25:39 +0100 | <dminuoso> | Well, it was my own programming mistake. |
2022-02-04 10:26:03 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Ping timeout: 256 seconds) |
2022-02-04 10:26:42 +0100 | <dminuoso> | It's easy to say "dont use code that has bottoms" in a language where bottoms can arise unexpectedly and might not be covered by tests easily. |
2022-02-04 10:26:45 +0100 | zaquest | (~notzaques@5.130.79.72) |
2022-02-04 10:27:40 +0100 | <dminuoso> | My immediate solution was to attach NFData to every data involving the config and deepseq it right at parseConfig, which was fine because I eventually need all bits anyway. At least this would transfer the explosion point to something predictable |
2022-02-04 10:28:41 +0100 | <Graham31415> | Hi, I'm about to start writing my first haskell application. I saw RIO, and thought I'd start with that. I also want to use qualified imports for everything I can. In the example script at the bottom of https://www.fpcomplete.com/haskell/library/rio/ it imports RIO and also System.Environment. I'm guessing `getArgs` comes from System.Environment, |
2022-02-04 10:28:41 +0100 | <Graham31415> | and that this is part of the "base" package rather than RIO? So is it normal to use the RIO prelude and then use base things on top of it? That seems strange to me. |
2022-02-04 10:29:25 +0100 | <dminuoso> | Graham31415: Yes. |
2022-02-04 10:29:41 +0100 | <Graham31415> | (also, why dont more examples, tutorials, docs, etc. use qualified imports more?) |
2022-02-04 10:30:08 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) |
2022-02-04 10:30:17 +0100 | <Graham31415> | On the one hand, I see many folks advocating for qualified imports, on the other hand I dont see much learning material using them. |
2022-02-04 10:30:54 +0100 | <dminuoso> | Graham31415: There's not much guidance on qualified imports or not, it's a matter of personal taste and common sense. |
2022-02-04 10:31:38 +0100 | <c_wraith> | I don't like qualified imports for what they do to syntax. But that's mostly not important, and some libraries basically require you to use them. |
2022-02-04 10:32:07 +0100 | <dminuoso> | It's also a matter of tooling. Using HLS might influence your opinion. |
2022-02-04 10:32:17 +0100 | <dminuoso> | Since it might make whatever you prefer easier to do |
2022-02-04 10:32:22 +0100 | <c_wraith> | in which direction? :) |
2022-02-04 10:32:27 +0100 | <dminuoso> | Either the way I see it. |
2022-02-04 10:32:49 +0100 | <Graham31415> | Ok, thanks. I'll muddle through... |
2022-02-04 10:32:51 +0100 | <dminuoso> | It can make generating explicit export lists easier, as well as navigating and locating qualified imports easier. |
2022-02-04 10:32:58 +0100 | <dminuoso> | Or generating the latter as well. |
2022-02-04 10:33:18 +0100 | <dminuoso> | So if you have some reservations on either approach on account of "more cumbersome", HLS might address that. |
2022-02-04 10:34:01 +0100 | <c_wraith> | note that there's a fun case - you can name a module when you import it without importing it qualified. That seems... very narrow. |
2022-02-04 10:34:11 +0100 | ski | . o O ( HT libraries .. ) |
2022-02-04 10:34:21 +0100 | <c_wraith> | Yeah, I avoid those. :P |
2022-02-04 10:34:33 +0100 | <merijn> | Doesn't everyone? |
2022-02-04 10:34:56 +0100 | <c_wraith> | presumably not him! |
2022-02-04 10:35:12 +0100 | <dminuoso> | Graham31415: One important bit to note perhaps, that there's certainly some common idioms with respect to text, containers and bytestring. |
2022-02-04 10:35:21 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:c18f:7483:538b:1622) |
2022-02-04 10:35:34 +0100 | <ski> | it would be nice if Haddock would disambiguate with module qualification, when there's more than one identifier having the same name in scope, though |
2022-02-04 10:36:16 +0100 | <dminuoso> | So for bytestring its relatively common to do qualified imports `import qualified Data.ByteString as BS` and `import qualified Data.ByteString.Lazy as BSL` (the actual qualifier prefixes vary between folks, they are not the point), and then consistently use them to clearly communicate where lazy and strict BS code/types are used. |
2022-02-04 10:36:23 +0100 | <dminuoso> | For text you sometimes see a similar thing |
2022-02-04 10:36:41 +0100 | <Graham31415> | I must say, this stuff make Haskell hard to learn. All the supposedly scary stuff is well documented. |
2022-02-04 10:36:49 +0100 | <dminuoso> | containers enjoys similar usage because they introduce a lot of overlapping function names for IntSet, Set, Map, etc |
2022-02-04 10:36:55 +0100 | <c_wraith> | there's also that weird thing where you can import multiple modules and share a name between them. Sometimes that's really nice, like when you're able to put everything imported for a single purpose into the same namespace. Like parsers that split important logic across multiple modules. |
2022-02-04 10:37:50 +0100 | <ski> | hm, wasn't there some page that had some stats on how common it was to use `import'-`qualified'-`as' for various modules, and the most common renamings for the most common modules that were imported thus ? |
2022-02-04 10:38:05 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Remote host closed the connection) |
2022-02-04 10:38:07 +0100 | <dminuoso> | Mmm, yes someone in this channel did this research. |
2022-02-04 10:38:09 +0100 | <dminuoso> | Was this [exa]? |
2022-02-04 10:38:52 +0100 | jonathanx | (~jonathan@h-178-174-176-109.a357.priv.bahnhof.se) |
2022-02-04 10:39:28 +0100 | <ski> | > let xs = cycle [0,undefined]; xs = cycle [undefined,1] in xs |
2022-02-04 10:39:30 +0100 | <lambdabot> | error: |
2022-02-04 10:39:30 +0100 | <lambdabot> | Conflicting definitions for ‘xs’ |
2022-02-04 10:39:30 +0100 | <lambdabot> | Bound at: <interactive>:1:5-6 |
2022-02-04 10:39:37 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:c18f:7483:538b:1622) (Ping timeout: 240 seconds) |
2022-02-04 10:39:51 +0100 | <[exa]> | not me, but I recall seeing this question already here too |
2022-02-04 10:42:47 +0100 | ardell | (~ardell@user/ardell) |
2022-02-04 10:46:36 +0100 | ubert | (~Thunderbi@141.98.252.252) (Ping timeout: 250 seconds) |
2022-02-04 10:51:20 +0100 | mmhat | (~mmh@55d49d8b.access.ecotel.net) |
2022-02-04 10:52:43 +0100 | cfricke | (~cfricke@user/cfricke) (Quit: WeeChat 3.3) |
2022-02-04 10:58:41 +0100 | xff0x | (~xff0x@2001:1a81:5224:e000:4717:65df:57b3:7708) (Ping timeout: 256 seconds) |
2022-02-04 10:59:28 +0100 | xff0x | (~xff0x@2001:1a81:5224:e000:7446:150d:d8ae:ed12) |
2022-02-04 11:00:47 +0100 | akegalj | (~akegalj@18-45.dsl.iskon.hr) (Quit: leaving) |
2022-02-04 11:02:05 +0100 | dsrt^ | (~dsrt@128-092-185-170.biz.spectrum.com) (Ping timeout: 256 seconds) |
2022-02-04 11:03:08 +0100 | dsrt^ | (~dsrt@128-092-185-170.biz.spectrum.com) |
2022-02-04 11:06:37 +0100 | arjun | (~arjun@user/arjun) (Ping timeout: 256 seconds) |
2022-02-04 11:07:16 +0100 | ubert | (~Thunderbi@p200300ecdf0994a856831da0cd63cc4d.dip0.t-ipconnect.de) |
2022-02-04 11:07:39 +0100 | dsrt^ | (~dsrt@128-092-185-170.biz.spectrum.com) (Ping timeout: 256 seconds) |
2022-02-04 11:10:06 +0100 | dsrt^ | (~dsrt@128-092-185-170.biz.spectrum.com) |
2022-02-04 11:10:49 +0100 | arjun | (~arjun@103.57.87.28) |
2022-02-04 11:11:01 +0100 | MasseR4 | (~MasseR@51.15.143.128) (Quit: The Lounge - https://thelounge.chat) |
2022-02-04 11:11:38 +0100 | MasseR4 | (~MasseR@51.15.143.128) |
2022-02-04 11:13:57 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) (Quit: WeeChat 3.4) |
2022-02-04 11:14:15 +0100 | arjun | (~arjun@103.57.87.28) (Client Quit) |
2022-02-04 11:14:25 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) |
2022-02-04 11:17:03 +0100 | dsrt^ | (~dsrt@128-092-185-170.biz.spectrum.com) (Ping timeout: 256 seconds) |
2022-02-04 11:17:11 +0100 | rahulfromearth | (~rahulfrom@27.4.61.26) |
2022-02-04 11:18:25 +0100 | amk | (~amk@109.255.169.126) (Ping timeout: 256 seconds) |
2022-02-04 11:20:38 +0100 | amk | (~amk@109.255.169.126) |
2022-02-04 11:20:47 +0100 | waleee | (~waleee@2001:9b0:21d:fc00:398f:b003:b90d:acf4) |
2022-02-04 11:24:25 +0100 | rahulfromearth | (~rahulfrom@27.4.61.26) (Ping timeout: 256 seconds) |
2022-02-04 11:28:08 +0100 | vysn | (~vysn@user/vysn) |
2022-02-04 11:34:08 +0100 | cfricke | (~cfricke@user/cfricke) |
2022-02-04 11:34:11 +0100 | <lortabac> | I need to parse a couple of query parameters from a URL, right now I'm using network-uri, http-types and http-api-data |
2022-02-04 11:34:54 +0100 | <lortabac> | is there a higher-level package that composes the functionalities of those 3 packages? |
2022-02-04 11:41:11 +0100 | <[exa]> | dminuoso: but I cant find it. we might need to invoke tomsmeding's 1337 l0g 534rch 5ki11s |
2022-02-04 11:43:42 +0100 | haskellberryfinn | (~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) |
2022-02-04 11:43:43 +0100 | Merfont | (~Kaiepi@156.34.47.253) |
2022-02-04 11:47:02 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) (Quit: Leaving) |
2022-02-04 11:48:28 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) |
2022-02-04 11:49:14 +0100 | lavaman | (~lavaman@98.38.249.169) |
2022-02-04 11:50:52 +0100 | adnaahm | (~adnaahm@host-57-net-67-160-119.mobilinkinfinity.net.pk) (Read error: Connection reset by peer) |
2022-02-04 11:51:00 +0100 | adnaahm | (~adnaahm@51.89.118.136) |
2022-02-04 11:51:09 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) (Quit: WeeChat 3.4) |
2022-02-04 11:51:17 +0100 | haskellberryfinn | (~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Ping timeout: 256 seconds) |
2022-02-04 11:52:25 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) |
2022-02-04 11:52:29 +0100 | <dminuoso> | lortabac: servant-client-core exposes higher level primitives to bootstrap that yourself, depending on whether you like the dependency footprint |
2022-02-04 11:52:49 +0100 | <lortabac> | dminuoso: I already have a dependency on servant-client-core, so it's ok |
2022-02-04 11:54:00 +0100 | rando25892 | (~homefame@user/rando25892) |
2022-02-04 11:54:45 +0100 | Lord_of_Life_ | (~Lord@user/lord-of-life/x-2819915) |
2022-02-04 11:55:28 +0100 | <lortabac> | but the thing is, I'm not parsing an HTTP request, I just have a URL as a Text |
2022-02-04 11:55:49 +0100 | Lord_of_Life | (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 256 seconds) |
2022-02-04 11:56:03 +0100 | Lord_of_Life_ | Lord_of_Life |
2022-02-04 11:56:16 +0100 | __monty__ | (~toonn@user/toonn) |
2022-02-04 11:56:23 +0100 | <dminuoso> | Mmm |
2022-02-04 11:57:55 +0100 | ardell | (~ardell@user/ardell) (Quit: Konversation terminated!) |
2022-02-04 11:58:16 +0100 | <dminuoso> | Actually looking at it, you cant easily poke it out |
2022-02-04 11:58:21 +0100 | <dminuoso> | It all revolves around https://hackage.haskell.org/package/http-types-0.12.3/docs/Network-HTTP-Types.html#v:queryToQueryT… at the end |
2022-02-04 11:58:24 +0100 | wyrd | (~wyrd@gateway/tor-sasl/wyrd) (Ping timeout: 276 seconds) |
2022-02-04 11:58:57 +0100 | <dminuoso> | Sorry, I dont think this direction will help you unless you can make use of parseUrlPiece/parseUrlParam |
2022-02-04 12:00:11 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) (Quit: WeeChat 3.4) |
2022-02-04 12:02:23 +0100 | adnaahm | (~adnaahm@51.89.118.136) (Ping timeout: 256 seconds) |
2022-02-04 12:02:55 +0100 | adnaahm | (~adnaahm@host-57-net-67-160-119.mobilinkinfinity.net.pk) |
2022-02-04 12:03:35 +0100 | perrierjouet | (~perrier-j@modemcable012.251-130-66.mc.videotron.ca) |
2022-02-04 12:04:41 +0100 | cosimone | (~user@2001:b07:ae5:db26:c24a:d20:4d91:1e20) |
2022-02-04 12:05:33 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) (Ping timeout: 256 seconds) |
2022-02-04 12:06:48 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) |
2022-02-04 12:09:25 +0100 | <desantra> | Shouldn't it be fairly easy to write a parser to parse out query params from a url text? |
2022-02-04 12:10:00 +0100 | Graham31415 | (~Graham314@5.33.56.252) (Quit: Client closed) |
2022-02-04 12:11:58 +0100 | <lortabac> | desantra: yes it's easy, I was asking if it already exists |
2022-02-04 12:12:21 +0100 | jgeerds_ | (~jgeerds@55d4a547.access.ecotel.net) (Ping timeout: 256 seconds) |
2022-02-04 12:12:38 +0100 | <desantra> | lortabac: ah sure, well not that I know of |
2022-02-04 12:27:47 +0100 | DavidMilestone | (~DavidMile@182.64.8.212) |
2022-02-04 12:28:08 +0100 | Midjak | (~Midjak@may53-1-78-226-116-92.fbx.proxad.net) |
2022-02-04 12:30:05 +0100 | kojo5551 | (~kojo5551@fep.grid.pub.ro) (Quit: ZNC 1.6.4 - http://znc.in) |
2022-02-04 12:30:43 +0100 | cynomys | (~cynomys@user/cynomys) (Ping timeout: 256 seconds) |
2022-02-04 12:31:03 +0100 | pavonia | (~user@user/siracusa) (Quit: Bye!) |
2022-02-04 12:41:17 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) (Ping timeout: 240 seconds) |
2022-02-04 12:44:03 +0100 | jrm | (~jrm@156.34.173.250) (Quit: ciao) |
2022-02-04 12:45:27 +0100 | jrm | (~jrm@156.34.173.250) |
2022-02-04 12:47:26 +0100 | jakalx | (~jakalx@base.jakalx.net) () |
2022-02-04 12:47:35 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) |
2022-02-04 12:51:41 +0100 | Ariakenom | (~Ariakenom@h-82-196-111-63.NA.cust.bahnhof.se) (Ping timeout: 256 seconds) |
2022-02-04 12:51:49 +0100 | RFV | (~Thunderbi@139.red-88-12-223.dynamicip.rima-tde.net) |
2022-02-04 12:52:00 +0100 | Ariakenom | (~Ariakenom@2001:9b1:efe:9d00:ddca:91f7:7b50:e029) |
2022-02-04 12:54:40 +0100 | RFV1 | (~Thunderbi@139.red-88-12-223.dynamicip.rima-tde.net) |
2022-02-04 12:54:45 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 256 seconds) |
2022-02-04 12:55:49 +0100 | MoC | (~moc@user/moc) |
2022-02-04 12:57:27 +0100 | mbuf | (~Shakthi@122.174.58.23) (Quit: Leaving) |
2022-02-04 12:57:50 +0100 | miremeister | (uid387155@id-387155.uxbridge.irccloud.com) |
2022-02-04 12:58:29 +0100 | RFV | (~Thunderbi@139.red-88-12-223.dynamicip.rima-tde.net) (Ping timeout: 256 seconds) |
2022-02-04 12:58:29 +0100 | RFV1 | RFV |
2022-02-04 12:59:53 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) |
2022-02-04 13:01:26 +0100 | alx741 | (~alx741@157.100.197.240) |
2022-02-04 13:02:08 +0100 | Ariakenom_ | (~Ariakenom@h-82-196-111-63.NA.cust.bahnhof.se) |
2022-02-04 13:03:05 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 13:06:11 +0100 | Ariakenom | (~Ariakenom@2001:9b1:efe:9d00:ddca:91f7:7b50:e029) (Ping timeout: 256 seconds) |
2022-02-04 13:09:49 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 256 seconds) |
2022-02-04 13:10:02 +0100 | jrm | (~jrm@156.34.173.250) (Quit: ciao) |
2022-02-04 13:10:08 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) |
2022-02-04 13:11:22 +0100 | jrm | (~jrm@156.34.173.250) |
2022-02-04 13:12:57 +0100 | unyu | (~pyon@user/pyon) |
2022-02-04 13:16:15 +0100 | tavares | (~tavares@187.19.213.50) |
2022-02-04 13:16:26 +0100 | tavares | (~tavares@187.19.213.50) (Changing host) |
2022-02-04 13:16:26 +0100 | tavares | (~tavares@user/tavares) |
2022-02-04 13:18:37 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 240 seconds) |
2022-02-04 13:20:35 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) |
2022-02-04 13:20:55 +0100 | RFV | (~Thunderbi@139.red-88-12-223.dynamicip.rima-tde.net) (Ping timeout: 256 seconds) |
2022-02-04 13:22:47 +0100 | [itchyjunk] | (~itchyjunk@user/itchyjunk/x-7353470) |
2022-02-04 13:33:38 +0100 | phma | (phma@2001:5b0:210d:a008:2b93:5e3e:cefa:7af9) |
2022-02-04 13:36:11 +0100 | hendi | (sid489601@id-489601.lymington.irccloud.com) (Ping timeout: 245 seconds) |
2022-02-04 13:36:47 +0100 | xff0x | (~xff0x@2001:1a81:5224:e000:7446:150d:d8ae:ed12) (Ping timeout: 256 seconds) |
2022-02-04 13:37:21 +0100 | phma_ | (phma@2001:5b0:210d:a008:2b93:5e3e:cefa:7af9) (Ping timeout: 256 seconds) |
2022-02-04 13:37:50 +0100 | jakalx | (~jakalx@base.jakalx.net) |
2022-02-04 13:37:56 +0100 | rusrushal13 | (~rusrushal@2401:4900:30ba:6ed2:5f67:6972:1845:c7aa) |
2022-02-04 13:38:00 +0100 | hendi | (sid489601@id-489601.lymington.irccloud.com) |
2022-02-04 13:38:38 +0100 | rusrushal13 | (~rusrushal@2401:4900:30ba:6ed2:5f67:6972:1845:c7aa) (Client Quit) |
2022-02-04 13:39:00 +0100 | bitdex | (~bitdex@gateway/tor-sasl/bitdex) (Quit: = "") |
2022-02-04 13:46:19 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 256 seconds) |
2022-02-04 13:47:17 +0100 | whatsupdoc | (uid509081@id-509081.hampstead.irccloud.com) (Quit: Connection closed for inactivity) |
2022-02-04 13:47:23 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) |
2022-02-04 13:50:42 +0100 | alx741 | (~alx741@157.100.197.240) (Quit: alx741) |
2022-02-04 13:54:20 +0100 | jgeerds_ | (~jgeerds@55d4a547.access.ecotel.net) |
2022-02-04 13:56:03 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 256 seconds) |
2022-02-04 13:57:37 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) |
2022-02-04 13:59:07 +0100 | alx741 | (~alx741@157.100.197.240) |
2022-02-04 14:00:31 +0100 | jakalx | (~jakalx@base.jakalx.net) () |
2022-02-04 14:01:19 +0100 | jakalx | (~jakalx@base.jakalx.net) |
2022-02-04 14:05:02 +0100 | rusrushal13 | (~rusrushal@2409:4056:9:1708:2c2:74fb:7af9:78dc) |
2022-02-04 14:07:03 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) (Ping timeout: 256 seconds) |
2022-02-04 14:07:40 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) |
2022-02-04 14:09:01 +0100 | zaquest | (~notzaques@5.130.79.72) (Quit: Leaving) |
2022-02-04 14:11:33 +0100 | doxen | (~bbrahms@pool-173-54-217-168.nwrknj.fios.verizon.net) |
2022-02-04 14:11:59 +0100 | messier102 | (~messier10@user/messier102) |
2022-02-04 14:13:17 +0100 | sharky2 | (~bc8147f2@cerf.good1.com) (Quit: CGI:IRC (Session timeout)) |
2022-02-04 14:15:02 +0100 | absence_ | (torgeihe@hildring.pvv.ntnu.no) (Ping timeout: 240 seconds) |
2022-02-04 14:15:17 +0100 | Gurkenglas | (~Gurkengla@dslb-090-186-104-244.090.186.pools.vodafone-ip.de) (Ping timeout: 240 seconds) |
2022-02-04 14:19:46 +0100 | absence | (torgeihe@hildring.pvv.ntnu.no) |
2022-02-04 14:27:24 +0100 | xff0x | (~xff0x@2001:1a81:5224:e000:7446:150d:d8ae:ed12) |
2022-02-04 14:28:31 +0100 | doyougnu | (~doyougnu@cpe-67-249-83-190.twcny.res.rr.com) (Remote host closed the connection) |
2022-02-04 14:28:34 +0100 | CiaoSen | (~Jura@p200300c95737a2002a3a4dfffe84dbd5.dip0.t-ipconnect.de) |
2022-02-04 14:30:51 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Remote host closed the connection) |
2022-02-04 14:31:25 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 14:35:57 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Ping timeout: 240 seconds) |
2022-02-04 14:37:31 +0100 | Vajb | (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer) |
2022-02-04 14:38:00 +0100 | Vajb | (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) |
2022-02-04 14:40:41 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 14:41:36 +0100 | `2jt | (~jtomas@130.red-88-22-46.staticip.rima-tde.net) |
2022-02-04 14:41:57 +0100 | wmacmil | (~wmacmil@83-233-165-97.cust.bredband2.com) |
2022-02-04 14:42:13 +0100 | Vajb | (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer) |
2022-02-04 14:42:31 +0100 | Vajb | (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) |
2022-02-04 14:43:14 +0100 | <wmacmil> | ive recently updated to using cabal, however for just going back and looking at code in old files it gives me errors when i try to use dante like " It is a member of the hidden package ‘mtl-2.2.2’." |
2022-02-04 14:43:39 +0100 | <wmacmil> | is there any way i can just local install with cabal the necessary packages without having to refactor the entire directory with a cabal init |
2022-02-04 14:45:47 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Ping timeout: 250 seconds) |
2022-02-04 14:47:37 +0100 | jgeerds_ | (~jgeerds@55d4a547.access.ecotel.net) (Ping timeout: 256 seconds) |
2022-02-04 14:49:43 +0100 | slack1256 | (~slack1256@186.11.114.177) |
2022-02-04 14:52:29 +0100 | max22- | (~maxime@2a01cb0883359800f5b23c2351d98307.ipv6.abo.wanadoo.fr) (Ping timeout: 250 seconds) |
2022-02-04 14:52:31 +0100 | adnaahm | (~adnaahm@host-57-net-67-160-119.mobilinkinfinity.net.pk) (Read error: Connection reset by peer) |
2022-02-04 14:52:50 +0100 | doyougnu | (~doyougnu@cpe-67-249-83-190.twcny.res.rr.com) |
2022-02-04 14:53:01 +0100 | <dminuoso> | desantra: hah, "shouldnt it be fairly easy" |
2022-02-04 14:53:52 +0100 | acidsys | (~LSD@2.lsd.systems) (Excess Flood) |
2022-02-04 14:54:03 +0100 | <dminuoso> | How Ive grown to dislike that sentiment at the beginning of an undertaking. |
2022-02-04 14:54:21 +0100 | acidsys | (~LSD@2.lsd.systems) |
2022-02-04 14:54:29 +0100 | acidsys | (~LSD@2.lsd.systems) (Excess Flood) |
2022-02-04 14:55:05 +0100 | <lortabac> | dminuoso: in this case I have all the needed pieces, I just have to implement the glue |
2022-02-04 14:55:13 +0100 | acidsys | (~LSD@2.lsd.systems) |
2022-02-04 14:55:19 +0100 | Vajb | (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Ping timeout: 250 seconds) |
2022-02-04 14:55:40 +0100 | vpan | (~0@212.117.1.172) (Quit: Leaving.) |
2022-02-04 14:56:09 +0100 | zaquest | (~notzaques@5.130.79.72) |
2022-02-04 14:56:40 +0100 | <dminuoso> | Reminds me of how the past 2-3 weeks figuring out all the small little details when dealing with domain names. |
2022-02-04 14:58:37 +0100 | alp | (~alp@user/alp) (Ping timeout: 240 seconds) |
2022-02-04 14:58:51 +0100 | <lortabac> | yes, "it should be easy" can betray you in unexpected way :D |
2022-02-04 15:01:37 +0100 | <desantra> | well I was trying to think what you need to support in this case. Iirc there are only two valid forms for parameter queries which are ?boolQuery and ?query=... no? |
2022-02-04 15:02:23 +0100 | slac13852 | (~slack1256@191.126.227.202) |
2022-02-04 15:02:28 +0100 | hueso | (~root@user/hueso) (Quit: hueso) |
2022-02-04 15:02:30 +0100 | <dminuoso> | Now we need to talk about a) character sets, b) escaping characters, c) permisseable lengths, and d) semantics of duplicate query parameters. |
2022-02-04 15:02:40 +0100 | <dminuoso> | Those are the first 4 subtleties I can think of from the top off my head |
2022-02-04 15:02:46 +0100 | <dminuoso> | Further surprises are to be expected. |
2022-02-04 15:02:50 +0100 | shriekingnoise | (~shrieking@201.231.16.156) |
2022-02-04 15:03:17 +0100 | mon_aaraj | (~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 240 seconds) |
2022-02-04 15:03:48 +0100 | <desantra> | right... nvm |
2022-02-04 15:04:07 +0100 | DavidMilestone | (~DavidMile@182.64.8.212) () |
2022-02-04 15:04:27 +0100 | <dminuoso> | So the first thing to do is read the URI RFC, all updates on that, related RFCs, errata |
2022-02-04 15:04:39 +0100 | <dminuoso> | Just to know how to correctly do parsing here |
2022-02-04 15:04:51 +0100 | slack1256 | (~slack1256@186.11.114.177) (Ping timeout: 256 seconds) |
2022-02-04 15:04:59 +0100 | hueso | (~root@user/hueso) |
2022-02-04 15:05:16 +0100 | <dminuoso> | Perhaps its really simple, who knows - but having not read them I cant say |
2022-02-04 15:05:38 +0100 | mon_aaraj | (~MonAaraj@user/mon-aaraj/x-4416475) |
2022-02-04 15:06:18 +0100 | RFV | (~Thunderbi@139.red-88-12-223.dynamicip.rima-tde.net) |
2022-02-04 15:10:45 +0100 | bontaq | (~user@ool-45779fe5.dyn.optonline.net) |
2022-02-04 15:14:09 +0100 | RFV | (~Thunderbi@139.red-88-12-223.dynamicip.rima-tde.net) (Quit: RFV) |
2022-02-04 15:20:33 +0100 | vglfr | (~vglfr@coupling.penchant.volia.net) |
2022-02-04 15:21:19 +0100 | <messier102> | Hi all. I'm somewhat new to Haskell, but I've recently been interested in the "types as proofs" line of thought. I stumbled upon an idea of encoding arbitrary properties via ad-hoc type unions (e.g. `[a] & Sorted`), but couldn't find any prior discussion online. It seems like a pretty surface-level idea, so maybe I'm just looking in the wrong places. |
2022-02-04 15:21:37 +0100 | <messier102> | I wrote up a brief description of what I'm thinking of: https://gist.github.com/messier102/b7fef1387c9a66a26727f9ee0a3b5758 |
2022-02-04 15:21:57 +0100 | <messier102> | Has this been considered in the context of Haskell before? Would appreciate any pointers. |
2022-02-04 15:23:31 +0100 | <merijn> | messier102: Sounds like you wanna google "Liquid haskell" :) |
2022-02-04 15:23:34 +0100 | <dminuoso> | What you propose sounds rather analogue to a secondary/orthogonal type system |
2022-02-04 15:23:43 +0100 | <merijn> | Not quite what you're describing, but probably interesting to you |
2022-02-04 15:23:50 +0100 | <janus> | wmacmil: 'hidden package mtl' just means it is in your dep tree but not a direct dependency. it just means you need to add it to build-depends |
2022-02-04 15:24:02 +0100 | slack1256 | (~slack1256@186.11.24.3) |
2022-02-04 15:24:07 +0100 | ph88^ | (~ph88@ip5f5af71f.dynamic.kabel-deutschland.de) |
2022-02-04 15:24:20 +0100 | <dminuoso> | In some sense LH could be considered such a secondary/orthogonal type system I guess |
2022-02-04 15:24:25 +0100 | <merijn> | messier102: I've pondered and proposes something like what you said before, but then no one was interested in paying me to work on it, so it never went anywhere |
2022-02-04 15:24:37 +0100 | <janus> | wmacmil: it would be weird if dante and mtl had common modules, so are you sure that is really because of a symbol from dante? |
2022-02-04 15:24:43 +0100 | <desantra> | messier102: you probably want a dependently typed language like Idris. Haskell does not support dep types (yet) |
2022-02-04 15:24:48 +0100 | <dminuoso> | Disclaimer: ^- merijn would get rich but get no work done if he was getting paid for all his ideas. |
2022-02-04 15:25:07 +0100 | <merijn> | dminuoso: tbh, that's really only the one idea, though |
2022-02-04 15:25:11 +0100 | <messier102> | merijn, dminuoso: Thank you, I will check those keywords out. :) |
2022-02-04 15:25:18 +0100 | <merijn> | dminuoso: Also, joke's on you, I already don't get work done |
2022-02-04 15:25:39 +0100 | wroathe | (~wroathe@206-55-188-8.fttp.usinternet.com) |
2022-02-04 15:25:39 +0100 | wroathe | (~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host) |
2022-02-04 15:25:39 +0100 | wroathe | (~wroathe@user/wroathe) |
2022-02-04 15:25:44 +0100 | <dminuoso> | messier102: I dont think of them as "keywords", really nothing ever stops you from having a second type system. |
2022-02-04 15:25:54 +0100 | <dminuoso> | At least not in the traditional type theory sense. |
2022-02-04 15:26:17 +0100 | <merijn> | Incidentally, I wrote a paper arguing for that awhile ago |
2022-02-04 15:26:23 +0100 | slac13852 | (~slack1256@191.126.227.202) (Ping timeout: 256 seconds) |
2022-02-04 15:26:28 +0100 | <merijn> | "awhile" being, close to a decade now, lol |
2022-02-04 15:27:14 +0100 | adnaahm | (~adnaahm@host-57-net-67-160-119.mobilinkinfinity.net.pk) |
2022-02-04 15:27:15 +0100 | <merijn> | Granted, that was mostly "this is a great idea and here's why", not much "how do you make it work" :p |
2022-02-04 15:28:42 +0100 | slac91840 | (~slack1256@191.126.227.202) |
2022-02-04 15:28:42 +0100 | adnaahm | (~adnaahm@host-57-net-67-160-119.mobilinkinfinity.net.pk) (Read error: Connection reset by peer) |
2022-02-04 15:28:52 +0100 | <dminuoso> | I guess part of the problem of tying everything into a singular type system is that it drives up implementation complexity and it reduces diagnostics quality. Consider the kind of compiler errors you get from type rich libraries when doing something wrong. |
2022-02-04 15:28:56 +0100 | adnaahm | (~adnaahm@host-57-net-67-160-119.mobilinkinfinity.net.pk) |
2022-02-04 15:29:04 +0100 | <messier102> | merijn, it does seem like the implementation might get a bit hairy when it comes down to it. I'd be interested to read the paper you mentioned, is it possible for you to share it? |
2022-02-04 15:29:08 +0100 | <merijn> | dminuoso: That was essentially my argument |
2022-02-04 15:29:30 +0100 | <merijn> | You want to enforce some "non-functional" (strictness, memory consumption, multi-threading, etc.) properties |
2022-02-04 15:29:36 +0100 | <dminuoso> | So while you manage to encode some property into the type system, some kind of "you misused X in B" turns into "ambiguous type variable error here", "unable to satisfy constraint blahblahblah", "couldn't unify b0 with b0" |
2022-02-04 15:29:48 +0100 | <merijn> | Stuffing all these things into the "functional" type (i.e. what does this compute) turns both into a mess |
2022-02-04 15:30:10 +0100 | <merijn> | messier102: I mean, it contains basically 0 on "how would you actually do this" :D |
2022-02-04 15:30:40 +0100 | raehik | (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) |
2022-02-04 15:30:45 +0100 | <messier102> | merijn: I just want to hear the rationale :D It's probably more thought than I've given it so far |
2022-02-04 15:31:15 +0100 | slack1256 | (~slack1256@186.11.24.3) (Ping timeout: 256 seconds) |
2022-02-04 15:31:33 +0100 | <dminuoso> | messier102: well some of these orthogonal type systems exist. |
2022-02-04 15:31:36 +0100 | <dminuoso> | for instance the burrow checker in rust |
2022-02-04 15:32:11 +0100 | <merijn> | messier102: I think it's here https://oopsle.github.io/2014/abstracts.pdf but that's just, like, 2 pages of off-the-cuff brainstorming, essentially :) |
2022-02-04 15:32:46 +0100 | <dminuoso> | Oh. I guess that should read borrow checker. |
2022-02-04 15:33:09 +0100 | <merijn> | A burrow checker would be, like, a fox, weasel, or ferret :D |
2022-02-04 15:33:30 +0100 | <messier102> | merijn: thanks, I'll definitely check it out |
2022-02-04 15:33:39 +0100 | <[exa]> | pages of off-the-cuff brainstorming, essentially :) |
2022-02-04 15:33:54 +0100 | <[exa]> | ^ misclick with mid mouse, sorry |
2022-02-04 15:34:27 +0100 | <dminuoso> | Dont worry, the next time you'll be our official channel parrot. |
2022-02-04 15:35:04 +0100 | <[exa]> | I'll invest into colorful plumage |
2022-02-04 15:38:00 +0100 | max22- | (~maxime@2a01cb0883359800f5889d6f7a8326a9.ipv6.abo.wanadoo.fr) |
2022-02-04 15:38:31 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) (Ping timeout: 256 seconds) |
2022-02-04 15:40:05 +0100 | CHUD | (~CHUD@dhcp6531.kent.ac.uk) |
2022-02-04 15:40:38 +0100 | kaph | (~kaph@net-2-47-208-144.cust.vodafonedsl.it) |
2022-02-04 15:41:25 +0100 | segfaultfizzbuzz | (~rustisafu@2602:306:cd3c:9350:cc4:c954:b25:db0a) |
2022-02-04 15:45:15 +0100 | ph88^ | (~ph88@ip5f5af71f.dynamic.kabel-deutschland.de) (Quit: Leaving) |
2022-02-04 15:46:07 +0100 | <ski> | messier102 : hm, is that `[a] & Sorted' supposed to be like an intersection type (rather than a union type, as you mentioned) ? you could also compare with LiquidHaskell, i think (where you'd say something like `{xs : [a] | sorted xs}') |
2022-02-04 15:46:15 +0100 | <ski> | oh, LiquidHaskell was mentioned |
2022-02-04 15:46:41 +0100 | <messier102> | ski: sorry, I might've meant intersection type, yes |
2022-02-04 15:47:10 +0100 | <messier102> | always conflate those two |
2022-02-04 15:47:35 +0100 | jonathanx | (~jonathan@h-178-174-176-109.a357.priv.bahnhof.se) (Remote host closed the connection) |
2022-02-04 15:47:52 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) |
2022-02-04 15:52:06 +0100 | <messier102> | LiquidHaskell seems interesting, although perhaps not entirely what I was thinking of |
2022-02-04 15:52:26 +0100 | <segfaultfizzbuzz> | i am doing a double take on something which popped up on reddit. https://www.reddit.com/r/haskell/comments/skcir6/what_is_wholesale_or_monolithic_update/ these folks are saying: "persistent arrays need to be copied completely even for changes to a single element." -- really...?? |
2022-02-04 15:52:47 +0100 | <segfaultfizzbuzz> | i thought you folks had the ST monad to encapsulate mutation or something to that effect |
2022-02-04 15:53:32 +0100 | razetime | (~quassel@49.207.209.26) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) |
2022-02-04 15:53:39 +0100 | <ski> | sure, but those are ephemeral (mutable) arrays, not persistent (immutable) ones |
2022-02-04 15:53:43 +0100 | <ski> | we have both |
2022-02-04 15:54:20 +0100 | <ski> | oh, and we can do bulk updates on persistent, so it's not quite as bad as copy for each single change |
2022-02-04 15:54:43 +0100 | ski | . o O ( `DiffArray' ) |
2022-02-04 15:56:14 +0100 | <segfaultfizzbuzz> | lol the C++ comment operator |
2022-02-04 15:56:31 +0100 | <ski> | "One of the main differences between functional and procedural algorithms is that the former rely on lists as the basic carrier of information while the latter rely on arrays." -- seems a bit too simplistic, both to "functional" and to "procedural" |
2022-02-04 15:56:36 +0100 | <segfaultfizzbuzz> | When the // operator is applied to a diff array, its contents are physically updated in place. lol |
2022-02-04 15:56:55 +0100 | <ski> | @type (//) |
2022-02-04 15:56:56 +0100 | <lambdabot> | Ix i => Array i e -> [(i, e)] -> Array i e |
2022-02-04 15:57:20 +0100 | <segfaultfizzbuzz> | yeah i don't think the list comment is accurate but it is idiomatic for haskell entry level documentation iiuc |
2022-02-04 15:58:38 +0100 | <ski> | "wholesale or monolithic update" means that we update all elements, or at least many of them, in one go, one fell swoop |
2022-02-04 15:59:14 +0100 | <ski> | (the former is mapping over an array. the latter is `(//)') |
2022-02-04 15:59:31 +0100 | <segfaultfizzbuzz> | there may as well be a /* and */ operator in there ;-) |
2022-02-04 16:00:03 +0100 | waleee | (~waleee@2001:9b0:21d:fc00:398f:b003:b90d:acf4) (Quit: WeeChat 3.4) |
2022-02-04 16:00:26 +0100 | romesrf | (~romes@bl8-111-202.dsl.telepac.pt) |
2022-02-04 16:00:30 +0100 | <romesrf> | o/ |
2022-02-04 16:01:54 +0100 | <ski> | "Does library Data . Array provide mutable or immutable arrays?" -- `Data.Array' itself provides immutable arrays, but there's several modules with `Data.Array.' as prefix which provides (different kinds of) mutable arrays |
2022-02-04 16:03:05 +0100 | <ski> | "Is a data structure with \"wholesale or monolithic update\" a mutable or immutable one?" -- the main need for having those is for immutable, but mutable ones could also support such operations, for convenience |
2022-02-04 16:04:21 +0100 | <ski> | segfaultfizzbuzz : does this help ? |
2022-02-04 16:06:16 +0100 | <segfaultfizzbuzz> | actually more fundamentally i should probably understand, |
2022-02-04 16:06:21 +0100 | slack1256 | (~slack1256@186.11.31.131) |
2022-02-04 16:06:58 +0100 | phma_ | (phma@2001:5b0:211f:7008:1fdf:50b9:29f4:b115) |
2022-02-04 16:06:59 +0100 | <segfaultfizzbuzz> | it seems like in "many/most" circumstances updates should be in-place |
2022-02-04 16:07:19 +0100 | <segfaultfizzbuzz> | there is something about laziness which seems to require allocation...? |
2022-02-04 16:07:44 +0100 | <merijn> | segfaultfizzbuzz: Why should the be in place in most circumstances? |
2022-02-04 16:07:48 +0100 | <ski> | which flavor of array are you speaking of ? |
2022-02-04 16:07:49 +0100 | phma | (phma@2001:5b0:210d:a008:2b93:5e3e:cefa:7af9) (Read error: Connection reset by peer) |
2022-02-04 16:08:53 +0100 | slac91840 | (~slack1256@191.126.227.202) (Ping timeout: 256 seconds) |
2022-02-04 16:08:54 +0100 | <segfaultfizzbuzz> | so as an amateur it seems like "essentially everything" should be linear/affine, much as in rust |
2022-02-04 16:09:17 +0100 | <segfaultfizzbuzz> | and i can't understand in what circumstances something other than that would be necessary, which seems to connect to when laziness is necessary |
2022-02-04 16:10:13 +0100 | phma_ | phma |
2022-02-04 16:10:41 +0100 | <merijn> | segfaultfizzbuzz: Laziness is mostly irrelevant here? |
2022-02-04 16:11:08 +0100 | <merijn> | segfaultfizzbuzz: The point is that you can't know when things are safe to mutate in place in regular Haskell |
2022-02-04 16:11:20 +0100 | <merijn> | Because you can't tell when your reference is the only one |
2022-02-04 16:11:28 +0100 | miremeister | (uid387155@id-387155.uxbridge.irccloud.com) (Quit: Connection closed for inactivity) |
2022-02-04 16:12:03 +0100 | <segfaultfizzbuzz> | my limited understanding is that the primary reason that i would use haskell is to benefit from laziness/non-strictness as a first class citizen/primary emphasis/default assumption |
2022-02-04 16:12:20 +0100 | <segfaultfizzbuzz> | but i don't feel confident understanding when i would need to use laziness and when/how i would benefit |
2022-02-04 16:12:51 +0100 | wroathe | (~wroathe@user/wroathe) (Ping timeout: 256 seconds) |
2022-02-04 16:12:55 +0100 | <segfaultfizzbuzz> | merijn: ahh |
2022-02-04 16:13:25 +0100 | <merijn> | Rust is requiring some heavy duty machinery in the borrow checker to check that kinda thing |
2022-02-04 16:13:56 +0100 | lortabac | (~lortabac@2a01:e0a:541:b8f0:56b3:2a4c:af18:8385) (Quit: WeeChat 2.8) |
2022-02-04 16:15:06 +0100 | <WhateverRabbit> | you can't do guarded recursion without laziness. every map over a list/tree/array/whatever gives you some benefit |
2022-02-04 16:16:08 +0100 | <segfaultfizzbuzz> | "guarded" recursion ? |
2022-02-04 16:16:18 +0100 | <segfaultfizzbuzz> | the definition i'm finding on ncatlab isn't illuminating |
2022-02-04 16:19:05 +0100 | zebrag | (~chris@user/zebrag) |
2022-02-04 16:19:09 +0100 | wroathe | (~wroathe@206-55-188-8.fttp.usinternet.com) |
2022-02-04 16:19:09 +0100 | wroathe | (~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host) |
2022-02-04 16:19:09 +0100 | wroathe | (~wroathe@user/wroathe) |
2022-02-04 16:19:52 +0100 | Pickchea | (~private@user/pickchea) |
2022-02-04 16:20:11 +0100 | <ski> | WhateverRabbit : you can express it, more or less manually, in a strict language, given lazy suspensions (and, in addition to `force' and `delay' operations, also a `lazy' operation, commonly used to delay a choice of suspensions/thunks) |
2022-02-04 16:21:52 +0100 | <WhateverRabbit> | map f (x:xs) = f x : map f xs -- here you create a list instance with two thunks - f x and map f xs. map f xs doesn't evaluate nothing untill you don't read something from tail of f x : map f xs list instace |
2022-02-04 16:22:09 +0100 | doxen | (~bbrahms@pool-173-54-217-168.nwrknj.fios.verizon.net) (Ping timeout: 256 seconds) |
2022-02-04 16:22:14 +0100 | <ski> | "How to add laziness to a strict language, without even being odd" by Philip Wadler,Walid Taha,David MacQueen in 1998-09 at <https://homepages.inf.ed.ac.uk/wadler/topics/language-design.html#lazyinstrict> ; "Primitives for Expressing Iterative Lazy Algorithms" by André van Tonder in 2003-09-20 - 2004-08-04 at <https://srfi.schemers.org/srfi-45/srfi-45.html> |
2022-02-04 16:22:20 +0100 | <WhateverRabbit> | sorry for my bad english |
2022-02-04 16:23:57 +0100 | wroathe | (~wroathe@user/wroathe) (Ping timeout: 256 seconds) |
2022-02-04 16:24:04 +0100 | slac13545 | (~slack1256@191.125.227.202) |
2022-02-04 16:25:16 +0100 | <segfaultfizzbuzz> | brb |
2022-02-04 16:25:18 +0100 | jao | (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) |
2022-02-04 16:25:22 +0100 | segfaultfizzbuzz | (~rustisafu@2602:306:cd3c:9350:cc4:c954:b25:db0a) (Quit: Leaving) |
2022-02-04 16:25:36 +0100 | <ski> | itym "map f xs doesn't evaluate until you read something from the tail of f x : map f xs list instance" |
2022-02-04 16:25:46 +0100 | <romesrf> | hey everyone, after automatically deriving MonadReader for a newtype, how can I ask for the environment? |
2022-02-04 16:25:58 +0100 | <ski> | just ask |
2022-02-04 16:26:00 +0100 | <ski> | @type ask |
2022-02-04 16:26:01 +0100 | <lambdabot> | MonadReader r m => m r |
2022-02-04 16:26:13 +0100 | <romesrf> | :) i think something isn't working hahahah |
2022-02-04 16:26:24 +0100 | <ski> | @type asks |
2022-02-04 16:26:24 +0100 | alp | (~alp@user/alp) |
2022-02-04 16:26:25 +0100 | <lambdabot> | MonadReader r m => (r -> a) -> m a |
2022-02-04 16:26:27 +0100 | slack1256 | (~slack1256@186.11.31.131) (Ping timeout: 256 seconds) |
2022-02-04 16:26:53 +0100 | n3rdy1 | (~n3rdy1@2600:1700:4570:3480::41) |
2022-02-04 16:26:56 +0100 | <romesrf> | :+1: that's what I was expecting, but instead I get couldn't match ReaderT with ohhhh i understand my mistake now :) |
2022-02-04 16:27:06 +0100 | <romesrf> | i'm probably importing the wrong ask |
2022-02-04 16:28:07 +0100 | <romesrf> | that was it thank you, ahahahah |
2022-02-04 16:28:59 +0100 | <ski> | oic, np |
2022-02-04 16:32:30 +0100 | <jkaye[m]> | I would not agree with that understanding |
2022-02-04 16:32:43 +0100 | <jkaye[m]> | Laziness is nice, but I don't think it's Haskell's primary benefit |
2022-02-04 16:32:44 +0100 | <jkaye[m]> | There are many people who would love a strict-by-default Haskell (no comment on whether that's "good" or not) |
2022-02-04 16:35:07 +0100 | <ski> | laziness can help with modularity |
2022-02-04 16:38:35 +0100 | mon_aaraj | (~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 256 seconds) |
2022-02-04 16:39:27 +0100 | <jkaye[m]> | WhateverRabbit: not sure what you mean by that |
2022-02-04 16:40:04 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:c18f:7483:538b:1622) |
2022-02-04 16:40:16 +0100 | CHUD | (~CHUD@dhcp6531.kent.ac.uk) (Remote host closed the connection) |
2022-02-04 16:41:47 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) |
2022-02-04 16:43:56 +0100 | Vajb | (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) |
2022-02-04 16:44:55 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:c18f:7483:538b:1622) (Ping timeout: 256 seconds) |
2022-02-04 16:44:57 +0100 | jao | (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Ping timeout: 240 seconds) |
2022-02-04 16:47:36 +0100 | <jkaye[m]> | Why do you think that can't be done strictly? You can even do it strictly in GHC using extensions. It does change the semantics of the function of course |
2022-02-04 16:47:47 +0100 | Sgeo | (~Sgeo@user/sgeo) |
2022-02-04 16:52:03 +0100 | lavaman | (~lavaman@98.38.249.169) (Remote host closed the connection) |
2022-02-04 16:56:25 +0100 | CHUD | (~CHUD@edu791A.kent.ac.uk) |
2022-02-04 16:57:00 +0100 | <CHUD> | what does this function do? f x = if even (x + 1) then x + 1 else f (x - 1), like how does it evaluate? |
2022-02-04 16:58:01 +0100 | <CHUD> | I tested it, f 2 returns 2 and f 3 returns 4 |
2022-02-04 16:58:10 +0100 | <opqdonut> | first the condition of the if gets evaluated, and based on that either the then or else gets evaluated |
2022-02-04 16:58:26 +0100 | <opqdonut> | you can just plug in the values and do it by hand |
2022-02-04 16:58:42 +0100 | <CHUD> | if it's an even number then what happens to (x+1) that's straight after it? |
2022-02-04 16:58:57 +0100 | segfaultfizzbuzz | (~rustisafu@2602:306:cd3c:9350:7513:3c16:cd2c:7377) |
2022-02-04 16:59:01 +0100 | <CHUD> | if even (x+1) |
2022-02-04 16:59:16 +0100 | <opqdonut> | you can just plug in the values and do it by hand |
2022-02-04 16:59:39 +0100 | <CHUD> | I don't understand how the if then else statement works |
2022-02-04 16:59:40 +0100 | <opqdonut> | f 3 ==> if even (3+1) then 3+1 else f (3-1) ==> if True then 3+1 else f (3-1) ==> 3+1 ==> 4 |
2022-02-04 16:59:50 +0100 | <opqdonut> | it's not a statement, it's an expression |
2022-02-04 16:59:57 +0100 | <opqdonut> | it has a value |
2022-02-04 17:00:11 +0100 | <opqdonut> | it's pretty similar to the ?: operator in C/Java/JavaScript |
2022-02-04 17:00:22 +0100 | <merijn> | I'd even say identical :p |
2022-02-04 17:00:50 +0100 | <opqdonut> | in JS you'd write something like: f = x => even(x+1) ? (x+1) : f(x-1) |
2022-02-04 17:01:05 +0100 | <CHUD> | I don't know any other languages |
2022-02-04 17:01:16 +0100 | <CHUD> | opqdonut: thank you |
2022-02-04 17:01:27 +0100 | <opqdonut> | interesting, why did you call it an if _statement_ if you don't know any other languages? |
2022-02-04 17:01:47 +0100 | <ski> | if True then x else y = x |
2022-02-04 17:01:47 +0100 | <CHUD> | it's from Haskell MOOC I just read it online |
2022-02-04 17:01:48 +0100 | <ski> | if False then x else y = y |
2022-02-04 17:02:04 +0100 | <ski> | can be regarded as defining equations for `if'-`then'-`else' |
2022-02-04 17:02:19 +0100 | <opqdonut> | CHUD: you mean this? https://haskell.mooc.fi/part1#how-do-i-get-anything-done |
2022-02-04 17:02:25 +0100 | <CHUD> | yes |
2022-02-04 17:02:26 +0100 | <ski> | CHUD : sounds like that is bad, at least in that regard, in that case |
2022-02-04 17:02:28 +0100 | <opqdonut> | it says pretty much what I just told you |
2022-02-04 17:02:35 +0100 | <opqdonut> | I should know, I wrote that mooc :P |
2022-02-04 17:03:06 +0100 | <ski> | ah, it doesn't say anything about "statements" in Haskell |
2022-02-04 17:03:58 +0100 | <ski> | "In other languages, `if' is a statement. It doesn’t have a value, it just conditionally executes other statements.","In Haskell, `if' is an expression. It has a value. It selects between two other expressions. It corresponds to the `?:' operator in C or Java." |
2022-02-04 17:04:12 +0100 | <opqdonut> | CHUD: anyway, haskell's if-then-else lets you select between two values (or expressions, if you want to be pedantic) |
2022-02-04 17:05:36 +0100 | <opqdonut> | it's kind of like english |
2022-02-04 17:05:57 +0100 | <opqdonut> | "what's the color? well, if the fruit is an apple, green, otherwise red" |
2022-02-04 17:06:11 +0100 | <ski> | CHUD : to evaluate an `if'-`then'-`else' (aka a conditional) expression, `if <condition> then <consequent> else <alternate>', you evaluate the condition. if it's `True', then the result of evaluating the `if'-`then'-`else' will be the result of evaluating the consequent expression. otherwise (i.e. if the condition is `False'), it will be the result of evaluating the alternate expression |
2022-02-04 17:06:43 +0100 | <ski> | if isApple myFruit then green else red |
2022-02-04 17:07:10 +0100 | <CHUD> | so it doesn't evaluate if the x input is even it checks if (x+1) is even? |
2022-02-04 17:07:23 +0100 | <messier102> | all red apples in the world shook in terror |
2022-02-04 17:07:36 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 17:07:39 +0100 | <ski> | CHUD : yes |
2022-02-04 17:07:45 +0100 | <opqdonut> | CHUD: yes, the code is writte `if even (x+1) then ...`, not `if even x then ...` |
2022-02-04 17:08:32 +0100 | <ski> | either the `then' branch (consequent) or the `else' branch (alternate) will be chosen, depending on the value of the condition |
2022-02-04 17:08:46 +0100 | <CHUD> | alright, thank you |
2022-02-04 17:09:01 +0100 | <ski> | so, it's a way to express choice, choosing between two alternatives, depending on the outcome of checking a condition |
2022-02-04 17:12:07 +0100 | <messier102> | CHUD: are you learning Haskell as your first programming language? If so, what made you choose it? |
2022-02-04 17:13:15 +0100 | <CHUD> | I just found it on mooc.fi and picked it, there was little thought, I'm also working through part 1 of the java cource |
2022-02-04 17:13:31 +0100 | <messier102> | I see, interesting |
2022-02-04 17:13:49 +0100 | <CHUD> | Java is just to supplement my university course |
2022-02-04 17:13:53 +0100 | <geekosaur> | two at once seems like a good way to confuse yourself, though |
2022-02-04 17:14:17 +0100 | n3rdy1 | (~n3rdy1@2600:1700:4570:3480::41) (Ping timeout: 240 seconds) |
2022-02-04 17:14:17 +0100 | <CHUD> | Haskell isn't a top priority, just doing it on the side |
2022-02-04 17:15:19 +0100 | <CHUD> | I have my functional programming module starting in a couple of months |
2022-02-04 17:15:56 +0100 | gaff | (~gaff@49.207.198.16) |
2022-02-04 17:16:21 +0100 | <messier102> | What are you majoring in, if you don't mind me asking? |
2022-02-04 17:16:24 +0100 | <ski> | nice |
2022-02-04 17:16:33 +0100 | <CHUD> | computer science |
2022-02-04 17:16:43 +0100 | <gaff> | is there a way to create the binary literal 0b11110000, say? |
2022-02-04 17:17:13 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 256 seconds) |
2022-02-04 17:17:16 +0100 | <geekosaur> | gaff, ghc 9.x supports that directly |
2022-02-04 17:17:24 +0100 | <int-e> | There's {-# LANGUAGE BinaryLiterals #-} |
2022-02-04 17:17:24 +0100 | <gaff> | i see |
2022-02-04 17:17:53 +0100 | waleee | (~waleee@2001:9b0:21d:fc00:398f:b003:b90d:acf4) |
2022-02-04 17:17:58 +0100 | <int-e> | ah does ghc 9.x enable that by default now... |
2022-02-04 17:19:05 +0100 | <gaff> | geekosaur: yeah, i saw the language extension, i can type it in GHCi, but i was wondering how the code can generate it. |
2022-02-04 17:19:13 +0100 | <int-e> | 9.2 does, 9.0 doesn't |
2022-02-04 17:19:20 +0100 | <gaff> | i see |
2022-02-04 17:19:36 +0100 | <ski> | "generate"/"create" meaning ? |
2022-02-04 17:20:57 +0100 | <int-e> | In any case the extension has been there for a long time. (8.0.2 has it, that's the oldest version I have here, but I expect it has been there for much longer) |
2022-02-04 17:22:38 +0100 | lavaman | (~lavaman@98.38.249.169) |
2022-02-04 17:25:08 +0100 | <gaff> | yeah, i use 8.10.4, and it has that extension, but not much more |
2022-02-04 17:25:49 +0100 | <gaff> | ski: yeah, how can a function for example return a binary literal? |
2022-02-04 17:26:27 +0100 | <c_wraith> | gaff: binary literals only exist in source |
2022-02-04 17:26:29 +0100 | <gaff> | not possible in 8.10.4 |
2022-02-04 17:26:47 +0100 | <c_wraith> | gaff: as far as a function is concerned, they're just a number |
2022-02-04 17:26:49 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:c18f:7483:538b:1622) |
2022-02-04 17:27:09 +0100 | n3rdy1 | (~n3rdy1@2600:1700:4570:3480:1b88:50f:dae0:9293) |
2022-02-04 17:27:25 +0100 | lavaman | (~lavaman@98.38.249.169) (Ping timeout: 256 seconds) |
2022-02-04 17:27:47 +0100 | <ski> | gaff : .. just do it ? |
2022-02-04 17:28:11 +0100 | <ski> | % let f x = (x,0b11110000) in f 2 |
2022-02-04 17:28:11 +0100 | <yahb> | ski: (2,240) |
2022-02-04 17:28:16 +0100 | <ski> | seems to work fine, to me |
2022-02-04 17:28:24 +0100 | shapr | (~user@pool-173-73-44-186.washdc.fios.verizon.net) |
2022-02-04 17:28:32 +0100 | <geekosaur> | gaff, the computers we use all use binary internally. how you enter or display a number has no relationship to how the computer stores it or works with it |
2022-02-04 17:29:07 +0100 | <gaff> | geekosaur: yes |
2022-02-04 17:29:15 +0100 | <geekosaur> | and even the binary representation is mostly an invisible detail unless you start to use bit operations on them |
2022-02-04 17:29:27 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Remote host closed the connection) |
2022-02-04 17:29:29 +0100 | <gaff> | correct |
2022-02-04 17:29:53 +0100 | <opqdonut> | > Numeric.showBin 240 "" |
2022-02-04 17:29:55 +0100 | <lambdabot> | error: |
2022-02-04 17:29:55 +0100 | <lambdabot> | Not in scope: ‘Numeric.showBin’ |
2022-02-04 17:29:55 +0100 | <lambdabot> | Perhaps you meant one of these: |
2022-02-04 17:30:13 +0100 | <ski> | % (showString "0b" . showIntAtBase 2 intToDigit 0b11110000) "" |
2022-02-04 17:30:13 +0100 | <yahb> | ski: "0b11110000" |
2022-02-04 17:30:18 +0100 | <ski> | % (showString "0b" . showIntAtBase 2 intToDigit 240) "" |
2022-02-04 17:30:18 +0100 | <yahb> | ski: "0b11110000" |
2022-02-04 17:30:35 +0100 | <opqdonut> | yeah |
2022-02-04 17:30:57 +0100 | <geekosaur> | I think yahb has showBin |
2022-02-04 17:31:12 +0100 | <geekosaur> | % Numeric.showBin 240 "" |
2022-02-04 17:31:13 +0100 | <yahb> | geekosaur: ; <interactive>:40:1: error:; Not in scope: `Numeric.showBin'; Perhaps you meant one of these: `Numeric.showHex' (imported from Numeric), `Numeric.showInt' (imported from Numeric), `Numeric.showOct' (imported from Numeric) |
2022-02-04 17:31:19 +0100 | <geekosaur> | guess not |
2022-02-04 17:31:20 +0100 | <gaff> | yeah, but that is a string, now how do i get that into a binary literal? |
2022-02-04 17:31:31 +0100 | <opqdonut> | I guess Numeric.showBin is too new to be on any of the bots |
2022-02-04 17:31:39 +0100 | <messier102> | gaff: what do you mean by a literal, exactly? |
2022-02-04 17:31:44 +0100 | <ski> | gaff : no, question makes no sense |
2022-02-04 17:32:06 +0100 | <gaff> | sorry, i am a bit confused |
2022-02-04 17:32:23 +0100 | <gaff> | literal: 123 |
2022-02-04 17:32:27 +0100 | <opqdonut> | you _could_ define your own `newtype Bin = Bin Int` with a `Show` instance that prints it as 0b101010 |
2022-02-04 17:32:38 +0100 | <opqdonut> | maybe that's what you're after? |
2022-02-04 17:32:47 +0100 | <ski> | literals are things that appear in text. e.g. in source code, or in the `String's produced by `Show' (or the ones consumed by `Read') |
2022-02-04 17:33:09 +0100 | cosimone | (~user@2001:b07:ae5:db26:c24a:d20:4d91:1e20) (Read error: Connection reset by peer) |
2022-02-04 17:33:33 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) (Ping timeout: 256 seconds) |
2022-02-04 17:33:46 +0100 | cosimone | (~user@2001:b07:ae5:db26:c24a:d20:4d91:1e20) |
2022-02-04 17:34:13 +0100 | <ski> | literals are converted to values (and the other way around), when going from source (or `String') (repsectively when using `Read'). so a function can't possibly "return a literal", except in the sense that it may return some text, which involves a literal |
2022-02-04 17:34:13 +0100 | <romesrf> | how would i do mapConcurrently but over a MonadIO m => t m a rather than IO a? I was looking at monadUnliftIO but i'm unsure |
2022-02-04 17:34:22 +0100 | <ski> | a number is a number, not a literal |
2022-02-04 17:34:25 +0100 | <gaff> | ok, here is my problem. i want to distinguish binary number from a decimal in calculations. now the problem is that we have numbers such as 1100 that can go both ways, so i need a representation for binary to make the cut clear. |
2022-02-04 17:34:48 +0100 | <c_wraith> | gaff: numbers aren't binary or decimal. those are details about the *representation* of a number. |
2022-02-04 17:34:52 +0100 | <ski> | gaff : you should normally not think of numbers in calculations as being in any base whatsoever |
2022-02-04 17:35:01 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 17:35:12 +0100 | <Hecate> | shapr: a cookie is a header |
2022-02-04 17:35:18 +0100 | <gaff> | ski: i am doing stuff with bits etc |
2022-02-04 17:35:19 +0100 | <Hecate> | ugh |
2022-02-04 17:35:24 +0100 | <ski> | what stuff ? |
2022-02-04 17:35:26 +0100 | <Hecate> | shapr: please disregard this message |
2022-02-04 17:35:31 +0100 | <gaff> | like conversions |
2022-02-04 17:35:38 +0100 | <ski> | meaning ? |
2022-02-04 17:35:57 +0100 | <c_wraith> | romesrf: a typical MonadIO instance will carry additional contents that have no obvious way to fork. |
2022-02-04 17:36:03 +0100 | <gaff> | converting binary numbers to decimals, decimals to a list of bits, etc |
2022-02-04 17:36:27 +0100 | <romesrf> | c_wraith: i see! :) makes sense |
2022-02-04 17:36:39 +0100 | <ski> | there aren't really such a thing as binary *numbers*. there are binary *numerals*/*literals* |
2022-02-04 17:36:54 +0100 | <gaff> | sorry, binary literals |
2022-02-04 17:36:55 +0100 | <messier102> | gaff: it sounds to me like you want to convert between different textual representations of a number (so, Strings) |
2022-02-04 17:36:56 +0100 | <ski> | numbers are numbers, they are neither binary, nor decimal, not of any other base |
2022-02-04 17:37:32 +0100 | <c_wraith> | romesrf: like, say you're working in 'StateT Foo IO Bar' - It's not too bad to decide each concurrent call gets the same initial state, but what do you do with all the different result states? |
2022-02-04 17:37:34 +0100 | <gaff> | so if i say to you 1100, what does it mean? |
2022-02-04 17:37:48 +0100 | <ski> | is that supposed to be a `String' ? |
2022-02-04 17:37:51 +0100 | <messier102> | gaff: I don't know, what's the base? |
2022-02-04 17:37:52 +0100 | <gaff> | no |
2022-02-04 17:37:56 +0100 | <gaff> | literal |
2022-02-04 17:38:11 +0100 | <ski> | so, it is some kind of text, then ? |
2022-02-04 17:38:11 +0100 | <geekosaur> | I could imagine a numeric type which carried along with it a preferred base representation. the complication then becomes what happens if you multiply (10 @10) * (6 @8), which base is the result? |
2022-02-04 17:38:12 +0100 | <opqdonut> | if you tell GHC 1100 it will mean 1100 in base ten, that is, one thousand and one hundred |
2022-02-04 17:38:14 +0100 | <CHUD> | I get this error when I try to run the Set1Test.hs Mooc/Test.hs:19:1: error: Could not find module ‘Test.QuickCheck’ Use -v (or `:set -v` in ghci) to see a list of the files searched for. | 19 | import Test.QuickCheck | ^^^^^^^^^^^^^^^^^^^^^^ Mooc/Test.hs:20:1: error: Could not find module ‘Test.QuickCheck.Monadic’ Use -v (or `:set -v` in ghci) to see a list of the files searched for. | 20 | import Test.QuickCheck.Monadic |
2022-02-04 17:38:20 +0100 | <ski> | appearing in Haskell source, or what ? program input ? |
2022-02-04 17:38:37 +0100 | <ski> | we need to know the context in which it appears, to be able to tell |
2022-02-04 17:38:39 +0100 | <CHUD> | It's when I run the command from a terminal in vs code |
2022-02-04 17:38:42 +0100 | <gaff> | can appear in haskell source |
2022-02-04 17:38:43 +0100 | <opqdonut> | CHUD: did you run `stack build`? |
2022-02-04 17:38:47 +0100 | <CHUD> | Yes |
2022-02-04 17:38:58 +0100 | <c_wraith> | romesrf: this is the reason forkIO (and things based on it, like mapConcurrently) only work in IO. Everything else has more rules, and it isn't obvious what those rules should be |
2022-02-04 17:39:27 +0100 | <romesrf> | c_wraith: that's insightful, thank you |
2022-02-04 17:39:28 +0100 | <opqdonut> | CHUD: and you're running the tests with `stack runhaskell Set1Test.hs`? |
2022-02-04 17:39:34 +0100 | <ski> | if it appears in Haskell source, then it's a decimal numeric literal (assuming there's no `0x',`0o' or `0b' prefix before it, or it being part of an identifier, or a `String' literal or anything like that) |
2022-02-04 17:39:45 +0100 | <CHUD> | on the regular terminal not the one in vs code |
2022-02-04 17:39:50 +0100 | <CHUD> | I'll try it in vs code |
2022-02-04 17:40:30 +0100 | <CHUD> | opqdonut: sorry, it seems to be doing something again x/71 |
2022-02-04 17:40:35 +0100 | <gaff> | ski: so can haskell code generate a literal like 0b1100? i am using 8.10.4 |
2022-02-04 17:40:55 +0100 | Vajb | (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Ping timeout: 256 seconds) |
2022-02-04 17:41:02 +0100 | <wavemode> | -X BinaryLiterals |
2022-02-04 17:41:10 +0100 | lavaman | (~lavaman@98.38.249.169) |
2022-02-04 17:41:14 +0100 | <ski> | gaff : what do tou mean by "generate a literal" ? |
2022-02-04 17:41:15 +0100 | <c_wraith> | gaff: literals are strings. you can certainly write a function that returns that string. But it's not a number. |
2022-02-04 17:41:20 +0100 | <messier102> | gaff: think about it this way: numeric values in Haskell (e.g. Int) encode some quantity. Whether we choose to represent that quantity as 255 (base 10), or 0xFF, or 0b11111111, all of which are equivalent, is a detail relating to the textual representation of that quantity |
2022-02-04 17:41:21 +0100 | Vajb | (~Vajb@2001:999:274:c862:3b86:e1e1:5bff:355e) |
2022-02-04 17:41:34 +0100 | <ski> | gaff : it can generate a `String' (or some other text format) that includes such a literal, sure |
2022-02-04 17:41:49 +0100 | doxen | (~bbrahms@pool-173-54-217-168.nwrknj.fios.verizon.net) |
2022-02-04 17:42:17 +0100 | cosimone | (~user@2001:b07:ae5:db26:c24a:d20:4d91:1e20) (Remote host closed the connection) |
2022-02-04 17:42:46 +0100 | <gaff> | ski: there is no way to do that, is it, because that doesn't make sense? |
2022-02-04 17:43:11 +0100 | <gaff> | i think i will need to think about that a bit more |
2022-02-04 17:43:11 +0100 | <ski> | to do what ? |
2022-02-04 17:43:28 +0100 | <opqdonut> | CHUD: you might find more help on the course's telegram channel (see the material), many people are using vs code to work on the course but I'm not that familiar with vs code myself. The instructions do work in a normal linux terminal at least :) |
2022-02-04 17:43:47 +0100 | <gaff> | i mean haskell function can return a literal like 123, but can it return 0b1100? |
2022-02-04 17:43:52 +0100 | cosimone | (~user@2001:b07:ae5:db26:c24a:d20:4d91:1e20) |
2022-02-04 17:44:12 +0100 | <ski> | foo x = "123" |
2022-02-04 17:44:21 +0100 | <ski> | bar y = "0b1100" |
2022-02-04 17:44:25 +0100 | <ski> | there you go |
2022-02-04 17:44:36 +0100 | <gaff> | ok |
2022-02-04 17:44:42 +0100 | <ski> | both functions "return literals" |
2022-02-04 17:44:50 +0100 | <messier102> | gaff: if a function returns a number, it doesn't return a string of characters "123". It returns a value representing that quantity, which can be expressed in different ways |
2022-02-04 17:45:05 +0100 | <messier102> | % 1100 = 12 |
2022-02-04 17:45:05 +0100 | <yahb> | messier102: |
2022-02-04 17:45:09 +0100 | <messier102> | % 1100 == 12 |
2022-02-04 17:45:09 +0100 | <yahb> | messier102: False |
2022-02-04 17:45:20 +0100 | <messier102> | my binary math is off today, sorry |
2022-02-04 17:45:24 +0100 | <gaff> | ski: thanks |
2022-02-04 17:45:26 +0100 | <ski> | % 2 = 3 |
2022-02-04 17:45:26 +0100 | <yahb> | ski: |
2022-02-04 17:45:33 +0100 | Vajb | (~Vajb@2001:999:274:c862:3b86:e1e1:5bff:355e) (Ping timeout: 256 seconds) |
2022-02-04 17:45:35 +0100 | <janus> | does anybody have the sources for GHC 2? because it is needed it build GHC 3 |
2022-02-04 17:45:58 +0100 | <messier102> | % 0b1100 == 12 |
2022-02-04 17:45:58 +0100 | <yahb> | messier102: True |
2022-02-04 17:46:04 +0100 | <CHUD> | opqdonut: It seems to be progressing, I think when I first ran it, it build a different sent of haskell files I had, when I just ran it again now, I went into the exercises path and then ran stack... and it has just finished completing the 71 actions |
2022-02-04 17:46:29 +0100 | <ski> | % !2 = 3 |
2022-02-04 17:46:30 +0100 | <yahb> | ski: ; <interactive>:48:1: error: Top-level strict bindings aren't allowed: !2 = 3 |
2022-02-04 17:46:33 +0100 | <ski> | bah :) |
2022-02-04 17:46:35 +0100 | <dolio> | janus: https://www.haskell.org/ghc/download_ghc_210.html |
2022-02-04 17:46:57 +0100 | segfaultfizzbuzz | (~rustisafu@2602:306:cd3c:9350:7513:3c16:cd2c:7377) (Quit: Leaving) |
2022-02-04 17:47:17 +0100 | <dolio> | Oh, that's an FTP link? |
2022-02-04 17:47:25 +0100 | <janus> | it doesn't work |
2022-02-04 17:47:25 +0100 | <gaff> | ski: so literal = string of characters |
2022-02-04 17:47:38 +0100 | <janus> | "Error in server response" says wget |
2022-02-04 17:47:38 +0100 | <CHUD> | opqdonut: I just did a quick test after completing exercise 1 in set 1 and it ran and passed |
2022-02-04 17:48:00 +0100 | <dolio> | You might need to ask SPJ directly or something. |
2022-02-04 17:48:10 +0100 | <opqdonut> | CHUD: great |
2022-02-04 17:48:11 +0100 | <ski> | gaff : literal is a source notion. when representing source in Haskell, we tend to use `String', or some other text-representation (or perhaps an Abstract Syntax Tree, even) |
2022-02-04 17:48:15 +0100 | <wavemode> | if the git repository goes back far enough you can checkout the source code of any historical version |
2022-02-04 17:48:24 +0100 | <wavemode> | building it will be another story |
2022-02-04 17:48:27 +0100 | <janus> | ok i will shoot SPJ a mail then |
2022-02-04 17:48:28 +0100 | <messier102> | gaff: I think it would be easier to think about it if you banned the word "literal" from your vocabulary for a moment, because you seem to have misunderstood what it means |
2022-02-04 17:48:32 +0100 | <gaff> | ski |
2022-02-04 17:48:57 +0100 | <ski> | gaff |
2022-02-04 17:49:23 +0100 | <gaff> | yes |
2022-02-04 17:49:52 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Remote host closed the connection) |
2022-02-04 17:50:03 +0100 | chele | (~chele@user/chele) (Remote host closed the connection) |
2022-02-04 17:51:17 +0100 | <gaff> | so (0b11110000 + 0b00001111) :: Int = 255 => this is a source notion |
2022-02-04 17:51:39 +0100 | <CHUD> | opqdonut: thank you for helping me |
2022-02-04 17:52:13 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) |
2022-02-04 17:52:49 +0100 | <ski> | gaff : saying "my function returns a literal" sounds off in the same way as saying "my function returns a variable" or "my function returns a definition". strictly speaking, none of these can be the case, since the things that purportedly would be returned are not entities that exist at the level of Haskell evaluation. however, in the specific context of talking about some (e.g. source) language (e.g. |
2022-02-04 17:52:55 +0100 | <ski> | Haskell, or some other one), we can understand the former phrases as being shorthand for returning Haskell *representations* of those things (literals,&c.) |
2022-02-04 17:53:09 +0100 | <janus> | what is up with that ftp server |
2022-02-04 17:53:12 +0100 | <janus> | nc -vvv ftp.dcs.gla.ac.uk 21 |
2022-02-04 17:53:13 +0100 | <janus> | Connection to ftp.dcs.gla.ac.uk 21 port [tcp/ftp] succeeded! |
2022-02-04 17:53:20 +0100 | <janus> | and then it just never replies |
2022-02-04 17:53:24 +0100 | <gaff> | ok |
2022-02-04 17:54:18 +0100 | <dolio> | I'm honestly surprised it's still actually running. |
2022-02-04 17:54:20 +0100 | shapr | hugs Hecate |
2022-02-04 17:54:22 +0100 | <wavemode> | the server must be lazy |
2022-02-04 17:54:51 +0100 | <romesrf> | what happened to this (Haggis)? : https://www.microsoft.com/en-us/research/wp-content/uploads/1995/09/composing-haggis.pdf |
2022-02-04 17:55:01 +0100 | <gaff> | so the expression (0b11110000 + 0b00001111) :: Int contains binary l"literals" |
2022-02-04 17:55:02 +0100 | <ski> | gaff : the sequences of characters `0b11110000',`0b00001111' (and the sign `+' and the parentheses, and the `::' and the `Int') and `255' are source-level notions. however, when reading the expression (to the left of `=') into Haskell, those gets translated into corresponding Haskell evaluation notions (so the numeric literals (being in binary) gets translated to numbers (not being in any particular base), |
2022-02-04 17:55:08 +0100 | <ski> | the `+' operator gets translated to the addition function) |
2022-02-04 17:55:27 +0100 | <gaff> | ok |
2022-02-04 17:55:31 +0100 | <messier102> | Literals can be viewed as opposed to variables. They are the actual concrete values *in the source code*. For example, if you were to go and write `addTwo x = x + 2`, the 2 there would be considered a literal -- because we refer to all other values indirectly by their variable name. |
2022-02-04 17:55:44 +0100 | <ski> | oh, Haggis .. haven't heard that name in a long time |
2022-02-04 17:55:49 +0100 | zmt00 | (~zmt00@user/zmt00) |
2022-02-04 17:55:51 +0100 | <romesrf> | ahah :) |
2022-02-04 17:56:08 +0100 | <c_wraith> | messier102: I don't think that's the right contrast. I think the right contrast is that a literal is something you can represent in source code without calling a conversion function. |
2022-02-04 17:56:12 +0100 | <gaff> | messier102: correct |
2022-02-04 17:56:14 +0100 | ski | also misses Fudgets |
2022-02-04 17:57:00 +0100 | <janus> | what happened to Thomas Hallgren? |
2022-02-04 17:57:25 +0100 | <janus> | doesn't even mention FP on https://www.linkedin.com/in/thallgren/?locale=sv_SE |
2022-02-04 17:57:32 +0100 | <janus> | wonder if it is the right Hallgren |
2022-02-04 17:57:38 +0100 | <messier102> | c_wraith: well, yes, but I'm not coming at it from the compiler perspective necessarily :) this is already confusing enough |
2022-02-04 17:58:27 +0100 | wmacmil | (~wmacmil@83-233-165-97.cust.bredband2.com) (Remote host closed the connection) |
2022-02-04 17:58:37 +0100 | <ski> | janus : he still has <https://cth.altocumulus.org/~hallgren/>, which includes Fudgets,Alfa,&c. |
2022-02-04 17:58:50 +0100 | wmacmil | (~wmacmil@83-233-165-97.cust.bredband2.com) |
2022-02-04 17:58:59 +0100 | RFV | (~Thunderbi@139.red-88-12-223.dynamicip.rima-tde.net) |
2022-02-04 17:59:08 +0100 | <gaff> | c_wraith: what do you mean by "conversion function"? |
2022-02-04 17:59:11 +0100 | <romesrf> | ski: what's the Haggis story? it looks interesting but i can find nothing at all anywhere |
2022-02-04 17:59:23 +0100 | <romesrf> | i first saw it mentioned at the end of `Concurrent Haskell` |
2022-02-04 17:59:25 +0100 | <ski> | "WebFudgets (2017) WebFudgets allow Haskell programs built with Fudgets (see below) to run in a web page. I have adapted some of the Fudgets programs from back in the day to WebFudgets." |
2022-02-04 18:00:16 +0100 | <ski> | oh, and Hallgren also did WWWBrowser in Haskell (using Fudgets), which automagically could fetch images in parallel, displaying pages faster than Mosaic |
2022-02-04 18:00:21 +0100 | <dolio> | It seems like the important thing to point out in this context is that literals are notation for values. They're not values, and many literals can be notation for the same value. |
2022-02-04 18:00:26 +0100 | wmacmil | (~wmacmil@83-233-165-97.cust.bredband2.com) (Remote host closed the connection) |
2022-02-04 18:00:52 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 18:00:55 +0100 | <dolio> | And the notation originally used to describe the value has no effect on how the value is printed to the screen. |
2022-02-04 18:01:03 +0100 | <ski> | romesrf : i don't believe i looked that much into Haggis at the time (i did read more about Fudgets, to be sure) |
2022-02-04 18:01:11 +0100 | wmacmil | (~wmacmil@83-233-165-97.cust.bredband2.com) |
2022-02-04 18:01:28 +0100 | ubert | (~Thunderbi@p200300ecdf0994a856831da0cd63cc4d.dip0.t-ipconnect.de) (Remote host closed the connection) |
2022-02-04 18:01:45 +0100 | slack1256 | (~slack1256@191.125.227.215) |
2022-02-04 18:01:51 +0100 | <c_wraith> | gaff: there's nothing special about that term. It's a function that converts something to something else. |
2022-02-04 18:01:59 +0100 | tzh | (~tzh@c-24-21-73-154.hsd1.wa.comcast.net) |
2022-02-04 18:02:02 +0100 | wmacmil | (~wmacmil@83-233-165-97.cust.bredband2.com) (Remote host closed the connection) |
2022-02-04 18:02:05 +0100 | <ski> | "The programming languages I used in the beginning were mostly BASIC and 6502 assembler." -- hehe :) |
2022-02-04 18:02:12 +0100 | Akiva | (~Akiva@user/Akiva) |
2022-02-04 18:02:27 +0100 | machinedgod | (~machinedg@24.105.81.50) (Ping timeout: 256 seconds) |
2022-02-04 18:02:52 +0100 | <gaff> | ski: that's way back |
2022-02-04 18:03:00 +0100 | lbseale | (~ep1ctetus@user/ep1ctetus) |
2022-02-04 18:03:01 +0100 | <ski> | which ? |
2022-02-04 18:03:01 +0100 | CHUD | (~CHUD@edu791A.kent.ac.uk) (Remote host closed the connection) |
2022-02-04 18:03:06 +0100 | <gaff> | BASIC |
2022-02-04 18:03:20 +0100 | CHUD | (~CHUD@edu791A.kent.ac.uk) |
2022-02-04 18:03:22 +0100 | <gaff> | do people use that stuff anymore? |
2022-02-04 18:03:25 +0100 | ski | also, incidentally, started with BASIC, and 6502 assembler |
2022-02-04 18:03:35 +0100 | slac13545 | (~slack1256@191.125.227.202) (Read error: Connection reset by peer) |
2022-02-04 18:04:13 +0100 | <gaff> | c_wraith: like fromIntegral? |
2022-02-04 18:04:39 +0100 | <messier102> | maybe we're reinventing the wheel here |
2022-02-04 18:04:40 +0100 | <messier102> | https://en.wikipedia.org/wiki/Literal_(computer_programming) |
2022-02-04 18:04:50 +0100 | <ski> | well .. i've been, on and off, lately, disassembling a Prolog implementation for the Commodore 64 (wanting to add LCO/TCO, and probably the "same" for disjunctions. and want to fix a bug with variable name display, and perhaps some other tweaks as well) |
2022-02-04 18:05:12 +0100 | <c_wraith> | gaff: like every single function except for id |
2022-02-04 18:05:14 +0100 | slowButPresent | (~slowButPr@user/slowbutpresent) |
2022-02-04 18:05:19 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:c18f:7483:538b:1622) (Remote host closed the connection) |
2022-02-04 18:05:28 +0100 | <gaff> | yeah |
2022-02-04 18:05:51 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Ping timeout: 256 seconds) |
2022-02-04 18:06:07 +0100 | <janus> | oooh good to see his website. |
2022-02-04 18:06:24 +0100 | <Cheery> | I'm in middle of implementing typeclasses in my own runtime/compiler. Any ideas or advices that I might miss otherwise? |
2022-02-04 18:06:35 +0100 | <ski> | reminds me i want to try to install Fudgets and Alfa again |
2022-02-04 18:06:40 +0100 | <gaff> | but a binary literal is desugared to fromInteger 0b... |
2022-02-04 18:06:43 +0100 | RFV | (~Thunderbi@139.red-88-12-223.dynamicip.rima-tde.net) (Quit: RFV) |
2022-02-04 18:06:48 +0100 | <gaff> | under the hood |
2022-02-04 18:07:18 +0100 | <ski> | all integer literals are desugared like that .. that's not specific to binary ones |
2022-02-04 18:08:41 +0100 | tavares | (~tavares@user/tavares) (Ping timeout: 256 seconds) |
2022-02-04 18:08:55 +0100 | <gaff> | i am contrasting with what has been said earlier ... that literals do not need conversion functions. perhaps what was meant was that they do not need explicit conversion functions. |
2022-02-04 18:08:55 +0100 | <ski> | (and the decimal/octal/hexadecimal/binary integer literal, of type `Integer', that's being passed to `fromInteger', is read/translated into an integer (number)) |
2022-02-04 18:09:10 +0100 | cfricke | (~cfricke@user/cfricke) (Quit: WeeChat 3.3) |
2022-02-04 18:10:20 +0100 | tavares | (~tavares@187.19.213.50) |
2022-02-04 18:10:21 +0100 | <ski> | i didn't really follow the conversion part of the conversation, but i guess the idea was that there was no *explicit* conversion in the source, for a literal ? |
2022-02-04 18:10:21 +0100 | zer0bitz | (~zer0bitz@2001:2003:f74d:b800:39e9:9943:8cd0:5689) |
2022-02-04 18:10:37 +0100 | CiaoSen | (~Jura@p200300c95737a2002a3a4dfffe84dbd5.dip0.t-ipconnect.de) (Ping timeout: 240 seconds) |
2022-02-04 18:10:51 +0100 | <dolio> | I think that angle is not going to clear up confusion. |
2022-02-04 18:11:05 +0100 | <gaff> | i am not sure what the person who mentioned it really meant. |
2022-02-04 18:11:11 +0100 | ski | . o O ( To converse or not to conserve, is that the question ? ) |
2022-02-04 18:11:13 +0100 | <messier102> | gaff: I think you're fixating on the "conversion function" remark too much. It's not that important to understanding the notion of a literal. |
2022-02-04 18:11:22 +0100 | <gaff> | ok |
2022-02-04 18:12:09 +0100 | <dolio> | > 0 == (256 :: Int8) |
2022-02-04 18:12:11 +0100 | <lambdabot> | True |
2022-02-04 18:12:48 +0100 | <messier102> | Maybe an analogy would help. Think of a literal as a recipe for a cake. When a program runs, it takes that recipe and creates an actual cake (runtime value in memory) from it. But the recipe itself is not something that exists as a physical object during execution. |
2022-02-04 18:12:51 +0100 | <dolio> | > (256 :: Int8) |
2022-02-04 18:12:54 +0100 | <lambdabot> | 0 |
2022-02-04 18:13:21 +0100 | <wavemode> | shouldn't it wrap to negative if it's signed |
2022-02-04 18:13:23 +0100 | <dolio> | Doesn't matter that I typed in 256, it still prints 0. |
2022-02-04 18:13:24 +0100 | machinedgod | (~machinedg@24.105.81.50) |
2022-02-04 18:13:27 +0100 | Feuermagier_ | (~Feuermagi@84.17.48.173) |
2022-02-04 18:13:36 +0100 | <dolio> | wavemode: It did. :) |
2022-02-04 18:13:58 +0100 | <ski> | messier102 : heh, that's a new take of that analogy :) |
2022-02-04 18:14:02 +0100 | whound | (~dust@2405:204:5488:ef4c:54b6:3467:52f3:e9f2) |
2022-02-04 18:14:21 +0100 | Pickchea | (~private@user/pickchea) (Quit: Leaving) |
2022-02-04 18:14:21 +0100 | <messier102> | ski: can you guess I just read a lecture on monads :D |
2022-02-04 18:14:37 +0100 | <ski> | @quote not.the.cake |
2022-02-04 18:14:37 +0100 | <lambdabot> | ski says: <ski> `getLine :: IO String' is a recipe for how to interact with the world to acquire a `String' <ski> the recipe is not the cake |
2022-02-04 18:14:44 +0100 | <messier102> | a number is like a burrito... |
2022-02-04 18:15:15 +0100 | <gaff> | too many analogies on food |
2022-02-04 18:15:57 +0100 | Feuermagier | (~Feuermagi@user/feuermagier) (Ping timeout: 250 seconds) |
2022-02-04 18:16:47 +0100 | <gaff> | ski: thanks much for your help. |
2022-02-04 18:16:50 +0100 | <ski> | np |
2022-02-04 18:17:03 +0100 | <gaff> | thanks everyone. |
2022-02-04 18:17:10 +0100 | <gaff> | bye |
2022-02-04 18:17:18 +0100 | <ski> | laters. have fun with Haskell ! |
2022-02-04 18:17:19 +0100 | gaff | (~gaff@49.207.198.16) () |
2022-02-04 18:17:50 +0100 | <messier102> | I hope it was at all helpful |
2022-02-04 18:20:11 +0100 | <geekosaur> | @quote rightly.apprehend |
2022-02-04 18:20:11 +0100 | <lambdabot> | No quotes match. :( |
2022-02-04 18:20:48 +0100 | <geekosaur> | "I am not able rightly to apprehend the kind of confusion of ideas that could provoke such a question." |
2022-02-04 18:21:34 +0100 | <ski> | @remember Charles_Babbage I am not able rightly to apprehend the kind of confusion of ideas that could provoke such a question. |
2022-02-04 18:21:34 +0100 | <lambdabot> | I will never forget. |
2022-02-04 18:22:03 +0100 | acarrico | (~acarrico@dhcp-68-142-39-249.greenmountainaccess.net) (Quit: Leaving.) |
2022-02-04 18:22:23 +0100 | acarrico | (~acarrico@dhcp-68-142-39-249.greenmountainaccess.net) |
2022-02-04 18:22:44 +0100 | <messier102> | powerful words |
2022-02-04 18:23:22 +0100 | Vajb | (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) |
2022-02-04 18:23:25 +0100 | slac93974 | (~slack1256@186.11.30.195) |
2022-02-04 18:24:32 +0100 | tavares | (~tavares@187.19.213.50) (Changing host) |
2022-02-04 18:24:32 +0100 | tavares | (~tavares@user/tavares) |
2022-02-04 18:25:27 +0100 | slack1256 | (~slack1256@191.125.227.215) (Ping timeout: 256 seconds) |
2022-02-04 18:26:37 +0100 | xff0x | (~xff0x@2001:1a81:5224:e000:7446:150d:d8ae:ed12) (Ping timeout: 240 seconds) |
2022-02-04 18:28:41 +0100 | xff0x | (~xff0x@2001:1a81:5244:c900:da3d:85a0:8128:63) |
2022-02-04 18:29:53 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:c18f:7483:538b:1622) |
2022-02-04 18:30:20 +0100 | lavaman | (~lavaman@98.38.249.169) (Remote host closed the connection) |
2022-02-04 18:31:29 +0100 | desantra | (~skykanin@user/skykanin) (Quit: WeeChat 3.3) |
2022-02-04 18:31:35 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Remote host closed the connection) |
2022-02-04 18:31:55 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) |
2022-02-04 18:32:41 +0100 | <CHUD> | quadruple :: Integer -> Integer quadruple x = double (double x) |
2022-02-04 18:33:02 +0100 | <CHUD> | ignore that sorry, I was trying to write a multiline |
2022-02-04 18:33:11 +0100 | <ski> | quadruple = double . double |
2022-02-04 18:34:39 +0100 | CHUD | (~CHUD@edu791A.kent.ac.uk) (Remote host closed the connection) |
2022-02-04 18:34:56 +0100 | CHUD | (~CHUD@edu791A.kent.ac.uk) |
2022-02-04 18:35:35 +0100 | <wavemode> | quadruple = decimate . vigintuple |
2022-02-04 18:35:57 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) (Ping timeout: 240 seconds) |
2022-02-04 18:36:53 +0100 | maerwald | (~maerwald@mail.hasufell.de) (Changing host) |
2022-02-04 18:36:53 +0100 | maerwald | (~maerwald@user/maerwald) |
2022-02-04 18:44:35 +0100 | wavemode | (~wavemode@c-98-223-145-19.hsd1.il.comcast.net) () |
2022-02-04 18:45:00 +0100 | wavemode | (~wavemode@2601:241:0:fc90:da0f:27a6:a9a0:a864) |
2022-02-04 18:47:45 +0100 | lavaman | (~lavaman@98.38.249.169) |
2022-02-04 18:48:00 +0100 | segfaultfizzbuzz | (~rustisafu@2602:306:cd3c:9350:5857:f054:76af:4d5e) |
2022-02-04 18:48:10 +0100 | FinnElija | (~finn_elij@user/finn-elija/x-0085643) (Remote host closed the connection) |
2022-02-04 18:48:33 +0100 | FinnElija | (~finn_elij@user/finn-elija/x-0085643) |
2022-02-04 18:50:12 +0100 | romesrf | (~romes@bl8-111-202.dsl.telepac.pt) (Quit: WeeChat 3.4) |
2022-02-04 18:50:23 +0100 | MoC | (~moc@user/moc) (Quit: Konversation terminated!) |
2022-02-04 18:50:43 +0100 | MajorBiscuit | (~MajorBisc@wlan-145-94-218-48.wlan.tudelft.nl) (Ping timeout: 256 seconds) |
2022-02-04 18:50:57 +0100 | CHUD | (~CHUD@edu791A.kent.ac.uk) (Ping timeout: 256 seconds) |
2022-02-04 18:52:37 +0100 | alp | (~alp@user/alp) (Ping timeout: 240 seconds) |
2022-02-04 18:52:57 +0100 | max22- | (~maxime@2a01cb0883359800f5889d6f7a8326a9.ipv6.abo.wanadoo.fr) (Remote host closed the connection) |
2022-02-04 18:52:57 +0100 | segfaultfizzbuzz | (~rustisafu@2602:306:cd3c:9350:5857:f054:76af:4d5e) (Ping timeout: 240 seconds) |
2022-02-04 18:53:47 +0100 | max22- | (~maxime@lfbn-ren-1-1026-62.w92-139.abo.wanadoo.fr) |
2022-02-04 19:01:09 +0100 | zuhkov | (~duycop@14.166.144.253) |
2022-02-04 19:01:24 +0100 | alp | (~alp@user/alp) |
2022-02-04 19:01:38 +0100 | zuhkov | (~duycop@14.166.144.253) () |
2022-02-04 19:06:49 +0100 | wombat875 | (~wombat875@pool-72-89-24-154.nycmny.fios.verizon.net) (Read error: Connection reset by peer) |
2022-02-04 19:09:49 +0100 | wavemode | (~wavemode@2601:241:0:fc90:da0f:27a6:a9a0:a864) (Quit: Client closed) |
2022-02-04 19:10:06 +0100 | wavemode | (~wavemode@2601:241:0:fc90:da0f:27a6:a9a0:a864) |
2022-02-04 19:10:55 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 19:12:49 +0100 | doxen | (~bbrahms@pool-173-54-217-168.nwrknj.fios.verizon.net) (Ping timeout: 256 seconds) |
2022-02-04 19:18:20 +0100 | <monochrom> | Aaahhhh late to a conversation that begs for bad puns. "What is a literal, literally?" (OK I'm stopping now.) |
2022-02-04 19:19:11 +0100 | <geekosaur> | that convo was confusing enough without, I think |
2022-02-04 19:20:54 +0100 | waleee | (~waleee@2001:9b0:21d:fc00:398f:b003:b90d:acf4) (Ping timeout: 260 seconds) |
2022-02-04 19:21:07 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) |
2022-02-04 19:21:12 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Remote host closed the connection) |
2022-02-04 19:22:11 +0100 | waleee | (~waleee@h-98-128-229-110.NA.cust.bahnhof.se) |
2022-02-04 19:22:41 +0100 | doxen | (~bbrahms@pool-173-54-217-168.nwrknj.fios.verizon.net) |
2022-02-04 19:24:31 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 19:25:31 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) (Ping timeout: 256 seconds) |
2022-02-04 19:25:58 +0100 | justsomeguy | (~justsomeg@user/justsomeguy) |
2022-02-04 19:26:54 +0100 | <justsomeguy> | What do you guys think of this article "When You Should Use Lsts in Haskell (Mostly, You Should Not)" https://www.imn.htwk-leipzig.de/~waldmann/etc/untutorial/list-or-not-list/ |
2022-02-04 19:27:34 +0100 | <EvanR> | list is good for composing computations and bad for big data storage |
2022-02-04 19:28:05 +0100 | <EvanR> | in haskell it's cool because those two are not the same |
2022-02-04 19:28:19 +0100 | burnsidesLlama | (~burnsides@dhcp168-031.wadham.ox.ac.uk) |
2022-02-04 19:28:37 +0100 | <geekosaur> | in many ways it's best to think of a list as a loop rather than a data structure |
2022-02-04 19:29:11 +0100 | <c_wraith> | Honestly, I think most list aversion is overblown, like string aversion. Ok, those are the same thing. |
2022-02-04 19:29:24 +0100 | <c_wraith> | Most of the time, it doesn't matter. |
2022-02-04 19:29:29 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Ping timeout: 256 seconds) |
2022-02-04 19:29:39 +0100 | <wavemode> | lists, like any data structure you use, need to be evaluated in terms of their asymptotics. lists have O(1) cons but O(N) most everything else, so you should only use them if that's acceptable for your use case |
2022-02-04 19:30:14 +0100 | <geekosaur> | yeh, I have a decent amount of code locally that just uses lists because they're easy and they don't sling around anywhere near enough data to justify something else |
2022-02-04 19:30:18 +0100 | <c_wraith> | Haskell lists have other really nice properties, like being easy to produce and consume in O(1) space |
2022-02-04 19:30:58 +0100 | <wavemode> | many people also don't like relying on list fusion :p |
2022-02-04 19:31:06 +0100 | <c_wraith> | that doesn't rely on fusion! |
2022-02-04 19:31:14 +0100 | <c_wraith> | fusion is only a constant-factor improvement |
2022-02-04 19:31:36 +0100 | <geekosaur> | and xmonad has gotten by for over a decade with lists, mainly because it's extremely rare to have enough windows open for it to matter |
2022-02-04 19:31:53 +0100 | <ski> | (zipper) |
2022-02-04 19:32:02 +0100 | <c_wraith> | I can't imagine successfully using a computer with several thousand open windows :) |
2022-02-04 19:33:08 +0100 | <EvanR> | browser tabs on the other hand |
2022-02-04 19:33:08 +0100 | k8yun | (~k8yun@198-48-158-40.cpe.pppoe.ca) |
2022-02-04 19:33:14 +0100 | <Cheery> | I keep forgetting I got windows open and there's plenty of them behind. |
2022-02-04 19:33:42 +0100 | <monochrom> | I would support "When You Should Use Lists in Any Language at All (Mostly You Shouldn't)". |
2022-02-04 19:34:29 +0100 | <monochrom> | OK, I need to correct it to "When You Should Use Lists for Data in Any Language at All (Mostly You Shouldn't)". |
2022-02-04 19:34:32 +0100 | <ski> | .. perhaps if you indexed your windows, possibly adding tags, and allowed searching for the one you wanted ? |
2022-02-04 19:34:39 +0100 | <c_wraith> | You should probably use lists more in Haskell than most languages |
2022-02-04 19:34:40 +0100 | <EvanR> | how about "for some x, when you should use data structure x in any language at all mostly you shouldn't" |
2022-02-04 19:35:21 +0100 | jao | (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) |
2022-02-04 19:35:51 +0100 | <EvanR> | there's the idea of "the one true number type" and "the one true container type" in many languages, an ideal form that the wise designers attempted to approximate |
2022-02-04 19:36:05 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Remote host closed the connection) |
2022-02-04 19:36:13 +0100 | <geekosaur> | we even have a module supporting that (TagWindows) |
2022-02-04 19:36:26 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) |
2022-02-04 19:36:38 +0100 | <EvanR> | mostly you shouldn't use the one true number type or container type |
2022-02-04 19:36:50 +0100 | <maerwald> | thanks to the "lists are great" mentality, we still have `type String = [Char]` |
2022-02-04 19:37:00 +0100 | <c_wraith> | maerwald: and there's nothing wrong with that |
2022-02-04 19:37:26 +0100 | <maerwald> | right... I guess that's why I'm putting so much time into removing `type FilePath = String` :D |
2022-02-04 19:37:33 +0100 | <justsomeguy> | I guess this discussion applies to any language with singly-linked lists. The article gives a general rule of thumb that lists should usually not be used where out-of-order access is required. I think that's reasonable. It also claims that lists don't properly segregate iteration and data representation, which I'm undecided about either way. |
2022-02-04 19:37:43 +0100 | <c_wraith> | now there is a *lot* wrong with FilePath = String |
2022-02-04 19:37:48 +0100 | <c_wraith> | because that's just plain false |
2022-02-04 19:38:23 +0100 | <EvanR> | church encoding wonders why you'd want to segregate iteration and representation? xD |
2022-02-04 19:38:23 +0100 | <maerwald> | exactly... people use what is convenient, not what is correct |
2022-02-04 19:38:42 +0100 | <maerwald> | lists happen to be convenient in haskell |
2022-02-04 19:38:46 +0100 | <maerwald> | so they're all over the place |
2022-02-04 19:38:46 +0100 | <Cheery> | why [Char] and not [Integer]? |
2022-02-04 19:39:00 +0100 | Jing | (~hedgehog@240e:390:7c53:a7e1:8d1b:5472:3cae:e50c) (Quit: My MacBook has gone to sleep. ZZZzzz…) |
2022-02-04 19:39:13 +0100 | <wavemode> | what's that Church and state quote |
2022-02-04 19:39:22 +0100 | <maerwald> | Cheery: lol |
2022-02-04 19:39:32 +0100 | <EvanR> | haskell could use more convenience I think, we've got enough correctness to last until end of nuclear winter |
2022-02-04 19:39:41 +0100 | <maerwald> | EvanR: where? |
2022-02-04 19:39:57 +0100 | <ski> | @quote church.and.state |
2022-02-04 19:39:58 +0100 | <lambdabot> | shapr says: Haskell separates Church and state! |
2022-02-04 19:40:06 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 19:40:17 +0100 | <ski> | @quote separation.of |
2022-02-04 19:40:17 +0100 | <lambdabot> | GuySteele says: Some people prefer not to commingle the functional, lambda-calculus part of a language with the parts that do side effects. It seems they believe in the separation of Church and |
2022-02-04 19:40:17 +0100 | <lambdabot> | state. |
2022-02-04 19:40:40 +0100 | <ski> | @quote are.dual |
2022-02-04 19:40:40 +0100 | <lambdabot> | ski says: I'd rather say that in Haskell, Church and State are dual |
2022-02-04 19:41:10 +0100 | <EvanR> | an outmoded identification of state with IO maybe |
2022-02-04 19:41:49 +0100 | <ski> | (Church closely related to `forall o. (a -> o) -> o', State to `exists s. (s,s -> a)') |
2022-02-04 19:42:43 +0100 | <ski> | (or `forall o. (f o -> o) -> o' vs. `exists s. (s,s -> f s)', with recursion) |
2022-02-04 19:43:00 +0100 | <monochrom> | If one day I dualize System F that way, may I call it System E? :) |
2022-02-04 19:44:12 +0100 | <ski> | hm, curious (going backwards in alphabet) .. i guess so |
2022-02-04 19:44:50 +0100 | <monochrom> | An explanation is that E stands for "exists". |
2022-02-04 19:45:01 +0100 | <ski> | yes, i gathered :) |
2022-02-04 19:45:06 +0100 | <Cheery> | anyone knows if there are tricks to implementing typeclasses? |
2022-02-04 19:45:11 +0100 | <ski> | "F" for "forall" ? |
2022-02-04 19:45:20 +0100 | <geekosaur> | Cheery, why? |
2022-02-04 19:45:37 +0100 | <ski> | <Cheery> I'm in middle of implementing typeclasses in my own runtime/compiler. Any ideas or advices that I might miss otherwise? |
2022-02-04 19:45:40 +0100 | <geekosaur> | or what kinds of tricks are you thinking of? in ghc a typeclass instance is just a record of functions |
2022-02-04 19:45:45 +0100 | <monochrom> | I don't know whether Girard or Reynolds meant "F" to stand for "for all", but it works revisionistly! |
2022-02-04 19:46:04 +0100 | <geekosaur> | all they "need" to be is a type witness, but a record of implementations is a convenient witness |
2022-02-04 19:46:07 +0100 | <ski> | backronyms ftw ! |
2022-02-04 19:47:18 +0100 | <geekosaur> | and can be optimized away via inlining in many cases, since polymorphic recursion isn't that common |
2022-02-04 19:48:10 +0100 | MoC | (~moc@user/moc) |
2022-02-04 19:48:23 +0100 | <ski> | (or existentials) |
2022-02-04 19:49:11 +0100 | <ski> | (or higher-rank constraints) |
2022-02-04 19:49:21 +0100 | econo | (uid147250@user/econo) |
2022-02-04 19:51:09 +0100 | oscurochu | (~oscurochu@097-096-050-227.res.spectrum.com) |
2022-02-04 19:52:24 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:c18f:7483:538b:1622) (Remote host closed the connection) |
2022-02-04 19:53:14 +0100 | <Cheery> | well I'm implementing it in a runtime, using rpython. |
2022-02-04 19:55:26 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:c18f:7483:538b:1622) |
2022-02-04 19:55:58 +0100 | Erutuon | (~Erutuon@user/erutuon) |
2022-02-04 19:56:55 +0100 | jao | (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Remote host closed the connection) |
2022-02-04 19:57:18 +0100 | doyougnu | (~doyougnu@cpe-67-249-83-190.twcny.res.rr.com) (Remote host closed the connection) |
2022-02-04 19:59:22 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Remote host closed the connection) |
2022-02-04 19:59:25 +0100 | <Cheery> | implicits are an another nice thing, and these resemble those a bit. |
2022-02-04 20:00:50 +0100 | doyougnu | (~doyougnu@cpe-67-249-83-190.twcny.res.rr.com) |
2022-02-04 20:00:59 +0100 | alp | (~alp@user/alp) (Ping timeout: 256 seconds) |
2022-02-04 20:01:23 +0100 | <EvanR> | how type classes are different from implicits |
2022-02-04 20:01:39 +0100 | <EvanR> | Type Classes vs The World xD |
2022-02-04 20:03:19 +0100 | <Cheery> | well.. implicits are passed by name, eg. you got same name {g} somewhere, that hidden variable fills up slots elsewhere. |
2022-02-04 20:04:29 +0100 | ski | . o O ( "What's in a name? That which we call a rose / By any other name would smell as sweet" ) |
2022-02-04 20:05:17 +0100 | <ski> | (it would be nice to be able to rename implicits, on import (and export)) |
2022-02-04 20:05:47 +0100 | whound | (~dust@2405:204:5488:ef4c:54b6:3467:52f3:e9f2) (Quit: Konversation terminated!) |
2022-02-04 20:05:50 +0100 | <EvanR> | implicits give you access to the dictionary for whatever nefarious purposes, where as there's at most 1 instance for a given type class combination |
2022-02-04 20:06:04 +0100 | jao | (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) |
2022-02-04 20:06:17 +0100 | <EvanR> | globally |
2022-02-04 20:06:40 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 20:07:54 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:c18f:7483:538b:1622) (Remote host closed the connection) |
2022-02-04 20:08:53 +0100 | lavaman | (~lavaman@98.38.249.169) (Remote host closed the connection) |
2022-02-04 20:09:01 +0100 | o-90 | (~o-90@gateway/tor-sasl/o-90) |
2022-02-04 20:10:37 +0100 | messier102 | (~messier10@user/messier102) (Ping timeout: 240 seconds) |
2022-02-04 20:10:38 +0100 | doyougnu | (~doyougnu@cpe-67-249-83-190.twcny.res.rr.com) (Read error: Connection reset by peer) |
2022-02-04 20:11:25 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Ping timeout: 256 seconds) |
2022-02-04 20:23:11 +0100 | justsomeguy | (~justsomeg@user/justsomeguy) (Quit: WeeChat 3.4) |
2022-02-04 20:23:33 +0100 | <Cheery> | I can adjust my type inference/checker to elaborate, so it can add app(name,Y) around name, to handle constraints. |
2022-02-04 20:24:06 +0100 | o-90 | (~o-90@gateway/tor-sasl/o-90) (Ping timeout: 276 seconds) |
2022-02-04 20:24:40 +0100 | doyougnu | (~doyougnu@cpe-67-249-83-190.twcny.res.rr.com) |
2022-02-04 20:25:11 +0100 | emf | (~emf@162.218.217.190) |
2022-02-04 20:29:00 +0100 | emf_ | (~emf@2620:10d:c090:400::5:9a32) |
2022-02-04 20:29:52 +0100 | emf | (~emf@162.218.217.190) (Ping timeout: 250 seconds) |
2022-02-04 20:30:16 +0100 | vicfred | (~vicfred@user/vicfred) |
2022-02-04 20:30:42 +0100 | rusrushal13 | (~rusrushal@2409:4056:9:1708:2c2:74fb:7af9:78dc) (Ping timeout: 256 seconds) |
2022-02-04 20:31:20 +0100 | eggplantade | (~Eggplanta@2600:1700:bef1:5e10:c18f:7483:538b:1622) |
2022-02-04 20:34:07 +0100 | slack1256 | (~slack1256@191.125.227.215) |
2022-02-04 20:34:35 +0100 | <Cheery> | that way the generalize/instantiate also stays simple.. when the constraint is just a parameter to be passed implicitly. |
2022-02-04 20:35:04 +0100 | szkl | (uid110435@id-110435.uxbridge.irccloud.com) |
2022-02-04 20:35:57 +0100 | slac93974 | (~slack1256@186.11.30.195) (Ping timeout: 240 seconds) |
2022-02-04 20:38:24 +0100 | ec | (~ec@gateway/tor-sasl/ec) |
2022-02-04 20:39:38 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) |
2022-02-04 20:41:35 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Remote host closed the connection) |
2022-02-04 20:41:53 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) |
2022-02-04 20:45:04 +0100 | wavemode | (~wavemode@2601:241:0:fc90:da0f:27a6:a9a0:a864) (Quit: Client closed) |
2022-02-04 20:48:10 +0100 | marijan | (~marijanma@2001:470:69fc:105::1:6cce) |
2022-02-04 20:50:52 +0100 | bgamari | (~bgamari@2001:470:e438::1) (Remote host closed the connection) |
2022-02-04 20:51:14 +0100 | lavaman | (~lavaman@98.38.249.169) |
2022-02-04 20:52:35 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Remote host closed the connection) |
2022-02-04 20:52:54 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) |
2022-02-04 20:53:27 +0100 | bgamari | (~bgamari@70.16.102.89) |
2022-02-04 20:53:35 +0100 | oscurochu | (~oscurochu@097-096-050-227.res.spectrum.com) (Ping timeout: 256 seconds) |
2022-02-04 20:53:53 +0100 | ChaiTRex | (~ChaiTRex@user/chaitrex) |
2022-02-04 20:55:18 +0100 | chomwitt | (~chomwitt@2a02:587:dc07:dd00:12c3:7bff:fe6d:d374) |
2022-02-04 20:55:39 +0100 | TranquilEcho | (~grom@user/tranquilecho) |
2022-02-04 20:55:57 +0100 | lavaman | (~lavaman@98.38.249.169) (Ping timeout: 256 seconds) |
2022-02-04 20:59:20 +0100 | ProfSimm | (~ProfSimm@87.227.196.109) |
2022-02-04 21:00:55 +0100 | neurocyte0917090 | (~neurocyte@IP-212232080188.dynamic.medianet-world.de) |
2022-02-04 21:00:55 +0100 | neurocyte0917090 | (~neurocyte@IP-212232080188.dynamic.medianet-world.de) (Changing host) |
2022-02-04 21:00:55 +0100 | neurocyte0917090 | (~neurocyte@user/neurocyte) |
2022-02-04 21:01:31 +0100 | kimjetwav | (~user@2607:fea8:2363:8f00:8299:55f4:a45f:d9c3) (Remote host closed the connection) |
2022-02-04 21:03:14 +0100 | TranquilEcho | (~grom@user/tranquilecho) (Quit: WeeChat 2.8) |
2022-02-04 21:04:57 +0100 | juhp | (~juhp@128.106.188.82) (Ping timeout: 240 seconds) |
2022-02-04 21:07:43 +0100 | juhp | (~juhp@128.106.188.82) |
2022-02-04 21:08:25 +0100 | zer0bitz | (~zer0bitz@2001:2003:f74d:b800:39e9:9943:8cd0:5689) (Ping timeout: 256 seconds) |
2022-02-04 21:09:29 +0100 | merijn | (~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 252 seconds) |
2022-02-04 21:09:36 +0100 | <monochrom> | Dear lyxia: Define "data B a = F | T", this can be easily made a functor and contravariant functor. With that, phatom F = F, phatom T = T. However, "neg T = F; neg F = T" has the same type as phantom, B a -> B b, and still do different things. |
2022-02-04 21:09:53 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) |
2022-02-04 21:11:09 +0100 | kaph | (~kaph@net-2-47-208-144.cust.vodafonedsl.it) (Read error: Connection reset by peer) |
2022-02-04 21:12:02 +0100 | tatarqa | (~kli@ip-89-177-122-45.net.upcbroadband.cz) |
2022-02-04 21:13:14 +0100 | whatsupdoc | (uid509081@id-509081.hampstead.irccloud.com) |
2022-02-04 21:18:29 +0100 | kaph | (~kaph@net-2-47-208-144.cust.vodafonedsl.it) |
2022-02-04 21:20:10 +0100 | califax | (~califax@user/califx) (Remote host closed the connection) |
2022-02-04 21:20:19 +0100 | cynomys | (~cynomys@user/cynomys) |
2022-02-04 21:20:56 +0100 | lavaman | (~lavaman@98.38.249.169) |
2022-02-04 21:21:29 +0100 | califax | (~califax@user/califx) |
2022-02-04 21:21:47 +0100 | slac63591 | (~slack1256@186.11.28.67) |
2022-02-04 21:22:05 +0100 | fendor | (~fendor@91.141.44.253.wireless.dyn.drei.com) (Remote host closed the connection) |
2022-02-04 21:24:11 +0100 | slack1256 | (~slack1256@191.125.227.215) (Ping timeout: 256 seconds) |
2022-02-04 21:27:00 +0100 | ardell | (~ardell@user/ardell) |
2022-02-04 21:27:07 +0100 | ardell | (~ardell@user/ardell) (Client Quit) |
2022-02-04 21:28:04 +0100 | ardell | (~ardell@user/ardell) |
2022-02-04 21:28:59 +0100 | xff0x | (~xff0x@2001:1a81:5244:c900:da3d:85a0:8128:63) (Ping timeout: 250 seconds) |
2022-02-04 21:29:52 +0100 | xff0x | (~xff0x@2001:1a81:5244:c900:2c67:9c0a:1653:d1e3) |
2022-02-04 21:31:00 +0100 | [exa] | (exa@user/exa/x-3587197) (Remote host closed the connection) |
2022-02-04 21:32:43 +0100 | jonathanx_ | (~jonathan@h-178-174-176-109.a357.priv.bahnhof.se) |
2022-02-04 21:36:39 +0100 | jonathanx | (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Ping timeout: 256 seconds) |
2022-02-04 21:36:59 +0100 | doyougnu | (~doyougnu@cpe-67-249-83-190.twcny.res.rr.com) (Ping timeout: 256 seconds) |
2022-02-04 21:37:52 +0100 | <monochrom> | However! I reckon that if you seek also being parametric in the functor f, things may be more unique. |
2022-02-04 21:37:54 +0100 | MatthiasG2 | (~matthias@i6DFA038C.versanet.de) |
2022-02-04 21:39:17 +0100 | tavares | (~tavares@user/tavares) (Ping timeout: 240 seconds) |
2022-02-04 21:39:38 +0100 | <monochrom> | "This is going to be fun" |
2022-02-04 21:40:01 +0100 | vandito | (~vandito@131.0.224.113) |
2022-02-04 21:42:41 +0100 | tatarqa | (~kli@ip-89-177-122-45.net.upcbroadband.cz) (Quit: Leaving) |
2022-02-04 21:45:55 +0100 | vandito | (~vandito@131.0.224.113) (Quit: vandito) |
2022-02-04 21:46:30 +0100 | tavares | (~tavares@187.19.213.50) |
2022-02-04 21:49:49 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) (Remote host closed the connection) |
2022-02-04 21:50:03 +0100 | <zzz> | at https://hoggle.haskell.org it reads "... The Hoogle manual contains more details, including further details on search |
2022-02-04 21:50:06 +0100 | <zzz> | queries, how to install Hoogle as a command line application and how to |
2022-02-04 21:50:10 +0100 | <zzz> | integrate Hoogle with Firefox/Emacs/Vim etc." |
2022-02-04 21:50:44 +0100 | <zzz> | but i can't seem to find anything about vim |
2022-02-04 21:51:40 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) |
2022-02-04 21:52:30 +0100 | shapr | (~user@pool-173-73-44-186.washdc.fios.verizon.net) (Remote host closed the connection) |
2022-02-04 21:54:52 +0100 | [itchyjunk] | (~itchyjunk@user/itchyjunk/x-7353470) (Read error: Connection reset by peer) |
2022-02-04 21:59:39 +0100 | <lyxia> | monochrom: I meant that for the specific implementation in Data.Contravariant.Functor. To generalize, you'd want to add the law (phantom @f @a @a = id) to rule out such counterexamples. |
2022-02-04 22:00:36 +0100 | slac63591 | (~slack1256@186.11.28.67) (Remote host closed the connection) |
2022-02-04 22:01:19 +0100 | <ski> | `phantom @f @a @a' ? |
2022-02-04 22:01:36 +0100 | [exa] | (exa@user/exa/x-3587197) |
2022-02-04 22:12:54 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) |
2022-02-04 22:15:55 +0100 | wavemode | (~wavemode@2601:241:0:fc90:e107:b5f8:8bcd:8e3a) |
2022-02-04 22:16:17 +0100 | tavares | (~tavares@187.19.213.50) (Ping timeout: 240 seconds) |
2022-02-04 22:17:17 +0100 | yauhsien | (~yauhsien@61-231-25-133.dynamic-ip.hinet.net) (Ping timeout: 240 seconds) |
2022-02-04 22:17:27 +0100 | Erutuon | (~Erutuon@user/erutuon) (Ping timeout: 256 seconds) |
2022-02-04 22:19:11 +0100 | <sprout_> | https://twitter.com/andre_videla/status/1489680094339682308?s=20&t=FG02BMLwxD2K_Sci1ulVag |
2022-02-04 22:20:03 +0100 | takuan | (~takuan@178-116-218-225.access.telenet.be) (Ping timeout: 256 seconds) |
2022-02-04 22:22:25 +0100 | <lyxia> | ski: TypeApplications for phantom :: forall f a b. (...) => f a -> f b ? |
2022-02-04 22:23:26 +0100 | <ski> | i'd presume so ? |
2022-02-04 22:23:47 +0100 | mikoto-chan | (~mikoto-ch@213.177.151.239) (Ping timeout: 256 seconds) |
2022-02-04 22:23:53 +0100 | vandito | (~vandito@131.0.224.113) |
2022-02-04 22:24:11 +0100 | <ski> | oh, actually, just realized i misread you. nevermind then, carry on |
2022-02-04 22:25:07 +0100 | g | (x@libera/staff/glguy) (Quit: g) |
2022-02-04 22:25:08 +0100 | glguy | (x@libera/staff/glguy) (Quit: Quit) |
2022-02-04 22:25:46 +0100 | Erutuon | (~Erutuon@user/erutuon) |
2022-02-04 22:26:02 +0100 | vandito | (~vandito@131.0.224.113) (Client Quit) |
2022-02-04 22:34:57 +0100 | tavares | (~tavares@187.19.213.50) |
2022-02-04 22:48:03 +0100 | doxen | (~bbrahms@pool-173-54-217-168.nwrknj.fios.verizon.net) (Ping timeout: 256 seconds) |
2022-02-04 22:50:29 +0100 | glguy | (x@libera/staff/glguy) |
2022-02-04 22:53:20 +0100 | MoC | (~moc@user/moc) (Quit: Konversation terminated!) |
2022-02-04 22:53:24 +0100 | <monochrom> | Wow conformal mappings of commuting diagrams |
2022-02-04 22:57:50 +0100 | <byorgey> | DDDUDUDUUDDDUUUU <--- what monadic zombies say when they come for your brains |
2022-02-04 22:59:43 +0100 | <monochrom> | Are humans data as to zombies are co-data? |
2022-02-04 23:03:00 +0100 | <EvanR> | human mortal, data finite. Zombie potentially immortal but they can still be terminated (headshot) |
2022-02-04 23:03:19 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) (Remote host closed the connection) |
2022-02-04 23:03:30 +0100 | <EvanR> | so yes |
2022-02-04 23:03:35 +0100 | <monochrom> | :) |
2022-02-04 23:04:38 +0100 | <EvanR> | michael myers would have to be Stream HalloweenSequels though |
2022-02-04 23:05:06 +0100 | geekosaur | (~geekosaur@xmonad/geekosaur) |
2022-02-04 23:07:17 +0100 | tavares | (~tavares@187.19.213.50) (Ping timeout: 240 seconds) |
2022-02-04 23:08:07 +0100 | glguy | (x@libera/staff/glguy) (Quit: Quit) |
2022-02-04 23:11:08 +0100 | glguy | (x@libera/staff/glguy) |
2022-02-04 23:13:31 +0100 | ProfSimm | (~ProfSimm@87.227.196.109) (Remote host closed the connection) |
2022-02-04 23:13:41 +0100 | ProfSimm | (~ProfSimm@87.227.196.109) |
2022-02-04 23:14:25 +0100 | glguy | (x@libera/staff/glguy) (Read error: Connection reset by peer) |
2022-02-04 23:16:42 +0100 | glguy | (x@libera/staff/glguy) |
2022-02-04 23:18:00 +0100 | deadmarshal | (~deadmarsh@95.38.113.90) (Ping timeout: 250 seconds) |
2022-02-04 23:20:53 +0100 | jgeerds | (~jgeerds@55d4a547.access.ecotel.net) |
2022-02-04 23:22:12 +0100 | CiaoSen | (~Jura@p200300c95737a2002a3a4dfffe84dbd5.dip0.t-ipconnect.de) |
2022-02-04 23:22:17 +0100 | deadmarshal | (~deadmarsh@95.38.114.62) |
2022-02-04 23:22:42 +0100 | gehmehgeh | (~user@user/gehmehgeh) (Quit: Leaving) |
2022-02-04 23:23:34 +0100 | michalz2 | (~michalz2@185.246.204.89) (Remote host closed the connection) |
2022-02-04 23:23:34 +0100 | michalz | (~michalz@185.246.204.75) (Remote host closed the connection) |
2022-02-04 23:23:45 +0100 | MatthiasG2 | (~matthias@i6DFA038C.versanet.de) (Ping timeout: 256 seconds) |
2022-02-04 23:25:36 +0100 | MatthiasG2 | (~matthias@i6DFA03D9.versanet.de) |
2022-02-04 23:28:44 +0100 | waleee | (~waleee@h-98-128-229-110.NA.cust.bahnhof.se) (Quit: WeeChat 3.4) |
2022-02-04 23:28:44 +0100 | [exa] | (exa@user/exa/x-3587197) (Read error: Connection reset by peer) |
2022-02-04 23:29:45 +0100 | wootehfoot | (~wootehfoo@user/wootehfoot) (Ping timeout: 256 seconds) |
2022-02-04 23:29:57 +0100 | zebrag | (~chris@user/zebrag) (Ping timeout: 240 seconds) |
2022-02-04 23:30:22 +0100 | zebrag | (~chris@user/zebrag) |
2022-02-04 23:31:13 +0100 | machinedgod | (~machinedg@24.105.81.50) (Ping timeout: 256 seconds) |
2022-02-04 23:33:09 +0100 | nitrix | (~nitrix@user/nitrix) (Ping timeout: 256 seconds) |
2022-02-04 23:34:17 +0100 | lbseale | (~ep1ctetus@user/ep1ctetus) (Ping timeout: 256 seconds) |
2022-02-04 23:34:39 +0100 | waleee | (~waleee@2001:9b0:21d:fc00:398f:b003:b90d:acf4) |
2022-02-04 23:36:00 +0100 | <qrpnxz> | i'm using ghcup, 9.0 working fine, 9.2 not finding modules i install for some reason, i can't figure out the difference |
2022-02-04 23:37:00 +0100 | <monochrom> | Library binaries built for one GHC version cannot be reused by another GHC version. This has always been the case. |
2022-02-04 23:37:10 +0100 | nitrix | (~nitrix@user/nitrix) |
2022-02-04 23:37:44 +0100 | <qrpnxz> | i did reinstall the libs with cabal after switching, they have entries in the environment file for 9.2 |
2022-02-04 23:37:51 +0100 | <qrpnxz> | idk if there's something else i have to do |
2022-02-04 23:38:18 +0100 | <monochrom> | Steve Jobs was greatly inspired by this, and invented the slogan "This changes everything. Again." at every iPhone release. >:) |
2022-02-04 23:40:54 +0100 | <qrpnxz> | even on `cabal repl` not able to load libraries i have imported on my .ghci |
2022-02-04 23:42:29 +0100 | lavaman | (~lavaman@98.38.249.169) (Remote host closed the connection) |
2022-02-04 23:43:02 +0100 | gawen | (~gawen@user/gawen) |
2022-02-04 23:43:11 +0100 | <maerwald> | qrpnxz: are you on archlinux? |
2022-02-04 23:43:27 +0100 | <qrpnxz> | i'm on Debian bookworm |
2022-02-04 23:43:35 +0100 | gawen_ | (~gawen@user/gawen) (Ping timeout: 256 seconds) |
2022-02-04 23:43:40 +0100 | <qrpnxz> | (testing) |
2022-02-04 23:44:29 +0100 | <qrpnxz> | cabal/store/ghc-9.2.1 has packages |
2022-02-04 23:45:03 +0100 | deadmarshal | (~deadmarsh@95.38.114.62) (Ping timeout: 256 seconds) |
2022-02-04 23:49:15 +0100 | <maerwald> | great... 9.2.1 needs libnuma again |
2022-02-04 23:49:24 +0100 | <maerwald> | build system bugs from 5 years ago reappear |
2022-02-04 23:49:33 +0100 | ProfSimm | (~ProfSimm@87.227.196.109) (Remote host closed the connection) |
2022-02-04 23:49:35 +0100 | mc47 | (~mc47@xmonad/TheMC47) (Remote host closed the connection) |
2022-02-04 23:50:17 +0100 | <qrpnxz> | compile bot on a discord server i use can't compile haskell for a libnuma thing |
2022-02-04 23:50:20 +0100 | <qrpnxz> | idk what it is |
2022-02-04 23:51:35 +0100 | nitrix | (~nitrix@user/nitrix) (Quit: ZNC 1.8.2 - https://znc.in) |
2022-02-04 23:51:46 +0100 | <maerwald> | some optional library turned mandatory due to a build system bug |
2022-02-04 23:52:06 +0100 | <qrpnxz> | shucks |
2022-02-04 23:52:34 +0100 | <qrpnxz> | ok, i'm just gonna go back to 9.0 because i can't figure this out. |
2022-02-04 23:52:34 +0100 | nitrix | (~nitrix@user/nitrix) |
2022-02-04 23:55:38 +0100 | <maerwald> | 9.2.1 works on bookworm here |
2022-02-04 23:55:52 +0100 | <maerwald> | I tried `cabal repl --build-depends aeson` and could import modules |
2022-02-04 23:57:47 +0100 | <qrpnxz> | with 9.0 i can just do import, then compile like `ghc main.hs` and it works, i can import stuff in my .ghci, and it will just work, sure i could create a whole cabal project, that might work (hopefully), but i don't want to bother right now when 9.0 just works |
2022-02-04 23:58:14 +0100 | <qrpnxz> | no --build-depends required in 9.0 |
2022-02-04 23:59:05 +0100 | <maerwald> | use build-depends |
2022-02-04 23:59:06 +0100 | <qrpnxz> | i think i remember having to add the libs to my environment to get it to do that, but they are already there, so i can't think of anything else |