00:16:21 | * | xtr00 quit (Ping timeout: 248 seconds) |
00:18:36 | * | xtr00 joined #nim |
00:42:38 | * | amadaluzia quit (Quit: Hi, this is Paul Allen. I'm being called away to London for a few days. Meredith, I'll call you when I get back. Hasta la vista, baby.) |
01:27:40 | * | dza4 joined #nim |
01:27:50 | * | def-- joined #nim |
01:28:15 | * | zgasma_ joined #nim |
01:34:36 | * | zgasma quit (*.net *.split) |
01:34:37 | * | ursa-major quit (*.net *.split) |
01:34:37 | * | kasimir_ quit (*.net *.split) |
01:34:38 | * | gshumway quit (*.net *.split) |
01:34:38 | * | dza quit (*.net *.split) |
01:34:38 | * | dv^_^ quit (*.net *.split) |
01:34:38 | * | def- quit (*.net *.split) |
01:34:38 | * | khazakar quit (*.net *.split) |
01:34:45 | * | def-- is now known as def- |
01:38:15 | * | amadaluzia joined #nim |
01:42:03 | * | khazakar joined #nim |
01:46:33 | * | gshumway_ joined #nim |
02:11:25 | * | ursa-major joined #nim |
02:11:25 | * | kasimir_ joined #nim |
02:11:25 | * | dv^_^ joined #nim |
02:12:53 | * | twistedspine joined #nim |
02:16:37 | * | beholders_eye quit (Ping timeout: 252 seconds) |
02:17:43 | * | twistedspine quit (Changing host) |
02:17:44 | * | twistedspine joined #nim |
02:27:58 | * | amadaluzia quit (Ping timeout: 244 seconds) |
02:30:16 | * | amadaluzia joined #nim |
02:59:33 | * | twistedspine quit (Quit: Client closed) |
03:04:21 | * | twistedspine joined #nim |
03:04:21 | * | twistedspine quit (Changing host) |
03:04:21 | * | twistedspine joined #nim |
03:15:31 | * | twistedspine quit (Read error: Connection reset by peer) |
04:21:35 | * | dza4 is now known as dza |
04:23:33 | * | tokyovigilante quit (Read error: Connection reset by peer) |
04:23:48 | * | tokyovigilante joined #nim |
04:25:43 | FromDiscord | <heysokam> In reply to @albassort "maybe i can make": I believe nph is non-configurable by design |
04:25:57 | FromDiscord | <albassort> In reply to @heysokam "I believe nph is": :| |
04:26:07 | FromDiscord | <albassort> commandism |
04:26:13 | FromDiscord | <Elegantbeef> Correct |
04:26:25 | FromDiscord | <heysokam> standarization has a prize |
04:26:29 | FromDiscord | <heysokam> price |
04:26:42 | FromDiscord | <albassort> but our formatting is non standard |
04:26:56 | FromDiscord | <heysokam> tell that to nph 🤷♂️ |
04:26:56 | FromDiscord | <albassort> nobody here likes standard formatting |
04:27:13 | FromDiscord | <albassort> im on my open source forking arc |
04:27:44 | FromDiscord | <heysokam> 😄 |
04:29:02 | FromDiscord | <Elegantbeef> Resistance is futile your uniqueness will be absorbed into the collective |
04:29:35 | FromDiscord | <Elegantbeef> Shit it's distinctiveness |
04:29:48 | FromDiscord | <heysokam> Prepare for imminent assimilation. Your codebase belong to us. |
04:29:55 | FromDiscord | <Elegantbeef> Good thing I don't proclaim to be a trekker |
04:36:36 | FromDiscord | <Laylie> i am interested in a configurable fork of nph |
04:37:00 | FromDiscord | <Laylie> i can't stand the way it changes my perfect proc param separator semicolons into commas |
04:38:13 | FromDiscord | <albassort> In reply to @Laylie "i am interested in": this is on my todo list now |
04:48:18 | * | ntat joined #nim |
04:57:02 | FromDiscord | <Elegantbeef> Squint and the issue goes away |
04:57:22 | FromDiscord | <zumi.dxy> yeah i just edit nph and make it 60 chars max |
04:57:35 | FromDiscord | <zumi.dxy> i do not have a 5:1 monitor↵thank you |
04:57:51 | FromDiscord | <zumi.dxy> or multimonitor |
04:57:58 | FromDiscord | <zumi.dxy> or the space to install them |
04:59:26 | FromDiscord | <Robyn [She/Her]> In reply to @albassort "this is on my": could use the editorconfig format |
05:36:29 | FromDiscord | <Laylie> the yaml people could learn a thing or two from the editorconfig spec↵https://spec.editorconfig.org/ |
05:45:40 | * | amadaluzia quit (Ping timeout: 268 seconds) |
05:50:02 | * | coldfeet joined #nim |
06:08:10 | FromDiscord | <albassort> In reply to @battery.acid.bubblegum "could use the editorconfig": hmm |
06:08:40 | FromDiscord | <albassort> In reply to @Laylie "the yaml people could": HMM |
06:08:48 | FromDiscord | <albassort> i need this in rfc format too fnacy |
06:08:59 | FromDiscord | <albassort> (edit) "fnacy" => "fancy too implement" |
06:09:05 | FromDiscord | <albassort> (edit) "too" => "to" |
06:10:29 | * | ntat quit (Quit: leaving) |
06:15:10 | FromDiscord | <albassort> In reply to @battery.acid.bubblegum "could use the editorconfig": `it seems this is a very general format and doesn't contain any language specific features |
06:32:36 | FromDiscord | <Laylie> looks like it's normal to define custom language-specific properties |
06:32:41 | FromDiscord | <Laylie> https://www.jetbrains.com/help/resharper/EditorConfig_Index.html |
06:51:25 | FromDiscord | <flyx> the last major YAML release was 2009, before editorconfig started. pretty sure it’s the other way round and editorconfig learned from YAML. I met one of YAML’s authors and basically they would like to do an update but it’s not realistic considering how libs aren’t updated (PyYAML is still on YAML 1.1). so it’ll probably be eternally stuck at what it is today. |
06:51:54 | FromDiscord | <Laylie> i don't doubt it |
06:52:03 | FromDiscord | <Laylie> i was mainly praising editorconfig's simplicity |
06:53:51 | FromDiscord | <leorize> isn't this just slightly extended `ini`? |
06:54:28 | FromDiscord | <Laylie> i see it as a well-defined ini with ease of parsing as a goal |
06:54:31 | FromDiscord | <flyx> it’s ini with file globs |
06:55:02 | FromDiscord | <flyx> pretty good for what it should do |
06:55:40 | FromDiscord | <nnsee> > no inline comments |
06:55:44 | FromDiscord | <nnsee> immediately lost interest |
06:55:54 | FromDiscord | <leorize> use toml if you want that |
06:55:59 | FromDiscord | <nnsee> i do ;) |
06:56:05 | FromDiscord | <leorize> ini should never have inline comments due to string ambiguity |
06:56:43 | FromDiscord | <leorize> on Linux there's an another well-defined ini format that's employed in many complex situation\: https://www.freedesktop.org/software/systemd/man/latest/systemd.syntax.html |
07:42:45 | FromDiscord | <albassort> i really do not like nph as a codebase |
07:43:03 | FromDiscord | <albassort> i cants say why but it gives me bad vibes |
07:43:13 | FromDiscord | <albassort> vibes based engineering |
08:02:46 | * | kenran joined #nim |
08:08:21 | * | coldfeet quit (Quit: Lost terminal) |
08:18:18 | * | ntat joined #nim |
08:25:04 | * | kenran quit (Remote host closed the connection) |
08:27:21 | * | kenran joined #nim |
08:41:47 | * | beholders_eye joined #nim |
09:05:23 | * | ntat quit (Quit: leaving) |
09:14:07 | * | beholders_eye quit (Ping timeout: 252 seconds) |
09:49:09 | * | ntat joined #nim |
10:02:35 | * | coldfeet joined #nim |
10:02:42 | * | johuck quit (Write error: Connection reset by peer) |
10:02:51 | * | johuck joined #nim |
11:21:42 | * | ntat quit (Read error: Connection reset by peer) |
11:27:44 | * | beholders_eye joined #nim |
11:45:58 | * | ntat joined #nim |
11:53:26 | FromDiscord | <ywazme_> hi, can someone explain customizable memory management ? it is written in the presentation of the language but i barely understand it |
11:53:34 | * | ntat quit (Quit: leaving) |
11:57:36 | * | coldfeet quit (Quit: leaving) |
12:02:22 | * | coldfeet joined #nim |
12:07:56 | * | beholders_eye quit (Ping timeout: 252 seconds) |
12:09:37 | * | xtr00 quit (Read error: Connection reset by peer) |
12:15:37 | * | xtr00 joined #nim |
12:30:41 | * | kenran quit (Remote host closed the connection) |
12:37:48 | FromDiscord | <janakali> sent a long message, see https://pasty.ee/BvYWDlDq |
12:38:44 | FromDiscord | <janakali> (edit) "https://pasty.ee/xdlvgIZF" => "https://pasty.ee/KZYofgSU" |
12:44:19 | * | jinn6 joined #nim |
12:44:54 | * | beholders_eye joined #nim |
12:45:48 | jinn6 | hello, is there a way to detect the current compilation target language, and enable/disable parts of code based on that? I couldn't find any info about that? |
12:50:20 | jinn6 | ideally allowing me to have single file for all the targets |
12:52:13 | FromDiscord | <ywazme_> In reply to @janakali "<@1329929027120660654> https://nim-lang.org/docs/mm": thx, what do you mean exactly by cycles |
12:53:07 | FromDiscord | <nnsee> references going object1 -> object2 -> object1 |
12:54:09 | FromDiscord | <janakali> sent a code paste, see https://play.nim-lang.org/#pasty=ULURIEhE |
13:02:54 | FromDiscord | <pmunch> In reply to @jinn6 "hello, is there a": https://play.nim-lang.org/#pasty=yINPeHyt |
13:03:15 | FromDiscord | <pmunch> Not 100% sure about the JavaScript one, might be `when defined(javascript)` |
13:04:11 | FromDiscord | <pmunch> Hmm, interesting. Got an error about an identifier from a template not being available (even though I marked it as `inject`). Tried to copy the code to the playground to see if anyone knew what was going on, but it works there.. |
13:04:54 | jinn6 | nice, thanks |
13:08:45 | jinn6 | looks like nim generates rather weird javascript, lol, but it works |
13:10:37 | FromDiscord | <nnsee> think of the JS as IR for the javascript engine |
13:12:51 | FromDiscord | <pmunch> jinn6, it generates pretty weird C as well |
13:12:58 | FromDiscord | <pmunch> The point is that it works and that it is fast |
13:13:08 | jinn6 | fair enough |
13:13:15 | jinn6 | and yeah, 85 line, 2546 byte javascript file, just to print a hardcoded "JS1" output, lol, I suppose with bigger programs it would be way less overhead |
13:13:35 | FromDiscord | <pmunch> Oh yeah, the overhead for small programs is a bit brutal |
13:14:01 | FromDiscord | <pmunch> However compiled in release mode and minified it's not terrible |
13:14:09 | FromDiscord | <pmunch> Won't win any size competitions though |
13:14:43 | FromDiscord | <pmunch> But if all your libs are in Nim and you compile to JS you will only end up with the JS you need and not have to load a bunch of libraries |
13:14:56 | FromDiscord | <pmunch> So you might save it back again in the end |
13:15:02 | jinn6 | yeah, fair enough |
13:16:51 | FromDiscord | <pmunch> This is seriously weird.. |
13:17:42 | FromDiscord | <pmunch> In my codebase I get ` Error: undeclared identifier: "weight"`, but in this minimal reproduction everything works fine https://play.nim-lang.org/#pasty=vLuOBcFh |
13:18:31 | FromDiscord | <nnsee> you probably have, but tried clearing cache? |
13:19:47 | FromDiscord | <pmunch> Yup |
13:19:56 | FromDiscord | <pmunch> And switched to newer Nim versions |
13:20:25 | FromDiscord | <pmunch> And I don't use the identifiers `loop` or `body` anywhere else in my code.. |
13:20:51 | FromDiscord | <pmunch> (might have something in an include though, but I don't think so, and it shouldn't matter) |
13:21:34 | FromDiscord | <pmunch> The `loop` template is exactly the same as mine, the `pixel` in my code is from a loop, and the `png` is from nimPng |
13:21:43 | FromDiscord | <leorize> try `--expandMacro`? |
13:21:49 | FromDiscord | <leorize> it works on templates too |
13:22:32 | FromDiscord | <pmunch> `--expandMacro:loop`: no output |
13:24:31 | FromDiscord | <pmunch> If you want to try it yourself: https://pasty.ee/efOtGLJb |
13:24:49 | FromDiscord | <pmunch> You need nimPNG installed first, but that should be the only dependency |
13:25:36 | FromDiscord | <pmunch> The trouble code is at line 140 |
13:27:41 | FromDiscord | <pmunch> It's almost like it doesn't see the template at all |
13:28:49 | FromDiscord | <pmunch> Moving the template outside the proc makes it work |
13:31:19 | FromDiscord | <pmunch> Oh wow, this is weird |
13:31:20 | FromDiscord | <pmunch> https://play.nim-lang.org/#pasty=HsvDYpga |
13:31:38 | FromDiscord | <pmunch> So it turns out it's because I had the `png` argument to my function as `auto` |
13:32:08 | FromDiscord | <pmunch> Same goes if it is a regular generic |
13:32:25 | FromDiscord | <leorize> generics funsies |
13:33:46 | FromDiscord | <pmunch> A smaller sample: https://play.nim-lang.org/#pasty=HXggaoCF |
13:38:25 | FromDiscord | <pmunch> Believe it might be this bug: https://github.com/nim-lang/Nim/issues/23889 |
14:03:35 | * | ntat joined #nim |
14:05:09 | * | beholders_eye quit (Ping timeout: 248 seconds) |
14:52:26 | jinn6 | ugh, if I want to import decode() from std/base64, but do not want it to be a global "decode()", how do I do it? if I do `from std/base64 import nil` and then `echo base64.decode(data_content)` then it errors `Error: attempting to call undeclared routine: 'decode'`, but the manual claims it's always possible to use full qualification like `echo strutils.replace("abc", "a", "z")`... |
14:54:30 | FromDiscord | <treeform> it should be possible but what you are trying todo, but it is strange... I don't think i ever seen `import nil` in the wild. Name space polution is a problem in dynamic langauges like python, but not in Nim because everything is statically checked and routed to the proper function. |
14:56:39 | jinn6 | yeah, but if I wanted to make my own decode() for example, I'd be unable to, and either need to choose a different name, or be unable to use the base64 (bc the fully qualified name seems broken?)...and well, I just don't want it to be decode() but something more reasonable like b64decode() lol |
14:57:58 | FromDiscord | <treeform> no decode you make in your own file is always the one that is used over the imported one. |
14:58:25 | FromDiscord | <Laylie> fully qualified base64.decode works for me, problem must be somewhere else |
14:59:27 | FromDiscord | <treeform> sent a code paste, see https://play.nim-lang.org/#pasty=EaQXxNOt |
15:00:31 | FromDiscord | <treeform> sent a code paste, see https://play.nim-lang.org/#pasty=sMCGxKWM |
15:00:56 | FromDiscord | <treeform> but the import nil is strange because Nim's rules don't need it. |
15:01:27 | jinn6 | https://play.nim-lang.org/#pasty=LoffINFx |
15:02:13 | FromDiscord | <Robyn [She/Her]> what if we just use TOML \:\> |
15:02:24 | FromDiscord | <Laylie> NO |
15:02:41 | jinn6 | TOML ftw |
15:03:43 | FromDiscord | <treeform> @jinn6 you have a different error var base64=false and a bool value has not decode... |
15:03:54 | * | jinn6 facepalms |
15:04:28 | jinn6 | yeah and now it works fine |
15:04:44 | FromDiscord | <treeform> and you don't need import nil |
15:05:09 | jinn6 | I know, I just don't like the bare decode() |
15:05:29 | FromDiscord | <treeform> its just how its done ... |
15:05:39 | jinn6 | ok well, I don't need the nil I suppose, but whatever... |
15:05:48 | FromDiscord | <treeform> what about data_content.decode() instead? |
15:06:25 | jinn6 | it annoys me how it's just decode() which is super nondescript, lol |
15:07:42 | jinn6 | base64.decode(stuff) is fine, but just decode(stuff) or stuff.decode() is way too ambiguous imho |
15:07:43 | FromDiscord | <treeform> maybe become annoyed at using long name when short name will do instead? |
15:08:30 | jinn6 | ideally I'd just do `from base64 import decode as b64decode` but alas, can't do that |
15:19:44 | FromDiscord | <threefour> Okay I put together a demonstration of what seems to be a compiler bug. Am I doing something that should be functional, or is it an ungraceful fail of invalid usage? |
15:19:48 | FromDiscord | <threefour> https://play.nim-lang.org/#pasty=RTQeYGkW |
15:20:30 | FromDiscord | <fabric.input_output> sent a code paste, see https://play.nim-lang.org/#pasty=DoRSmpJg |
15:20:34 | FromDiscord | <threefour> The issue comes from the `innerShapes` function of the vtable in this case. |
15:20:52 | FromDiscord | <threefour> Commenting out everything to do with `innerShapes` makes it compile just fine. |
15:21:35 | FromDiscord | <leorize> you can't just say that and not post it here |
15:21:54 | FromDiscord | <Laylie> toml is ok i guess, but it has a lot of features that we dont need and i personally like the idea of using a shared format like editorconfig |
15:22:53 | FromDiscord | <threefour> In reply to @leorize "you can't just say": Talking to me? I sent a Nim playground link. |
15:23:05 | FromDiscord | <leorize> a crash is always a bug |
15:23:09 | FromDiscord | <leorize> I usually put it in `()`, makes it looks less arcane↵(@fabric.input_output) |
15:23:21 | FromDiscord | <leorize> the question is whether your crash is known \:p |
15:23:27 | FromDiscord | <leorize> but it's fine to just submit that snip |
15:25:19 | FromDiscord | <leorize> you can simplify the sample a lot more |
15:26:04 | FromDiscord | <threefour> Probably. I did a 1:1 of everything in the proprietary code to make sure it was a proper recreation. |
15:26:38 | FromDiscord | <leorize> does commenting anything but `innerShapes` still produce the crash? |
15:26:49 | FromDiscord | <leorize> everything\ |
15:26:52 | FromDiscord | <leorize> oh lol matrix lag |
15:26:55 | FromDiscord | <leorize> I sent those long ago |
15:27:35 | FromDiscord | <leorize> your sample looks minimizable, so you should do that |
15:27:47 | FromDiscord | <leorize> make the smallest one that can trigger the bug, then submit it |
15:28:00 | FromDiscord | <fabric.input_output> In reply to @leorize "I usually put it": I usually do that but I found out I can just do this so that's what I'm gonna keep doing |
15:29:17 | FromDiscord | <leorize> the tiny colon just look so out of place tbh |
15:30:46 | FromDiscord | <fabric.input_output> it's comedic |
15:30:52 | FromDiscord | <fabric.input_output> I love it |
15:39:38 | * | twistedspine joined #nim |
15:39:38 | * | twistedspine quit (Changing host) |
15:39:38 | * | twistedspine joined #nim |
15:42:16 | * | twistedspine quit (Client Quit) |
16:11:17 | * | przmk quit (Remote host closed the connection) |
16:11:44 | * | przmk joined #nim |
16:31:11 | Amun-Ra | hmm, I could've sworn this used to work before: https://play.nim-lang.org/#pasty=HIHTvxAE |
16:32:36 | FromDiscord | <Elegantbeef> `s: openArray[byte or char]` will work |
16:32:44 | FromDiscord | <Elegantbeef> You don't need `or string` |
16:33:05 | FromDiscord | <leorize> sounds like a bug for that one |
16:33:26 | Amun-Ra | I had openArray[byte or char] before the paste, same result |
16:33:28 | FromDiscord | <Elegantbeef> Yea, but it never worked |
16:33:42 | FromDiscord | <Elegantbeef> `openArray[byte]` requires a conversion that will never happen |
16:34:13 | Amun-Ra | removing "or string" fixes the issue |
16:34:47 | FromDiscord | <Elegantbeef> https://play.nim-lang.org/#pasty=UMlUanUz |
16:34:49 | FromDiscord | <Elegantbeef> best way of doing it |
16:35:06 | FromDiscord | <Elegantbeef> Since `openArray` requires a conversion you cannot also have it have `string` as a valid choice |
16:36:09 | Amun-Ra | I ended up with 'https://play.nim-lang.org/#pasty=gTVLbuiC' |
16:36:51 | FromDiscord | <Elegantbeef> You don't need that |
16:36:53 | FromDiscord | <Elegantbeef> You can just do what I did and skip the double proc 😄 |
16:37:06 | Amun-Ra | hmm, let me check :> |
16:38:08 | FromDiscord | <Elegantbeef> Yes they should be equal, but Nim generic type matching is silly |
16:38:27 | Amun-Ra | is there a reason openArray[T] is fine and openArray[char or byte] isn't? |
16:38:33 | Amun-Ra | I seer |
16:38:35 | Amun-Ra | see* |
16:39:51 | FromDiscord | <Elegantbeef> The reason is likely that `openArray[T]` has a `ntyGenericParam` instead of a `ntyTypeClass` so it can do further checking of a match |
16:40:05 | Amun-Ra | oh |
16:40:14 | Amun-Ra | thanks for the fix and explanation |
16:40:37 | FromDiscord | <Elegantbeef> Nim does not invoke converters for generics, so it's "technically right" but terrible UX |
16:58:58 | * | amadaluzia joined #nim |
17:15:09 | * | andy-turner joined #nim |
17:32:25 | * | ntat quit (Quit: leaving) |
18:08:53 | * | beholders_eye joined #nim |
19:47:17 | * | amadaluzia quit (Ping timeout: 244 seconds) |
19:47:59 | * | amadaluzia joined #nim |
19:55:47 | * | coldfeet quit (Quit: Lost terminal) |
20:20:19 | * | GuyForThat joined #nim |
20:26:28 | * | GuyForThat left #nim (ERC 5.6.0.30.1 (IRC client for GNU Emacs 30.1)) |
20:28:31 | * | andy-turner quit (Quit: Leaving) |
21:50:15 | * | rockcavera joined #nim |
22:57:37 | * | tiorock joined #nim |
22:57:38 | * | tiorock quit (Changing host) |
22:57:38 | * | tiorock joined #nim |
22:57:38 | * | rockcavera quit (Killed (calcium.libera.chat (Nickname regained by services))) |
22:57:38 | * | tiorock is now known as rockcavera |
22:59:40 | * | tiorock joined #nim |
22:59:41 | * | tiorock quit (Changing host) |
22:59:41 | * | tiorock joined #nim |
22:59:41 | * | rockcavera is now known as Guest8445 |
22:59:41 | * | tiorock is now known as rockcavera |
23:02:09 | * | Guest8445 quit (Ping timeout: 248 seconds) |
23:11:42 | * | Lord_Nightmare quit (Quit: ZNC - http://znc.in) |
23:18:40 | FromDiscord | <__nycto__> I'm getting a SIGSEGV from `nimsuggest`. Is there a way to get a stacktrace out of that? I tried to recompile it with `./koch nimsuggest -d:debug --debugger:native -d:stacktraceMsgs -d:nimCompilerStacktraceHints -d:nimDebug`, but that didn't help. Is there an incantation I'm missing? |
23:24:15 | * | Lord_Nightmare joined #nim |