Logs: freenode/#haskell
| 2020-11-22 17:00:12 | <ski> | (oh, also `appFoo') |
| 2020-11-22 17:01:02 | → | MrSalt joins (DirefulSal@gateway/vpn/privateinternetaccess/direfulsalt) |
| 2020-11-22 17:01:12 | × | dirediresalt quits (DirefulSal@gateway/vpn/privateinternetaccess/direfulsalt) (Remote host closed the connection) |
| 2020-11-22 17:01:29 | → | andos joins (~dan@69-165-210-185.cable.teksavvy.com) |
| 2020-11-22 17:02:01 | <tomsmeding> | also the run*/exec*/eval* mess that mtl gives you |
| 2020-11-22 17:02:03 | <ski> | (punning for record fields (when matching/constructing) is another thing. but the punning present between the fields and the field extraction/selection/projection functions is also bad) |
| 2020-11-22 17:02:10 | → | sondr3 joins (~sondr3@cm-84.211.56.132.getinternet.no) |
| 2020-11-22 17:02:41 | → | kritzefitz joins (~kritzefit@212.86.56.80) |
| 2020-11-22 17:02:46 | <ski> | yea, although the `execFoo' and `evalFoo' don't tend to be raw projections, that i know of |
| 2020-11-22 17:03:52 | → | cosimone joins (~cosimone@2001:b07:ae5:db26:d849:743b:370b:b3cd) |
| 2020-11-22 17:04:06 | <ski> | (also, `Control.Monad.Cont' ought to export `evalCont = (`runCont` id)' and `evalContT = (`runContT` pure)' ..) |
| 2020-11-22 17:04:06 | <hekkaidekapus> | NoFieldSlectors is being implemented as we speak. Wholesale banning projections will be easier with that. |
| 2020-11-22 17:04:23 | → | phaul joins (~phaul@ruby/staff/phaul) |
| 2020-11-22 17:04:46 | <ski> | yes, i've got the memo for that :) |
| 2020-11-22 17:05:28 | <ski> | i think i'd possibly like an alternative syntax for projections, e.g. like in the MLs |
| 2020-11-22 17:05:56 | × | neiluj quits (~jco@unaffiliated/neiluj) (Ping timeout: 265 seconds) |
| 2020-11-22 17:06:10 | <hekkaidekapus> | That ship has also sailed for now, the community settled on RecordDotSyntax. |
| 2020-11-22 17:06:13 | → | Sonderblade joins (~helloman@94.191.153.49.mobile.tre.se) |
| 2020-11-22 17:06:31 | <ski> | so, instead of `x pt' : `#x pt' (SML) or `pt .x' (OCaml), or something along those lines |
| 2020-11-22 17:06:37 | → | DavidEichmann joins (~david@62.110.198.146.dyn.plus.net) |
| 2020-11-22 17:06:54 | <c_wraith> | RecordDotSyntax is an abomination that we really didn't need |
| 2020-11-22 17:07:07 | <ski> | (yea, i recall looking at `RecordDotSyntax', and not being particularly happy about it) |
| 2020-11-22 17:07:14 | × | stree quits (~stree@50-108-97-52.adr01.mskg.mi.frontiernet.net) (Quit: Caught exception) |
| 2020-11-22 17:07:22 | <hekkaidekapus> | c_wraith: No argument from me :D |
| 2020-11-22 17:07:31 | → | stree joins (~stree@50-108-97-52.adr01.mskg.mi.frontiernet.net) |
| 2020-11-22 17:07:51 | <ski> | (the postfix is nice. yet another overloading of the dot is not) |
| 2020-11-22 17:07:55 | × | Sonderblade quits (~helloman@94.191.153.49.mobile.tre.se) (Client Quit) |
| 2020-11-22 17:08:00 | hekkaidekapus | guesses we are in the ‘looser’ camp ;) |
| 2020-11-22 17:08:26 | <tomsmeding> | is RecordDotSyntax the intended alternative syntax for projections if you enable NoFieldSelectors? |
| 2020-11-22 17:09:36 | <hekkaidekapus> | tomsmeding: If I’m not mistaken, all new record extensions are being implemented so that they interact well with each other. |
| 2020-11-22 17:09:37 | <ski> | (the postfix would be especially nice with "message-dispatching"/"copattern" syntax) |
| 2020-11-22 17:09:57 | <tomsmeding> | hekkaidekapus: that's what one would hope :p |
| 2020-11-22 17:10:10 | <c_wraith> | NoFieldSelectors is amazing for generic-lens, so I'm happy with it |
| 2020-11-22 17:10:44 | × | caef^ quits (caef@ip98-184-89-2.mc.at.cox.net) () |
| 2020-11-22 17:10:47 | <hekkaidekapus> | tomsmeding: I have the bookmark, hooray! <https://gitlab.haskell.org/ghc/ghc/-/issues/18598> |
| 2020-11-22 17:11:11 | <merijn> | c_wraith: NoFieldSelectors is great for having records in sumtypes too |
| 2020-11-22 17:11:16 | × | phaul quits (~phaul@ruby/staff/phaul) (Ping timeout: 240 seconds) |
| 2020-11-22 17:12:12 | <tomsmeding> | hekkaidekapus: ah those three extensions are the ones we're getting? |
| 2020-11-22 17:12:39 | <merijn> | tomsmeding: The intention of NoFieldSelectors is "no projections" |
| 2020-11-22 17:12:46 | <hekkaidekapus> | Yep, you get one, you loose one too ;) |
| 2020-11-22 17:12:53 | <tomsmeding> | is it, or is it "allow alternative projections"? |
| 2020-11-22 17:13:07 | <merijn> | tomsmeding: You can already write your own projections |
| 2020-11-22 17:13:20 | <tomsmeding> | okay fair, s/alternative/alternative auto-generated/ |
| 2020-11-22 17:13:31 | <merijn> | tomsmeding: The problem with field selectors is that you basically can't safely use records for sumtypes |
| 2020-11-22 17:13:39 | <merijn> | tomsmeding: Since your projections will be partial |
| 2020-11-22 17:13:45 | <tomsmeding> | very true, but they're sometimes handy for pure product types |
| 2020-11-22 17:13:55 | <merijn> | Which sucks, because there are many reasons to want record syntax for constructing/destructing even for sum types |
| 2020-11-22 17:14:10 | × | Guest42 quits (56ca6780@gateway/web/cgi-irc/kiwiirc.com/ip.86.202.103.128) (Quit: Connection closed) |
| 2020-11-22 17:14:26 | → | Guest42 joins (56ca6780@gateway/web/cgi-irc/kiwiirc.com/ip.86.202.103.128) |
| 2020-11-22 17:14:26 | × | gxt quits (~gxt@gateway/tor-sasl/gxt) (Remote host closed the connection) |
| 2020-11-22 17:14:37 | <tomsmeding> | mind, I'm not arguing _against_ any of this, just trying to understand the intention :p |
| 2020-11-22 17:14:58 | <merijn> | The intention is "both" |
| 2020-11-22 17:15:11 | → | gxt joins (~gxt@gateway/tor-sasl/gxt) |
| 2020-11-22 17:15:52 | <tomsmeding> | makes sense |
| 2020-11-22 17:16:57 | → | Tsumo joins (~sven@2607:fea8:4f00:5080:40b5:f43c:9b6e:442e) |
| 2020-11-22 17:17:43 | ← | Tsumo parts (~sven@2607:fea8:4f00:5080:40b5:f43c:9b6e:442e) () |
| 2020-11-22 17:21:23 | <sondr3> | I'm writing a parser with megaparsec and I'm having some trouble getting a part of it to work; I want to parse multiple lines either to EOF or untill a line begins with a certain sequence of chars |
| 2020-11-22 17:22:51 | × | cads quits (~cads@ip-64-72-99-232.lasvegas.net) (Read error: Connection reset by peer) |
| 2020-11-22 17:23:30 | <sondr3> | Right now I have `T.pack <$> many anySingle <* notFollowedBy (string b <|> string ("\n" <> b))` but it still includes the `b` in the parsed text |
| 2020-11-22 17:23:52 | × | sagax quits (~sagax_nb@213.138.71.146) (Read error: Connection reset by peer) |
| 2020-11-22 17:24:22 | → | phaul joins (~phaul@ruby/staff/phaul) |
| 2020-11-22 17:26:52 | × | emfipp quits (~emfipp@unaffiliated/mjkr) (Quit: Going offline, see ya! (www.adiirc.com)) |
| 2020-11-22 17:30:04 | j | is now known as jess |
| 2020-11-22 17:31:05 | × | phaul quits (~phaul@ruby/staff/phaul) (Remote host closed the connection) |
| 2020-11-22 17:31:13 | × | czwartyeon quits (~czwartyeo@77-45-55-99.sta.asta-net.com.pl) (Ping timeout: 256 seconds) |
| 2020-11-22 17:31:30 | → | oish joins (~charlie@228.25.169.217.in-addr.arpa) |
| 2020-11-22 17:31:41 | → | czwartyeon joins (~czwartyeo@77-45-55-99.sta.asta-net.com.pl) |
| 2020-11-22 17:31:49 | → | phaul joins (~phaul@ruby/staff/phaul) |
| 2020-11-22 17:33:57 | → | Lycurgus joins (~niemand@98.4.114.74) |
| 2020-11-22 17:35:28 | × | acarrico quits (~acarrico@dhcp-68-142-39-249.greenmountainaccess.net) (Ping timeout: 260 seconds) |
| 2020-11-22 17:35:58 | × | czwartyeon quits (~czwartyeo@77-45-55-99.sta.asta-net.com.pl) (Ping timeout: 246 seconds) |
| 2020-11-22 17:40:29 | → | czwartyeon joins (~czwartyeo@77-45-55-99.sta.asta-net.com.pl) |
| 2020-11-22 17:40:49 | × | Fractalis quits (~Fractalis@2601:987:280:8d40:eda9:f9e1:2072:cea7) (Quit: Goodbye Everyone!) |
| 2020-11-22 17:41:14 | → | Fractalis joins (~Fractalis@2601:987:280:8d40:eda9:f9e1:2072:cea7) |
| 2020-11-22 17:41:50 | → | geekosaur joins (82659a09@host154-009.vpn.uakron.edu) |
| 2020-11-22 17:41:55 | × | phaul quits (~phaul@ruby/staff/phaul) (Ping timeout: 246 seconds) |
| 2020-11-22 17:42:31 | × | cosimone quits (~cosimone@2001:b07:ae5:db26:d849:743b:370b:b3cd) (Quit: cosimone) |
| 2020-11-22 17:42:49 | → | cosimone joins (~cosimone@5.170.242.170) |
| 2020-11-22 17:47:21 | → | elliott__ joins (~elliott@pool-108-51-141-12.washdc.fios.verizon.net) |
| 2020-11-22 17:49:28 | × | czwartyeon quits (~czwartyeo@77-45-55-99.sta.asta-net.com.pl) (Ping timeout: 260 seconds) |
| 2020-11-22 17:50:32 | → | alp joins (~alp@2a01:e0a:58b:4920:4da5:6445:b4de:973) |
| 2020-11-22 17:50:53 | <tomsmeding> | sondr3: not very familiar with megaparsec (only parsec), but this would be a use for manyTill, right? |
| 2020-11-22 17:51:23 | <tomsmeding> | also is megaparsec's `string` fixed in that it either succeeds as a whole or fails as a whole? With parsec you have to write `try (string b)` |
| 2020-11-22 17:51:23 | × | Guest42 quits (56ca6780@gateway/web/cgi-irc/kiwiirc.com/ip.86.202.103.128) (Quit: Connection closed) |
| 2020-11-22 17:51:35 | <merijn> | This parser looks rather weird anyway |
| 2020-11-22 17:51:47 | → | Guest42 joins (56ca6780@gateway/web/cgi-irc/kiwiirc.com/ip.86.202.103.128) |
| 2020-11-22 17:51:47 | <merijn> | "many anySingle" will just literally eat all your input |
| 2020-11-22 17:51:54 | <merijn> | Which can't be what you intended |
| 2020-11-22 17:52:48 | <tomsmeding> | (also, your usage of <|> suggests that you don't know whether anySingle consumes the final newline or not; if it does, use `string b`, otherwise use `string ("\n" <> b)` :p) |
| 2020-11-22 17:53:05 | <sondr3> | yeah, it's even worse now, I haven't been able to figure out how to write a "read anything unless the line starts with 'blah'" |
| 2020-11-22 17:53:10 | <tomsmeding> | (oh but it must, because otherwise it doesn't work at all) |
| 2020-11-22 17:53:32 | <tomsmeding> | sondr3: `manyTill anySingle (lookAhead (string b))` ? |
| 2020-11-22 17:53:50 | × | AlterEgo- quits (~ladew@124-198-158-163.dynamic.caiway.nl) (Quit: Leaving) |
| 2020-11-22 17:54:26 | <sondr3> | tomsmeding: THANK YOU, that worked |
| 2020-11-22 17:54:48 | <merijn> | tomsmeding: I think lookahead consumes input on failure, though? Which may or may not be relevant |
| 2020-11-22 17:54:51 | <tomsmeding> | 'many' iterates until it sees input that its argument does not parse |
| 2020-11-22 17:55:21 | <tomsmeding> | merijn: correct, but perhaps that doesn't matter here because megaparsec's `string` is really parsec's `try . string`? |
| 2020-11-22 17:55:35 | → | jonatanb joins (jonatanb@gateway/vpn/protonvpn/jonatanb) |
| 2020-11-22 17:55:42 | <tomsmeding> | though I wouldn't know :p |
| 2020-11-22 17:56:10 | × | conal quits (~conal@198.8.81.205) (Quit: Computer has gone to sleep.) |
All times are in UTC.