Newest at the top
2024-12-28 18:19:43 +0100 | <monochrom> | Similarly, you can let Haskell do dynamic programming for you by using a lazy array/vector! |
2024-12-28 18:19:21 +0100 | Xe | (~Xe@perl/impostor/xe) (Quit: ZNC 1.9.1 - https://znc.in) |
2024-12-28 18:18:49 +0100 | <monochrom> | i.e., it is OK to have resolvable self reference such as: m = Map.fromList [(1, "a"), (2, (m!1) ++ "b"] |
2024-12-28 18:17:53 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-28 18:17:37 +0100 | acidjnk_new3 | (~acidjnk@p200300d6e7283f42bc4ebb891d7561a4.dip0.t-ipconnect.de) acidjnk |
2024-12-28 18:17:37 +0100 | <monochrom> | If you use Data.Map.Lazy, lazy evaluation will figure out the dependency for you. >:) |
2024-12-28 18:17:02 +0100 | <enikar> | remain to solve the dependency graph |
2024-12-28 18:15:05 +0100 | <enikar> | plitter: to solve I'd probably use a Map. The key will be variable name, and the value just the value of this variable ;) |
2024-12-28 18:13:26 +0100 | <monochrom> | Hot take: You don't even need overloaded record dot, you can just write "myrecord & myfield". |
2024-12-28 18:12:35 +0100 | <plitter> | Thanks everyone! AoC solved! |
2024-12-28 18:12:31 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-28 18:10:31 +0100 | stiell | (~stiell@gateway/tor-sasl/stiell) stiell |
2024-12-28 18:05:46 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-28 18:01:40 +0100 | <monochrom> | (or actual record type system --- but I sneakily classify that as static semantics, therefore still covered haha) |
2024-12-28 18:00:30 +0100 | <monochrom> | I like record syntax, it is not a wart, and it is pretty much compatible with e.g. SML record syntax. The wart is in the semantics --- lacking actual record semantics. |
2024-12-28 17:52:49 +0100 | <monochrom> | loonycyborg: I have a hunch that the real cause is that indentation desugars to {foo ; bar; } but record syntax wants {foo , bar}, i.e., the {} part is fine, the issue is with ; vs , and also extra ; |
2024-12-28 17:36:34 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-28 17:35:16 +0100 | <plitter> | ok, I'll try to find the other keywords, fixing the amount of let and maybe outside of main :) thanks for the suggestions! |
2024-12-28 17:34:04 +0100 | lxsameer | (~lxsameer@Serene/lxsameer) (Quit: WeeChat 4.4.2) |
2024-12-28 17:33:11 +0100 | euleritian | (~euleritia@dynamic-176-006-135-074.176.6.pool.telefonica.de) |
2024-12-28 17:32:50 +0100 | euleritian | (~euleritia@dynamic-176-006-135-074.176.6.pool.telefonica.de) (Ping timeout: 252 seconds) |
2024-12-28 17:32:15 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-28 17:31:27 +0100 | <enikar> | maybe don't do all the stuff in main will help |
2024-12-28 17:31:14 +0100 | <int-e> | (and there are more keywords to find) |
2024-12-28 17:30:26 +0100 | <int-e> | plitter: but the error you're getting is because `if` is a keyword |
2024-12-28 17:28:57 +0100 | <int-e> | plitter: you'd want a single `let` block |
2024-12-28 17:27:41 +0100 | <plitter> | was interested in at the end. Is there some compiler options that will let me do that? Or amI on the wrong track? |
2024-12-28 17:27:39 +0100 | <plitter> | I'm doing an advent of code https://adventofcode.com/2015/day/7 and thought I could use haskell to just input all the instructions but translated to haskell https://termbin.com/9u1q. But getting an error because of what I'm assuming is out of scope variable https://termbin.com/o4kn. I thought that haskell would wait with trying to input values until the end. And that I could just print the value I |
2024-12-28 17:27:16 +0100 | lxsameer | (~lxsameer@Serene/lxsameer) lxsameer |
2024-12-28 17:21:13 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-28 17:20:00 +0100 | bitdex | (~bitdex@gateway/tor-sasl/bitdex) (Ping timeout: 264 seconds) |
2024-12-28 17:16:56 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-28 17:16:11 +0100 | <hellwolf> | what is it? |
2024-12-28 17:16:07 +0100 | <hellwolf> | not sure how using "labels" would look like. |
2024-12-28 17:15:57 +0100 | <hellwolf> | asking for partially "anonymous" fields seems a stretch. Considering that in most languages, you don't have such a thing. |
2024-12-28 17:15:09 +0100 | <hellwolf> | but I probably should just export all fields. |
2024-12-28 17:14:24 +0100 | simplystuart | (~simplystu@c-75-75-152-164.hsd1.pa.comcast.net) (Remote host closed the connection) |
2024-12-28 17:14:19 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-28 17:14:11 +0100 | <hellwolf> | labels, lenses, OverloadedRecordDot seems its own paradigm. |
2024-12-28 17:14:01 +0100 | simplystuart | (~simplystu@c-75-75-152-164.hsd1.pa.comcast.net) |
2024-12-28 17:13:07 +0100 | <haskellbridge> | <loonycyborg> I'm wondering why record syntax is made in such a way you can't use indentation with it to get rid of {} |
2024-12-28 17:12:44 +0100 | <haskellbridge> | <loonycyborg> were there any proposals to change that? |
2024-12-28 17:12:35 +0100 | <haskellbridge> | <loonycyborg> I'm wondering why record syntax is made in such a way you can't use indentation with it |
2024-12-28 17:12:03 +0100 | <hellwolf> | :) |
2024-12-28 17:12:01 +0100 | <hellwolf> | 12-28 18:08 <int-e> hellwolf: hack hack hack: https://paste.tomsmeding.com/P0Xif3Ga |
2024-12-28 17:09:47 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-28 17:08:52 +0100 | <int-e> | hellwolf: hack hack hack: https://paste.tomsmeding.com/P0Xif3Ga |
2024-12-28 17:07:28 +0100 | euleritian | (~euleritia@dynamic-176-006-135-074.176.6.pool.telefonica.de) |
2024-12-28 17:06:15 +0100 | <geekosaur> | like I said, wart |
2024-12-28 17:06:07 +0100 | <geekosaur> | nor a way IIRC to say "this is actually used"; ghc's way to say "not used" is prefix underscore, but that messes with other ways to use the selector |