Home liberachat/#haskell: Logs Calendar

Logs: liberachat/#haskell

←Prev  Next→
Page 1 .. 905 906 907 908 909 910 911 912 913 914 915 .. 18027
1,802,658 events total
2021-07-11 14:30:02 mikail_ joins (~mikail@2a02:c7f:bd83:fd00:55cf:122f:957a:f66f)
2021-07-11 14:32:22 yauhsien joins (~yauhsien@118-167-64-241.dynamic-ip.hinet.net)
2021-07-11 14:34:17 × turlando quits (~turlando@user/turlando) (Remote host closed the connection)
2021-07-11 14:34:43 Pickchea joins (~private@user/pickchea)
2021-07-11 14:35:47 turlando joins (~turlando@93-42-250-112.ip89.fastwebnet.it)
2021-07-11 14:35:47 × turlando quits (~turlando@93-42-250-112.ip89.fastwebnet.it) (Changing host)
2021-07-11 14:35:47 turlando joins (~turlando@user/turlando)
2021-07-11 14:37:03 × yauhsien quits (~yauhsien@118-167-64-241.dynamic-ip.hinet.net) (Ping timeout: 265 seconds)
2021-07-11 14:38:52 × kadobanana quits (~mud@user/kadoban) (Ping timeout: 268 seconds)
2021-07-11 14:46:19 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
2021-07-11 14:50:14 yauhsien joins (~yauhsien@118-167-64-241.dynamic-ip.hinet.net)
2021-07-11 14:51:04 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:6d00:2ab2:6519:235b)
2021-07-11 14:51:09 × jonathanx quits (~jonathan@94.234.33.210) (Remote host closed the connection)
2021-07-11 14:51:26 jonathanx joins (~jonathan@94.234.33.210)
2021-07-11 14:55:06 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:6d00:2ab2:6519:235b) (Ping timeout: 240 seconds)
2021-07-11 14:55:24 × yauhsien quits (~yauhsien@118-167-64-241.dynamic-ip.hinet.net) (Ping timeout: 272 seconds)
2021-07-11 14:57:48 × exilepilot quits (~exilepilo@2a00:23c4:ba88:fc01:68fe:19eb:6dd5:3e3e) (Quit: Leaving)
2021-07-11 14:57:49 zebrag joins (~chris@user/zebrag)
2021-07-11 14:58:36 × hyiltiz quits (~quassel@31.220.5.250) (Ping timeout: 268 seconds)
2021-07-11 14:59:36 hyiltiz joins (~quassel@31.220.5.250)
2021-07-11 14:59:51 × [exa] quits (exa@user/exa/x-3587197) (Ping timeout: 272 seconds)
2021-07-11 15:01:47 jess joins (~jess@libera/staff/jess)
2021-07-11 15:02:47 × Ariakenom quits (~Ariakenom@c83-255-154-140.bredband.tele2.se) (Read error: Connection reset by peer)
2021-07-11 15:04:07 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 265 seconds)
2021-07-11 15:04:27 anandprabhu joins (~anandprab@94.202.243.198)
2021-07-11 15:06:03 × sergal quits (~ezra@fsf/member/ezra) (Quit: bye bye)
2021-07-11 15:07:11 sergal joins (~sergal@fsf/member/ezra)
2021-07-11 15:13:06 × mjs2600 quits (~mjs2600@c-24-91-3-49.hsd1.vt.comcast.net) (Ping timeout: 256 seconds)
2021-07-11 15:15:13 oso joins (~oso@2601:58c:c080:a950:f275:2530:b398:680b)
2021-07-11 15:15:49 Guest12 joins (~Guest12@187.83.249.216.dyn.smithville.net)
2021-07-11 15:17:10 × Pickchea quits (~private@user/pickchea) (Ping timeout: 265 seconds)
2021-07-11 15:20:07 × fengctor quits (~fengctor@bras-base-ngflon0508w-grc-11-76-68-2-143.dsl.bell.ca) (Read error: Connection reset by peer)
2021-07-11 15:21:15 yauhsien joins (~yauhsien@118-167-64-241.dynamic-ip.hinet.net)
2021-07-11 15:25:40 × yauhsien quits (~yauhsien@118-167-64-241.dynamic-ip.hinet.net) (Ping timeout: 252 seconds)
2021-07-11 15:26:25 ahdyt joins (~ahdyt@36.80.188.104)
2021-07-11 15:27:04 × machinedgod quits (~machinedg@24.105.81.50) (Ping timeout: 272 seconds)
2021-07-11 15:29:25 econo joins (uid147250@user/econo)
2021-07-11 15:32:34 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:6d00:2ab2:6519:235b)
2021-07-11 15:33:38 × neceve quits (~quassel@2a02:c7f:607e:d600:f762:20dd:304e:4b1f) (Ping timeout: 255 seconds)
2021-07-11 15:33:43 kenran joins (~kenran@200116b82b619d0007bee3441e0dba70.dip.versatel-1u1.de)
2021-07-11 15:34:01 × Gurkenglas quits (~Gurkengla@dslb-002-203-144-156.002.203.pools.vodafone-ip.de) (Ping timeout: 246 seconds)
2021-07-11 15:34:59 × peterhil quits (~peterhil@dsl-hkibng32-54f849-252.dhcp.inet.fi) (Ping timeout: 268 seconds)
2021-07-11 15:35:29 <Athas> What is the most convenient type to use when you just want a plain one-dimensional zero-offset O(1) indexed array?
2021-07-11 15:35:43 <Athas> I feel Data.Array has too much boilerplate, but I can't really put my finger on it.
2021-07-11 15:36:42 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:6d00:2ab2:6519:235b) (Ping timeout: 240 seconds)
2021-07-11 15:37:57 <nshepperd2> Data.Vector
2021-07-11 15:38:39 <Athas> I guess... I've used Vector a lot for things that had to be fast and complex, but I haven't considered them for simple things.
2021-07-11 15:39:07 hnOsmium0001 joins (uid453710@id-453710.stonehaven.irccloud.com)
2021-07-11 15:41:04 × jonathanx quits (~jonathan@94.234.33.210) (Ping timeout: 252 seconds)
2021-07-11 15:42:20 <albet70> https://stackoverflow.com/questions/4020419/why-arent-python-nested-functions-called-closures
2021-07-11 15:42:43 <albet70> about closure, could haskell define functions inside function?
2021-07-11 15:43:35 peterhil joins (~peterhil@mobile-access-5672d5-10.dhcp.inet.fi)
2021-07-11 15:43:48 <Guest12> you can compose and use lambdas and use where/let...and you can define functions which mutually reference each other
2021-07-11 15:43:55 <albet70> python and js use function define inside a function, that inner function visit enclosed variable and outer function return that inner function
2021-07-11 15:45:09 <albet70> but lambda couldn't change enclosed variable
2021-07-11 15:45:25 × Pixi quits (~Pixi@user/pixi) (Quit: Leaving)
2021-07-11 15:45:40 <albet70> and variable are constant in haskell
2021-07-11 15:48:53 <albet70> non-local variable they call it
2021-07-11 15:51:35 <Guest12> i don't think the concept/question makes sense in haskell, at least to me
2021-07-11 15:54:43 <yin[m]> how do i find a value from a map while getting it's key? something like findMap :: (a -> Bool) -> Map k a -> k
2021-07-11 15:55:41 <Guest93> should I use ByteString? I want to represent blobs of data (like contents of relatively small files)
2021-07-11 15:55:59 <albet70> but it may not be on k, how u handle that?
2021-07-11 15:56:15 <albet70> one k
2021-07-11 15:56:20 <Guest93> it seems to be a stand-alone package so I'm wondering if there is something more integrated with Haskell that I should be using
2021-07-11 15:56:45 <yin[m]> ... -> Maybe k
2021-07-11 15:56:49 finsternis joins (~X@23.226.237.192)
2021-07-11 15:57:05 <albet70> [Maybe k]
2021-07-11 15:57:17 <yin[m]> that would work too
2021-07-11 15:57:29 <dmj`> Guest93: bytestring is a boot package, so its pretty well integrated
2021-07-11 15:57:36 <geekosaur> Guest93, Haskell doesn't do a monolithic base system, practically everything is an add-on package
2021-07-11 15:57:54 <Guest93> ok I will use bytestring
2021-07-11 15:58:10 <Guest93> [k] I think .. no need for Maybe when returning a list
2021-07-11 15:58:22 jonathanx joins (~jonathan@94.234.33.210)
2021-07-11 15:58:24 <dmj`> Guest93: you can use text too if your files are UTF8/16 encoded
2021-07-11 15:58:35 <Guest93> nah I don't want to assume that
2021-07-11 16:00:41 <albet70> yin[m] use snd to take out that value out of pair, then compare to get the key u want
2021-07-11 16:01:10 Pickchea joins (~private@user/pickchea)
2021-07-11 16:01:25 <dmj`> :t \val xs -> fmap fst . listToMaybe . Data.Map.toList . Data.Map.filter (==val)
2021-07-11 16:01:26 <lambdabot> Eq b1 => b1 -> p -> M.Map b2 b1 -> Maybe b2
2021-07-11 16:02:08 <dmj`> :t \val xs -> fmap fst . Data.Map.toList . Data.Map.filter (==val)
2021-07-11 16:02:09 <lambdabot> Eq b1 => b1 -> p -> M.Map b2 b1 -> [b2]
2021-07-11 16:02:29 Gurkenglas joins (~Gurkengla@dslb-002-203-144-156.002.203.pools.vodafone-ip.de)
2021-07-11 16:03:05 <yin[m]> thqt seems terribly inefficient
2021-07-11 16:03:45 <monochrom> There is no log-time algorithm for your problem.
2021-07-11 16:04:06 <s__> yin[m] You need to maintain two maps
2021-07-11 16:04:12 <albet70> yes, inefficient, but it came first
2021-07-11 16:04:15 <yin[m]> isn't it?
2021-07-11 16:04:33 <albet70> dmj` is better
2021-07-11 16:05:50 <monochrom> But it is better to use list's filter (enjoys fusion) than Map's filter (compulsory intermediate binary search tree).
2021-07-11 16:06:15 <dmj`> has to be at least linear unless two maps are used, but two maps assumes a bijective relationship
2021-07-11 16:07:09 <s__> second map could be Map value (Set key)
2021-07-11 16:07:11 <nshepperd2> if you're just looking up a value (you don't need arbitrary a -> Bool) then a reverse lookup index will work
2021-07-11 16:07:46 <monochrom> a->Bool is very arbitrary
2021-07-11 16:07:57 <monochrom> Premature generalization is the root of premature optimization.
2021-07-11 16:09:30 <albet70> Eq a -> a?
2021-07-11 16:10:30 <oso> is there a way to force evaluation of a Data.Map at time of creation? I'm building a map to create search partitions and want the overhead of creation to be at time of definition and not during the first search
2021-07-11 16:10:51 <oso> I've tried Data.Map.Strict, BangPatterns, and DeepSeq to no avail
2021-07-11 16:11:35 <EvanR> Data.Map.Strict, then you need to make sure you evaluate the map itself to get the creation to happen
2021-07-11 16:12:15 <EvanR> like, you assign it to a strict field, or a bang patterned variable etc
2021-07-11 16:12:27 <oso> Okay I'll give it a shot, thanks!

All times are in UTC.