Logs: liberachat/#haskell
| 2021-07-03 12:57:03 | <tomsmeding> | yes my editor can select things |
| 2021-07-03 12:57:43 | → | favonia joins (~favonia@user/favonia) |
| 2021-07-03 12:58:06 | <tomsmeding> | and then round up the selection to the smallest AST node that contains the source range or something |
| 2021-07-03 13:00:06 | <tomsmeding> | juri_: do you mean the _smallest_ value _larger_ than X? |
| 2021-07-03 13:00:17 | <juri_> | tomsmeding: aparently. :) |
| 2021-07-03 13:00:31 | <tomsmeding> | what about: fromIntegral (ceiling (X / Y)) * Y |
| 2021-07-03 13:00:48 | <juri_> | that's where i was going. :) |
| 2021-07-03 13:01:12 | → | alx741 joins (~alx741@186.178.109.174) |
| 2021-07-03 13:01:31 | → | fendor joins (~fendor@77.119.220.92.wireless.dyn.drei.com) |
| 2021-07-03 13:01:37 | → | nate1 joins (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) |
| 2021-07-03 13:01:38 | × | shailangsa quits (~shailangs@host86-186-196-229.range86-186.btcentralplus.com) (Ping timeout: 252 seconds) |
| 2021-07-03 13:01:46 | <juri_> | tho, i think that's supposed to be fromIntegral (ceiling (X*Y) +1 ) * Y |
| 2021-07-03 13:01:47 | <juri_> | ? |
| 2021-07-03 13:01:51 | juri_ | ponders. |
| 2021-07-03 13:02:05 | <juri_> | er. / Y, rather. |
| 2021-07-03 13:02:09 | <tomsmeding> | either ceiling (X / Y) or floor (X / Y) + 1 |
| 2021-07-03 13:02:21 | <tomsmeding> | depending if you want >=X or >X |
| 2021-07-03 13:03:07 | <juri_> | aha. of course. thanks. |
| 2021-07-03 13:04:05 | ← | tzar_bomba parts (~tzar_bomb@user/tzar-bomba/x-5218718) () |
| 2021-07-03 13:05:00 | → | dunkeln_ joins (~dunkeln@188.70.10.165) |
| 2021-07-03 13:05:39 | → | Deide joins (~Deide@wire.desu.ga) |
| 2021-07-03 13:05:39 | × | Deide quits (~Deide@wire.desu.ga) (Changing host) |
| 2021-07-03 13:05:39 | → | Deide joins (~Deide@user/deide) |
| 2021-07-03 13:07:54 | × | nate1 quits (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds) |
| 2021-07-03 13:09:18 | <tomsmeding> | tangentially related trick: ceil-division on _integers_ a and b can be implemented as (a + b - 1) `div` b, for anyone who didn't already know about that |
| 2021-07-03 13:13:40 | → | tose joins (~tose@ip-85-160-2-70.eurotel.cz) |
| 2021-07-03 13:13:46 | × | acidjnk_new quits (~acidjnk@p200300d0c72b953339f341015709cf67.dip0.t-ipconnect.de) (Ping timeout: 256 seconds) |
| 2021-07-03 13:17:47 | × | noctux quits (~noctux@user/noctux) (Remote host closed the connection) |
| 2021-07-03 13:17:54 | × | feliix42 quits (~felix@gibbs.uberspace.de) (Quit: ZNC 1.8.2 - https://znc.in) |
| 2021-07-03 13:18:19 | ← | jakalx parts (~jakalx@base.jakalx.net) (Error from remote client) |
| 2021-07-03 13:20:42 | × | arjun quits (~user@user/arjun) (Ping timeout: 252 seconds) |
| 2021-07-03 13:21:54 | → | feliix42 joins (~felix@gibbs.uberspace.de) |
| 2021-07-03 13:23:00 | → | dyeplexer joins (~dyeplexer@user/dyeplexer) |
| 2021-07-03 13:24:53 | × | pavonia quits (~user@user/siracusa) (Quit: Bye!) |
| 2021-07-03 13:25:36 | → | noctux joins (~noctux@user/noctux) |
| 2021-07-03 13:26:40 | × | cheater quits (~Username@user/cheater) (Ping timeout: 258 seconds) |
| 2021-07-03 13:26:58 | → | cheater joins (~Username@user/cheater) |
| 2021-07-03 13:27:06 | × | favonia quits (~favonia@user/favonia) (Ping timeout: 240 seconds) |
| 2021-07-03 13:27:25 | → | favonia joins (~favonia@user/favonia) |
| 2021-07-03 13:27:27 | × | geekosaur quits (~geekosaur@xmonad/geekosaur) (Remote host closed the connection) |
| 2021-07-03 13:27:51 | → | geekosaur joins (~geekosaur@xmonad/geekosaur) |
| 2021-07-03 13:27:56 | → | mc47 joins (~mc47@xmonad/TheMC47) |
| 2021-07-03 13:29:57 | → | Guest9 joins (~Guest9@103.249.233.78) |
| 2021-07-03 13:29:59 | → | arjun joins (~user@160.202.37.228) |
| 2021-07-03 13:30:58 | × | arjun quits (~user@160.202.37.228) (Changing host) |
| 2021-07-03 13:30:58 | → | arjun joins (~user@user/arjun) |
| 2021-07-03 13:31:31 | → | warnz joins (~warnz@2600:1700:77c0:5610:20b2:48fc:c4b7:f8df) |
| 2021-07-03 13:31:54 | × | cheater quits (~Username@user/cheater) (Ping timeout: 256 seconds) |
| 2021-07-03 13:34:52 | → | wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) |
| 2021-07-03 13:35:00 | × | gawen quits (~gawen@user/gawen) (Quit: cya) |
| 2021-07-03 13:35:32 | <yorick> | can I somehow access the default class implementation when I'm overriding it? |
| 2021-07-03 13:36:33 | <yorick> | the neccesary things to make my own aren't exported by the module I'm using |
| 2021-07-03 13:37:56 | × | jao quits (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Ping timeout: 252 seconds) |
| 2021-07-03 13:38:44 | → | gawen joins (~gawen@user/gawen) |
| 2021-07-03 13:39:03 | × | fef quits (~thedawn@user/thedawn) (Ping timeout: 244 seconds) |
| 2021-07-03 13:40:28 | → | jneira_ joins (~jneira_@217.red-81-39-172.dynamicip.rima-tde.net) |
| 2021-07-03 13:42:40 | × | jippiedoe quits (~david@2a02-a44c-e14e-1-2351-c955-5b2d-b577.fixed6.kpn.net) (Ping timeout: 256 seconds) |
| 2021-07-03 13:43:00 | → | stevenxl joins (~stevenlei@68.235.43.109) |
| 2021-07-03 13:43:54 | × | wei2912 quits (~wei2912@112.199.250.21) (Quit: Lost terminal) |
| 2021-07-03 13:44:18 | × | favonia quits (~favonia@user/favonia) (Ping timeout: 240 seconds) |
| 2021-07-03 13:45:21 | → | fef joins (~thedawn@user/thedawn) |
| 2021-07-03 13:46:10 | → | cheater1__ joins (~Username@user/cheater) |
| 2021-07-03 13:46:37 | → | favonia joins (~favonia@user/favonia) |
| 2021-07-03 13:47:39 | <Axman6> | so, this feels like a dumb question, but is there a reasonably performant function to turn an Integer into a ByteString in base10? some form of pack . show would make me a bit sad, but if that's the easiest way I'll go wiht it |
| 2021-07-03 13:47:41 | <Axman6> | wiht* |
| 2021-07-03 13:47:50 | × | dunkeln_ quits (~dunkeln@188.70.10.165) (Ping timeout: 252 seconds) |
| 2021-07-03 13:48:57 | <Axman6> | I'm just going to leave that one -_- |
| 2021-07-03 13:49:37 | <tomsmeding> | Axman6: is it performance-relevant code :p |
| 2021-07-03 13:50:46 | × | cheater1__ quits (~Username@user/cheater) (Ping timeout: 252 seconds) |
| 2021-07-03 13:51:32 | → | shapr joins (~user@pool-100-36-247-68.washdc.fios.verizon.net) |
| 2021-07-03 13:51:56 | <Axman6> | it... might be, eventually |
| 2021-07-03 13:52:14 | <Axman6> | I guess when that day comes, and the profiler says "Show is expensive!" I will make a change |
| 2021-07-03 13:53:26 | <tomsmeding> | a while ago I was parsing large (multi-megabyte; apparently that's large) files of floating-point numbers using haskell; then I found out that Read-ing floats is bloody expensive |
| 2021-07-03 13:53:54 | <tomsmeding> | even with a dedicated float parser from a bytestring it was still slower than C I believe |
| 2021-07-03 13:54:13 | <Axman6> | yeah, doesn't surprise me too much. IIRC Scientific's parsing is pretty decent |
| 2021-07-03 13:54:29 | → | dunkeln joins (~dunkeln@188.70.10.165) |
| 2021-07-03 13:54:37 | <Axman6> | actuallty, maybe not |
| 2021-07-03 13:54:57 | <tomsmeding> | I'm currently using bytestring-lexing |
| 2021-07-03 13:55:03 | <Axman6> | I remember reading years ago about PHP's float parsing being really fast, but there was a specific string that would put into an infinite loop |
| 2021-07-03 13:55:12 | <tomsmeding> | it's good enough for the purpose currently but it leaves a sour taste :p |
| 2021-07-03 13:55:18 | <tomsmeding> | lol |
| 2021-07-03 13:55:22 | <tomsmeding> | good old php |
| 2021-07-03 13:56:28 | <Axman6> | https://www.exploringbinary.com/php-hangs-on-numeric-value-2-2250738585072011e-308/ |
| 2021-07-03 13:58:34 | → | stevenxl_ joins (~stevenlei@68.235.43.165) |
| 2021-07-03 14:00:51 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 2021-07-03 14:00:59 | <Axman6> | I'm sure I've read something about fast floating point number parsing in Haskell but I can't remember where. wouldn't susprise me if it was something bos wrote |
| 2021-07-03 14:01:46 | × | stevenxl quits (~stevenlei@68.235.43.109) (Ping timeout: 252 seconds) |
| 2021-07-03 14:02:41 | <tomsmeding> | interesting link |
| 2021-07-03 14:03:39 | <adamse> | https://lemire.me has some good reading on both integers and floats parsing somewhere, not in haskell though (yet..) |
| 2021-07-03 14:03:46 | → | raehik joins (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) |
| 2021-07-03 14:04:25 | × | peterhil quits (~peterhil@dsl-hkibng32-54f849-252.dhcp.inet.fi) (Ping timeout: 265 seconds) |
| 2021-07-03 14:06:11 | <adamse> | https://lemire.me/blog/2021/01/29/number-parsing-at-a-gigabyte-per-second/ for floats |
| 2021-07-03 14:07:33 | → | jakalx joins (~jakalx@base.jakalx.net) |
| 2021-07-03 14:07:40 | → | zebrag joins (~chris@user/zebrag) |
| 2021-07-03 14:08:55 | <tomsmeding> | lol bytestring-lexing doesn't even try to be intelligent with float parsing I now see |
| 2021-07-03 14:09:17 | <tomsmeding> | it parses two integers and does some exponentiation and adding |
| 2021-07-03 14:09:30 | × | favonia quits (~favonia@user/favonia) (Ping timeout: 240 seconds) |
| 2021-07-03 14:09:49 | → | favonia joins (~favonia@user/favonia) |
| 2021-07-03 14:12:12 | → | fendor_ joins (~fendor@178.115.131.211.wireless.dyn.drei.com) |
| 2021-07-03 14:12:14 | × | aplainzetakind quits (~johndoe@captainludd.powered.by.lunarbnc.net) (Read error: Connection reset by peer) |
All times are in UTC.