<< 06-11-2025 >>

00:01:52FromDiscord<lamabamadong_33783> In reply to @Elegantbeef "I imagine they're thinking": Probably
00:02:48FromDiscord<lamabamadong_33783> In reply to @ch_dr_7 "nim was the only": Nim compiles to C and then invokes whatever C compiler you have configured in your project. C can be cross-compiled assuming you have the correct compilation toolchain installed.
00:03:11FromDiscord<lamabamadong_33783> Zig's compiler (zigcc) can actually cross-compile Zig code without compiling to C first.
00:03:36FromDiscord<lamabamadong_33783> Not just zig code either - it can cross-compile C as well.
00:03:52FromDiscord<lamabamadong_33783> At least I'm pretty sure what I just said was accurate - but please feel free to correct me because I'm often wrong.
02:40:16FromDiscord<ichigo7799> In reply to @aethrvmn "And they have a": It's entirely because CrowdStrike says it's a virus, so the security dept has told me I'm to delete it.
02:42:04FromDiscord<ichigo7799> Also AFAIK all compilers that use LLVM as their code generator can generate code (cross-compile) for any CPU LLVM knows how to make code for.
02:42:21FromDiscord<ichigo7799> though I believe zig is no longer using LLVM? IDK I haven't checked
02:42:59FromDiscord<ichigo7799> I'm more interested in languages that compile to C/CPP on account of I have to link to MSVC compiled static libraries for which I don't have the source (welcome to gamedev)
02:48:42*rockcavera quit (Remote host closed the connection)
04:06:58FromDiscord<nervecenter> In reply to @lamabamadong_33783 "At least I'm pretty": you can install any cross-compilation toolchain and tell the Nim compiler to invoke it
04:07:15FromDiscord<nervecenter> I've compiled my work analysis program on both ARM and RISC-V and it worked fine
04:07:39FromDiscord<nervecenter> Well I've both compiled ON the devices, and cross-compiled from x86 Linux
04:08:07FromDiscord<nervecenter> The Nim compiler can in fact be compiled on RISC-V and works as advertised
04:23:23*SchweinDeBurg quit (Quit: WeeChat 4.8.0-dev)
04:23:52*SchweinDeBurg joined #nim
05:42:49*hygo quit (Ping timeout: 255 seconds)
05:44:52*hygo joined #nim
06:37:21*Jjp137 quit (Quit: Leaving)
06:39:35*fallback quit (Quit: IRCNow and Forever!)
06:42:33*Jjp137 joined #nim
06:44:38FromDiscord<amun0666> In reply to @ichigo7799 "though I believe zig": But you have to provide a specific sysroot for the target.
06:44:55FromDiscord<amun0666> (edit) "In reply to @ichigo7799 "though I believe zig": But you have to provide a specific sysroot for the target. ... " added "@nervecenter"
06:45:13FromDiscord<amun0666> (edit) "@nervecenter" => "@ichigo7799"
06:49:20*fallback joined #nim
08:47:07FromDiscord<ichigo7799> dunno what a sysroot is; never needed one
08:48:14*anddam joined #nim
08:50:17FromDiscord<finnt730> In reply to @ichigo7799 "It's entirely because CrowdStrike": no offence, but I find CrowdStrike malware itself....↵remember when they broke millions of systems, because their rootkit broke?
08:51:33FromDiscord<nnsee> In reply to @lamabamadong_33783 "Zig's compiler (zigcc) can": zigcc is great for cross compilation. nim can also leverage zigcc to produce cross compiled binaries super easily as well
08:53:37FromDiscord<ichigo7799> In reply to @finnt730 "no offence, but I": I mean, it's not my choice to run crowdstrike lol
08:54:30FromDiscord<ichigo7799> corporate spyware and windows 11 were thrust upon me by the IT overlords and I must comply if I want to eat and pay rent
08:55:41FromDiscord<ichigo7799> anyway, crowdstrike is very inconsistent about whether it reports nim programs as malware, and I get no warning, just an immediate chat interrogation from IT
08:56:02FromDiscord<nnsee> i luckily work somewhere where Windows is banned and everyone is either on linux or a few on macos, and i've always thought what i would do if it were reversed. i think i'd probably try and set up some sort of VM for my development environment first and foremost
08:56:28FromDiscord<ichigo7799> unfortunately, games
08:56:34FromDiscord<nnsee> ah, fair
08:56:42FromDiscord<ichigo7799> which like, part of the reason I wanted to use nim was for pixie
08:57:01FromDiscord<ichigo7799> (edit) "which like, part of the reason I wanted to use nim was for pixie ... " added "https://github.com/treeform/pixie/"
08:58:29FromDiscord<ichigo7799> and compile-to-cpp since the compiler I must use is fixed by the middleware providers/console SDKs
09:00:53FromDiscord<systemblue2010> Why is Rust adopted by the US government and US companies, ↵but Nim is not adopted by European governments and companies?
09:02:09FromDiscord<systemblue2010> Europe has yet to see large-scale adoption of Zig or Rust, ↵so if Nim can take that position, ↵it will significantly increase the competitiveness of our language.
09:12:49FromDiscord<.tokyovigilante> sent a code paste, see https://play.nim-lang.org/#pasty=Dtqisxch
09:13:11FromDiscord<.tokyovigilante> I get `C:\Users\ryan\Develop\hikaru\src\ext\vulkan\vulkan_api.nim(52, 11) Error: cannot open file: apiGeneratedFilename`
09:17:58FromDiscord<janakali> @.tokyovigilante `import` doesn't accept arguments, I think `include` is the same↵use a macro to generate include/import statement
09:19:16FromDiscord<janakali> or a template
09:19:30FromDiscord<.tokyovigilante> thanks
09:20:51FromDiscord<.tokyovigilante> is that a one-liner type thing, say `template apiFilename: return &"import {apiGeneratedFilename}"`?
09:21:27FromDiscord<janakali> sent a code paste, see https://play.nim-lang.org/#pasty=HIlyJCSi
09:25:45FromDiscord<finnt730> In reply to @ichigo7799 "I mean, it's not": fair↵doesn't mean I do not dislike it 😛
09:27:29FromDiscord<.tokyovigilante> sent a code paste, see https://play.nim-lang.org/#pasty=zADTXXyJ
10:20:01FromDiscord<kiloneie> sent a code paste, see https://play.nim-lang.org/#pasty=xxTYUDDk
10:23:52FromDiscord<kiloneie> On one hand the first is more elegant and easier to read. On the other, possibly pointless empty space ?...
10:23:58FromDiscord<aethrvmn> I find the top one cleaner/more rradable
10:24:09FromDiscord<aethrvmn> I find the top one cleaner/more readable
10:24:33FromDiscord<aethrvmn> It's not pointless, it says "Ok so we are done defining"
10:25:22FromDiscord<kiloneie> In reply to @aethrvmn "It's not pointless, it": That's actually a very good justification. This came as a problem to me, due to moving away from my teen days of more comments than code.
10:25:51FromDiscord<kiloneie> To, use sensible variable, proc names, and thus, the code be self-explanatory
10:26:25FromDiscord<kiloneie> Comments should be like, how European donuts get sprinkled with dust sugar
10:26:42FromDiscord<kiloneie> Grated sugar ? (idk)
10:27:16FromDiscord<aethrvmn> The powdered sugar?
10:27:21FromDiscord<kiloneie> Yeah.
10:28:36FromDiscord<tauruuuuuus> I prefer number 1 too for readability, but number 2 is better at a glance in non-curly brace languages like nim, for my personal taste
10:36:18FromDiscord<kiloneie> The opinion changes, whether the amount of code is a lot, or little. several lines of definitions/inits -> empty line. Just one ? Hair splitting dilemma D:.
10:39:17FromDiscord<nnsee> as a rule of thumb, usually when a block of code results in a new level of indentation (such as the `for` loop in your example), i separate it with an empty line from the previous code _and_ the following code in most cases
10:39:21FromDiscord<nnsee> give your code some space to breathe
10:42:19FromDiscord<kiloneie> In reply to @nnsee "as a rule of": I am kind of using my sections for that. This will take more time to properly refine my style.
10:43:07FromDiscord<kiloneie> I love when procs are folded, they are line by line like this: https://media.discordapp.net/attachments/371759389889003532/1435942568914452530/Screenshot_2025-11-06_11-42-34.png?ex=690dcd3a&is=690c7bba&hm=eef79352fc48439a971e4791dde2ad58e1f1fc0bdc0a245b33a7d31db6e161ca&
10:43:32FromDiscord<kiloneie> This is fine to me. https://media.discordapp.net/attachments/371759389889003532/1435942671481831444/Screenshot_2025-11-06_11-43-18.png?ex=690dcd53&is=690c7bd3&hm=3beb206e3d0ef75a8e958ed5880664b4d25b62da91b1911b8bbc613808db5fd0&
10:43:53FromDiscord<kiloneie> But when folded... No. https://media.discordapp.net/attachments/371759389889003532/1435942762284449802/Screenshot_2025-11-06_11-43-44.png?ex=690dcd69&is=690c7be9&hm=7425489ba9bcb157636fe00c180a86a0bf5b38e347c3d60f017878bf38386a4d&
10:44:22FromDiscord<nnsee> to be honest i prefer the last image over the first one
10:45:54FromDiscord<kiloneie> This is where i am at, at this moment, after a bit of reflection in the last 15 minutes. https://media.discordapp.net/attachments/371759389889003532/1435943271330218115/Screenshot_2025-11-06_11-45-29.png?ex=690dcde2&is=690c7c62&hm=51d06527ba8a1aaacb7472a0e12cf4c8edbb24df3d935eb9a73a93593797c295&
10:46:24FromDiscord<nnsee> what is with all the sections
10:47:54FromDiscord<kiloneie> They seem obscene when they are empty, i know. But idk, i prefer them over comments ? The syntax highlight, the folding...
10:48:47FromDiscord<kiloneie> I do wish i had a good shorter name for sectionSilent though...
10:49:00FromDiscord<kiloneie> These sections also help me with debugging.
10:49:03FromDiscord<nnsee> it just makes it look busy
10:49:39FromDiscord<kiloneie> when code doesn't tell me where the error occurred, i can follow the sections. sectionSilent ones, i cannot.
11:50:08*beholders_eye quit (Ping timeout: 260 seconds)
11:55:06FromDiscord<lainlaylie> In reply to @kiloneie "I can't decide on": but the whole thing is conceptually one operation: defining a seq with a particular value. it being a var statement followed by a for loop is only a side effect of not using `collect` or `filter` or some other proc
11:55:56FromDiscord<lainlaylie> therefore there shouldn't be an empty line
11:58:42FromDiscord<nnsee> that's not how my brain parses empty lines. if we take natural language as an analogy, it's more of a comma in the middle of a sentence instead of a whole new sentence
11:59:28FromDiscord<nnsee> you declaring a var and you operating on a var are separate things logically - i don't think it matters that the var is operated on in the next loop
12:00:30FromDiscord<nnsee> (but otherwise yes, Kilo, just use collect https://nim-lang.org/docs/sugar.html#collect.m%2Cuntyped)
12:00:49FromDiscord<lainlaylie> the natural language in question being "instancesSelf is a seq containing instances whose name is instanceSelfName"? no comma↵↵either way, it doesnt really matter
12:27:25*beholders_eye joined #nim
13:11:28FromDiscord<aethrvmn> Because Nim wasn't astroturfed by the US government↵(@systemblue2010)
13:12:20FromDiscord<aethrvmn> Tbh I dont care about nim's popularity. Lisp is unpopular too
14:30:01FromDiscord<kiloneie> I've got 1 instance of using collect in this project(copied once). Sometimes it's really useful, i don't think it makes sense for me here...
14:37:23FromDiscord<lamabamadong_33783> In reply to @nervecenter "you can install any": Yeah, this is essentially what I was trying to say.
14:38:46FromDiscord<kiloneie> In reply to @lainlaylie "the natural language in": It might seem like overkill there, but, i like to categorize my identifiers and routines in such a way, that i don''t have to search through code, just look at it. At times, it may become too long, and then i start reconsidering the name.,
14:48:52*beholders_eye quit (Ping timeout: 244 seconds)
16:44:15FromDiscord<lainlaylie> sent a code paste, see https://paste.rs/DndPu
16:58:45FromDiscord<kiloneie> It's a dilemma for sure.
17:35:00*beholders_eye joined #nim
18:22:07*beholders_eye quit (Ping timeout: 240 seconds)
19:00:28FromDiscord<Robyn [She/Her]> In reply to @systemblue2010 "Europe has yet to": Nim has a lot of subtle inconsistencies and is not really that safe, especially when it comes to threading which is p important
19:01:10FromDiscord<Robyn [She/Her]> @nocturn9x can speak about the troubles he faced with Nim's parallelism story (sorry for the ping)
19:13:07FromDiscord<mjsdev> I shared this awhile back on the nim forums then dropped it for a bit, been working on it a bit more recently and got some fairly big wins. It's still completely broken without atomicArc as far as I know, but if anyone is curious and can deal with my 4-space indentation (which you'll never convince me not to do), have a look:↵↵https://github.com/mattsah/mininim
19:14:09FromDiscord<mjsdev> I think the Testing and Development instructions should work... I have no idea... nimble still seems like a pile of garbage.
19:35:40FromDiscord<nocturn9x> In reply to @battery.acid.bubblegum "<@523555920265871380> can speak about": no worries
19:35:59FromDiscord<nocturn9x> yeah nim and threads are... peculiar
19:56:43*przmk quit (Remote host closed the connection)
19:57:12*przmk joined #nim
21:21:38*SchweinDeBurg quit (Quit: WeeChat 4.8.0-dev)
22:03:30*SchweinDeBurg joined #nim
22:17:20*rockcavera joined #nim
23:06:57*beholders_eye joined #nim
23:23:39FromDiscord<aethrvmn> Hmmm, I'm in a pickle
23:24:00FromDiscord<aethrvmn> I am building a package manager but I cant bugfix it because so far I only have a tty
23:29:51FromDiscord<aethrvmn> 1000000555.jpg https://media.discordapp.net/attachments/371759389889003532/1436135523579068416/1000000555.jpg?ex=690e80ee&is=690d2f6e&hm=85f4b3abcfad1308cea1c646756d2d3ca93acef8ade016b1218e03b6ae1d0c34&
23:33:26FromDiscord<mjsdev> It's kinda blurry.
23:36:18FromDiscord<aethrvmn> Yeah, cant do much better with my phone \:(
23:37:27FromDiscord<mjsdev> looks like the error is on line 44 of "lapis?"
23:38:55FromDiscord<mjsdev> What's that code?
23:41:09FromDiscord<aethrvmn> The one on the arrow
23:42:10FromDiscord<aethrvmn> I try to parse a macro definition, I use newLit(newSeqstring)
23:42:30FromDiscord<aethrvmn> I try to parse a macro definition, I use `newLit(newSeq[string])`
23:43:31FromDiscord<dacctal> Never seen that kind of syntax for a new sequence
23:44:00FromDiscord<dacctal> what's your newLit function look like?
23:45:56FromDiscord<aethrvmn> It's the one from the docs lmao, I am very new to macros so I'm just trying to figure it out↵(@dacctal)
23:46:00FromDiscord<mjsdev> newLit is a Nim function to create a newLiteral -- without code, I don't think anyone is gonna be able to help much. Clearly whatever value is being assigned or passed on line 44 is a string, and should be a NimNode
23:46:08FromDiscord<dacctal> oh really lol
23:46:19FromDiscord<dacctal> mb I'm still learning too
23:48:52FromDiscord<aethrvmn> 1000000556.jpg https://media.discordapp.net/attachments/371759389889003532/1436140306901893170/1000000556.jpg?ex=690e8563&is=690d33e3&hm=8bb4e51277cb1c44e7c0baa439eed2e7f7fd1bc1eeace5e104b13366ee3a71b4&
23:48:53FromDiscord<aethrvmn> I am passing a seq↵(@mjsdev)
23:49:37FromDiscord<mjsdev> Can you share lapis.nim?
23:50:16FromDiscord<mjsdev> Is line 44 the one that says let value = stmt[1] ?
23:50:38FromDiscord<mjsdev> Correction $stmt[1]
23:50:49FromDiscord<mjsdev> $ convert to string BTW
23:51:00FromDiscord<dacctal> always a useful bit of syntax
23:51:09FromDiscord<aethrvmn> It's the`of "patches": patchesNode = value`
23:51:13FromDiscord<mjsdev> so you may be passing a sequence and getting a sequence node, but you're definitely trying to assign a string to value
23:51:37FromDiscord<mjsdev> Yeah, but value is a string at that point
23:51:51FromDiscord<mjsdev> cause you let value = $stmt[1]
23:51:57FromDiscord<mjsdev> the $ converts to string
23:52:58FromDiscord<aethrvmn> Yup, it was that $
23:53:12FromDiscord<aethrvmn> Saved me a couple of hours of pain, thanks