00:12:21 | FromDiscord | <dk> choosenim 0.6.0 on Window is broken and trying to build devel from source causes a nimterop assertion error |
00:12:21 | FromDiscord | <dk> lmao |
00:14:20 | * | tauplus joined #nim |
00:14:31 | FromDiscord | <dk> @dom96 a new release would be cool even if just to include a fix for this bug https://github.com/dom96/choosenim/issues/199 |
00:14:32 | disbot | β₯ Nimarchive cannot overwrite existing extraction? ; snippet at 12https://play.nim-lang.org/#ix=2mZw |
00:14:35 | * | tauplus quit (Remote host closed the connection) |
00:25:40 | shashlick | What's the issue you are seeing with build |
00:28:31 | shashlick | @dk ^^ |
00:28:47 | shashlick | @disruptek what substitutions are you thinking of |
00:30:16 | FromDiscord | <dk> https://gist.github.com/dawkot/9806d2689f4596a3ed93c6c741cfc3ef |
00:30:48 | FromDiscord | <dk> @shashlick |
00:39:39 | FromDiscord | <dk> Also, I'm just guessing that `C:\Users\97daw\.nimble\pkgs\httpbeast-0.2.2\httpbeast.nim(183, 36) Error: undeclared identifier: 'EWOULDBLOCK` means I need a devel compiler? |
00:40:48 | * | Zectbumo joined #nim |
00:40:50 | * | Zectbumo quit (Remote host closed the connection) |
00:41:13 | * | Zectbumo joined #nim |
00:50:06 | ForumUpdaterBot | New thread by Salient: Set global response header for Jester when serving static files, see https://forum.nim-lang.org/t/6716 |
00:51:48 | shashlick | @dk: is there no other output |
00:51:56 | shashlick | Can you run toast on the command line |
00:53:56 | FromDiscord | <flywind> `httpbeast` doesn't support windows. |
00:55:34 | FromDiscord | <dk> @flywind π |
00:56:58 | FromDiscord | <flywind> I have made a fork version of `httpbeast` and add windows support. https://github.com/xflywind/httpx |
00:58:04 | FromDiscord | <dk> Nice, I'll try it instead |
00:59:16 | FromDiscord | <flywind> By the way now you need devel compiler indeed. π |
01:00:02 | * | Tanger joined #nim |
01:00:08 | * | Tlangir joined #nim |
01:00:25 | FromDiscord | <dk> Fine, I'll build it without choosenim |
01:00:35 | * | Tlangir quit (Client Quit) |
01:01:59 | FromDiscord | <flywind> You don't need `choosenim devel` if you have ever installed some versions, just download devel from night builds. |
01:02:24 | FromDiscord | <flywind> And move them into devel directory. |
01:02:48 | FromDiscord | <flywind> https://github.com/nim-lang/nightlies/releases |
01:06:55 | FromDiscord | <dk> I'll try to do that |
01:09:40 | FromDiscord | <dk> What do you mean "move them into devel directory"? |
01:10:14 | FromDiscord | <flywind> Download `devel` version and move them into `toolchains` directory. C:\Users\blue\.choosenim\toolchains\nim-#devel |
01:10:38 | FromDiscord | <flywind> C:\Users\blue\choosenim\toolchains\nim-#devel |
01:11:30 | FromDiscord | <dk> Am I supposed to do `choosenim devel` after that? |
01:13:32 | FromDiscord | <dk> That causes the same choosenim error I had earlier, but I can just use the version without choosenim then |
01:13:42 | FromDiscord | <dk> Thanks for the nightlies, I didn't know about them |
01:13:58 | FromDiscord | <flywind> np |
01:14:04 | FromDiscord | <flywind> Maybe you can try previous version of `choosenim` in windows? I think they work fine? |
01:14:55 | FromDiscord | <dk> doesn't sound like less trouble |
01:15:07 | FromDiscord | <dk> than just using nim manually |
01:23:52 | * | krux02_ quit (Remote host closed the connection) |
01:28:27 | FromGitter | <viencokhi> Does anyone know any http package that support ssl-pining? |
01:38:14 | disruptek | AHAH! |
01:38:29 | * | stefantalpalaru_ joined #nim |
01:38:35 | disruptek | https://nim-lang.org/docs/manual_experimental.html#concepts-concept-diagnostics -- CALLSITE PRAGMA USE! |
01:41:22 | * | stefantalpalaru quit (Ping timeout: 260 seconds) |
01:44:25 | * | apahl quit (Ping timeout: 244 seconds) |
01:46:17 | * | stefantalpalaru_ is now known as stefantalpalaru |
01:46:20 | * | stefantalpalaru quit (Changing host) |
01:46:20 | * | stefantalpalaru joined #nim |
01:46:38 | * | apahl joined #nim |
01:49:08 | FromDiscord | <Elegant Beef> That's not supposed to work is it? |
01:52:05 | disruptek | my head says "no" but my balls say "yes". |
01:55:35 | FromDiscord | <Elegant Beef> Have you went to a ball doctor, your balls seem to be constantly on your mind |
01:55:48 | disruptek | nah, they're constantly on my lap. |
01:56:01 | FromDiscord | <Elegant Beef> Didnt realize you were that old |
01:56:07 | disruptek | yep. |
02:00:07 | * | waleee-cl quit (Quit: Connection closed for inactivity) |
02:10:17 | * | Zectbumo quit (Remote host closed the connection) |
02:12:16 | * | smitop quit (Quit: Connection closed for inactivity) |
02:23:41 | * | rockcavera joined #nim |
02:26:25 | * | muffindrake quit (Ping timeout: 240 seconds) |
02:26:33 | * | Zectbumo joined #nim |
02:28:39 | * | muffindrake joined #nim |
02:30:10 | * | endragor joined #nim |
02:34:18 | shashlick | @dk - can you run toast on the command line |
02:34:28 | shashlick | Does it work |
02:38:46 | * | Zectbumo quit (Remote host closed the connection) |
02:40:24 | * | Zectbumo joined #nim |
02:48:25 | FromDiscord | <Admin> are the dark mode search results broken only for me ? |
02:48:32 | FromDiscord | <Admin> that contrast hurts my eyes |
02:50:00 | * | endragor quit (Remote host closed the connection) |
02:50:08 | * | endragor joined #nim |
02:50:12 | leorize | fixed in devel |
02:51:04 | * | thomasross quit (Ping timeout: 258 seconds) |
03:08:03 | * | DamionDreggs joined #nim |
03:13:03 | FromDiscord | <Admin> how would i remove the last letter from a string ? |
03:16:28 | DamionDreggs | Is there a primary purpose driving NIM? I'm trying to decide if this is something I should spend time learning. |
03:16:41 | leorize | @Admin s.setLen(s.len - 1) |
03:17:22 | leorize | DamionDreggs: I'm not sure what do you mean by primary purpose |
03:18:08 | DamionDreggs | Is this language designed as a general purpose tool, or is it designed for some specific problem scope? |
03:18:38 | leorize | a general purpose tool |
03:19:01 | DamionDreggs | Gotcha, thank you. :) |
03:20:01 | leorize | welcome to nim :) |
03:21:10 | FromDiscord | <Admin> how should i format paramstrings ?0 |
03:21:11 | FromDiscord | <Admin> (edit) '?0' => '?' |
03:21:30 | leorize | DamionDreggs: just curious, where did you pick up the "NIM" spelling? I noticed a lot of newcomers use full caps even though all of our reference material and even the home page use "Nim". |
03:21:38 | leorize | @Admin paramstrings? |
03:22:31 | DamionDreggs | Leorize: the channel name is all uppercase for me |
03:22:55 | DamionDreggs | That's probably my client though |
03:23:08 | FromDiscord | <Admin> sent a code paste, see https://play.nim-lang.org/#ix=2v3W |
03:23:10 | leorize | probably :P I think freenode is not even case-sensitive |
03:23:34 | FromDiscord | <Admin> but when i echo the options right after the first replace its only {url |
03:23:45 | DamionDreggs | I was just browsing channels before I joined, I haven't heard of Nim before. |
03:25:05 | FromDiscord | <Admin> (edit) '{url' => '"{url"' |
03:25:35 | leorize | DamionDreggs: you can find our learning materials here: https://nim-lang.org/learn.html |
03:25:59 | leorize | hopefully they'll be interesting enough to keep you around :) |
03:26:46 | leorize | @Admin well you typically would use an param parser for that |
03:27:23 | leorize | in stdlib we got parseopt, but these 3rd-party packages are usually recommended over the stdlib's parser: |
03:27:25 | leorize | !repo cligen |
03:27:26 | disbot | https://github.com/c-blake/cligen -- 9cligen: 11Nim library to infer/generate command-line-interfaces / option / argument parsing; Docs At 15 205β 14π΄ 7& 1 more... |
03:27:34 | leorize | !repo argparse |
03:27:35 | disbot | https://github.com/iffy/nim-argparse -- 9nim-argparse: 11Argument parsing for Nim 15 41β 4π΄ 7& 1 more... |
03:27:48 | FromDiscord | <Admin> aha ok thanks |
03:28:18 | FromDiscord | <j$> is there a way to have object variants but w/ generics |
03:28:32 | leorize | what's stopping you from that? |
03:28:37 | DamionDreggs | Yes, I was browsing through briefly before I spoke. I'm mildly interested. The syntax reminds me a lot of the first language I ever learned. I like the compile-to-javascript concept. I haven't had the chance to browse core libraries yet |
03:29:43 | FromDiscord | <j$> leorize was that directed towards me? |
03:29:50 | leorize | yep |
03:30:11 | FromDiscord | <j$> one second lemme write a code thingy |
03:34:49 | FromDiscord | <j$> https://play.nim-lang.org/#ix=2v3Y |
03:35:16 | FromDiscord | <j$> this is obviously not the correct way to do this but... |
03:35:27 | FromDiscord | <j$> can it be done |
03:35:31 | leorize | https://play.nim-lang.org/#ix=2v3Z |
03:35:55 | FromDiscord | <j$> oh |
03:36:38 | leorize | https://play.nim-lang.org/#ix=2v40 |
03:37:13 | leorize | nim is a bit too flexible :P |
03:37:23 | FromDiscord | <j$> lol |
03:38:57 | FromDiscord | <j$> https://play.nim-lang.org/#ix=2v41 |
03:39:03 | FromDiscord | <j$> so why is this not functional |
03:39:18 | FromDiscord | <j$> wait |
03:39:19 | FromDiscord | <j$> nvm |
03:39:47 | leorize | nim assignments are not expressions |
03:39:56 | FromDiscord | <j$> yeah, I missed the echo |
03:41:14 | FromDiscord | <j$> so typedesc is used exclusively for ast gen, macros, etc |
03:41:17 | FromDiscord | <j$> ? |
03:41:30 | FromDiscord | <Varriount> > Yes. |
03:41:46 | leorize | typedesc are compile-time values |
03:42:01 | leorize | they refer to a (declared) type |
03:42:41 | FromDiscord | <j$> yeah im still struggling to understand macros and what not, but I'll figure that out at some point |
03:43:03 | FromDiscord | <j$> side note what is an empty object in memory look like? |
03:43:26 | leorize | it looks like nothing |
03:43:57 | leorize | an empty object is empty, so it doesn't occupy space |
03:44:47 | FromDiscord | <j$> does an empty object have a use other than being a type? |
03:45:01 | leorize | being a type is a big deal :P |
03:45:38 | FromDiscord | <j$> lol yeah for some reason I just assumed it be some other keyword that makes a type, but this makes sense |
03:47:56 | leorize | you don't really need to understand macros to use nim, though it's handy to know how they work |
03:48:08 | * | rockcavera quit (Remote host closed the connection) |
03:49:14 | FromDiscord | <j$> yeah that's why I'm putting it off, I've written a few but it's mostly trial and error and shots in the dark and I don't like guess work |
03:50:33 | leorize | that's pretty much how you write macros tbf :P |
03:51:06 | FromDiscord | <j$> haha |
03:52:43 | * | DamionDreggs quit (Quit: I Quit!) |
03:54:11 | FromDiscord | <j$> what editor/tools do you use to write nim code? |
03:54:55 | leorize | I use neovim with nim.nvim |
03:57:30 | Prestige | I use the same + nimlsp with coc-nvim |
04:06:02 | * | supakeen quit (Quit: WeeChat 2.9) |
04:06:45 | * | supakeen joined #nim |
04:15:18 | * | solitudesf joined #nim |
04:23:45 | FromDiscord | <Admin> undeclared identifier: 'newContext' |
04:23:51 | FromDiscord | <Admin> what do i have to import ? |
04:23:57 | FromDiscord | <Rika> net i think |
04:24:08 | FromDiscord | <Rika> https://nim-lang.org/docs/net.html#newContext%2Cstring%2Cstring%2Cstring%2Cstring%2Cstring |
04:24:48 | FromDiscord | <Rika> @Admin module needed is `net` if you havent seen my message above |
04:24:56 | FromDiscord | <Admin> yep got it thanks |
04:30:56 | FromDiscord | <Admin> weird |
04:31:03 | FromDiscord | <Admin> vsc still gives me the error but i compile just fine |
05:03:20 | * | NimBot joined #nim |
05:37:52 | Zevv | leoi |
05:38:20 | Zevv | leorize: of course its use-after-free, thats what it sais, right |
05:38:37 | Zevv | it sais, now, anyway :) |
05:51:32 | leorize | you might want a coffee or two before continuing lol |
05:53:46 | Zevv | well cmon i just slept for 8 hours |
05:54:06 | Zevv | ill probably continue in 2 or 3 monhts |
05:57:46 | * | narimiran joined #nim |
06:00:03 | narimiran | waazzuuuuuup |
06:20:26 | * | r4vi quit (Ping timeout: 240 seconds) |
06:22:20 | * | r4vi joined #nim |
06:28:01 | lbart | I'm pretty sure that this code worked some versions ago (1.0.6? with a tiny difference about the struct cpoint if i'm not wrong). But i'm facing this crash, don't know really why. Is I have to manage the memory now? |
06:28:01 | lbart | https://gist.github.com/lbartoletti/8516303ea15cd9d2234e7767a64ca13e#file-main-c-L17 Any ideas? Thanks |
06:34:01 | * | PMunch joined #nim |
06:38:43 | Zevv | narimiran: hows life |
06:39:18 | narimiran | recharged now, after 2-week holidays :) |
06:39:26 | Zevv | good work! |
06:39:55 | narimiran | eeerrrrm, exactly the opposite of work |
06:40:08 | Zevv | good holidays! |
06:41:01 | narimiran | yeah |
06:41:08 | narimiran | how bout you? |
06:45:34 | Zevv | having good holidays |
07:09:57 | ForumUpdaterBot | New thread by Lbart: Nim to C, see https://forum.nim-lang.org/t/6717 |
07:23:30 | * | PMunch quit (Quit: leaving) |
07:24:06 | ForumUpdaterBot | New thread by Lutins: For-fun medieval rebranding, see https://forum.nim-lang.org/t/6719 |
07:26:06 | * | PMunch joined #nim |
07:26:27 | FromDiscord | <Rika> thats fun |
07:54:02 | * | hnOsmium0001 quit (Quit: Connection closed for inactivity) |
07:54:43 | * | floppydh joined #nim |
07:57:26 | PMunch | Hmm, damn |
07:57:51 | PMunch | I updated my computer, which apparently must've updated some part of the GCC/Arduino toolchain.. |
07:58:42 | PMunch | Now getting "lto1: internel compiler error: bytecode stream: expected tag identifier_node instead of LTO_UNKNOWN" error when compiling for the Arduboy.. http://ix.io/2v4F |
08:04:03 | PMunch | Aha, apparently it was because it tried to compile in some sources that was built with an older compiler: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62083 |
08:04:14 | PMunch | Simply deleting the nim cache and recompiling fixed the issue |
08:15:56 | * | fredrikhr1 joined #nim |
08:16:54 | * | fredrikhr quit (Ping timeout: 258 seconds) |
08:16:54 | * | fredrikhr1 is now known as fredrikhr |
08:18:46 | * | Vladar joined #nim |
08:41:36 | * | solitudesf quit (Remote host closed the connection) |
08:42:12 | * | solitudesf joined #nim |
08:47:48 | * | krux02 joined #nim |
09:17:35 | * | abm joined #nim |
09:19:19 | * | Zectbumo quit (Remote host closed the connection) |
09:39:19 | * | floppydh quit (Quit: WeeChat 2.7.1) |
09:52:05 | * | FromDiscord quit (Remote host closed the connection) |
09:52:19 | * | FromDiscord joined #nim |
09:53:03 | * | gangstacat quit (Ping timeout: 272 seconds) |
09:58:41 | * | gangstacat joined #nim |
09:59:14 | Zevv | nimcache is baaaad then. it should take in account compiler fingerprints like ccache does |
10:01:55 | * | FromDiscord quit (Remote host closed the connection) |
10:02:12 | * | FromDiscord joined #nim |
10:11:26 | * | Northstrider[m] quit (Quit: killed) |
10:12:51 | * | Northstrider[m] joined #nim |
10:31:03 | * | apahl quit (Ping timeout: 272 seconds) |
10:31:55 | * | apahl joined #nim |
10:52:34 | * | arecacea1 quit (Remote host closed the connection) |
10:52:53 | * | arecacea1 joined #nim |
11:02:15 | Yardanico | 45=YHG[]' |
11:02:19 | Yardanico | sorry wrogn chat |
11:10:08 | FromDiscord | <Recruit_main707> xD |
11:14:44 | FromDiscord | <maiagallo> For what it's worth, I've spent the weekend checking nim, kotlin and rust and nim was my favourite by FAR |
11:15:16 | FromDiscord | <ache of head> Rust is cool but I feel like it complicates stuff that doesn't have to be |
11:15:54 | Yardanico | also I heard that Rust's ownership gets in your way too much when you start making your own data structures |
11:15:57 | Yardanico | instead of using stdlib ones |
11:16:03 | FromDiscord | <ache of head> Despite many people liking it, I feel likeborrowing system does more damage than it prevents it |
11:16:08 | FromDiscord | <ache of head> (edit) 'likeborrowing' => 'like the borrowing' |
11:16:59 | FromDiscord | <ache of head> I'm not saying it's bad |
11:17:02 | FromDiscord | <Rika> rust people would probably say that its hard to judge how many issues it would save you from since you dont get them |
11:17:04 | FromDiscord | <ache of head> I just don't like it |
11:17:19 | FromDiscord | <ache of head> It's weird to work with |
11:17:30 | FromDiscord | <maiagallo> I'm a bit sad now that nim's ecosystem is lagging behind comapred to them |
11:17:45 | Yardanico | well rust was pushed by mozilla quite a lot |
11:17:47 | FromDiscord | <Rika> yeah its most likely the fact that nim isnt backed by a large corp |
11:18:08 | FromDiscord | <ache of head> I feel like many people work differently, but this is how I do: I hate writing code that doesn't have to be there and that doesn't benefit to the project in any way directly. |
11:18:27 | FromDiscord | <ache of head> That's why implementing `Debug` for every single new struct I make is just the most annoying thing in the world to me. |
11:19:42 | FromDiscord | <ache of head> Shamelessly plugging myself in: I wrote an article on the differences between Nim and Rust once: https://dev.to/aachh/nim-v-rust-4kh5 |
11:20:11 | FromDiscord | <ache of head> Probably everything is wrong with it but it's a first time, eh? |
11:20:19 | FromDiscord | <maiagallo> Nice, I'm going to read it later π Btw I think I will end up trying nim, even though it won't help me find a new job anytime soon |
11:21:58 | FromDiscord | <Rika> reading it right now |
11:22:07 | FromDiscord | <Recruit_main707> @ache of head this is wrong https://media.discordapp.net/attachments/371759389889003532/747415436626493551/unknown.png |
11:22:22 | FromDiscord | <ache of head> Yeah, I know there's a return keyword |
11:22:26 | FromDiscord | <ache of head> I don't know why I wrote that |
11:22:32 | FromDiscord | <ache of head> I'm still not sure if it returns values |
11:22:33 | FromDiscord | <ache of head> Does it? |
11:22:36 | FromDiscord | <Recruit_main707> ofc |
11:22:39 | FromDiscord | <lakmatiol> it works like normal return |
11:22:40 | FromDiscord | <ache of head> I only know it exists procs. |
11:22:42 | FromDiscord | <Recruit_main707> its a normal return |
11:22:43 | FromDiscord | <ache of head> Ah, okay |
11:22:48 | FromDiscord | <ache of head> (edit) 'exists' => 'exits' |
11:22:55 | FromDiscord | <ache of head> *why did i send this* |
11:22:57 | FromDiscord | <lakmatiol> just that you often use result instead or just neither |
11:23:06 | FromDiscord | <ache of head> Yeah, that's true |
11:23:09 | FromDiscord | <ache of head> Okay, going to correct that now |
11:23:41 | FromDiscord | <Rika> also again, nim isnt necessarily a gc'd language |
11:23:46 | FromDiscord | <ache of head> Yep, I put an edit there |
11:23:59 | FromDiscord | <ache of head> I didn't know about planned ARC when I was writing it |
11:24:02 | FromDiscord | <Rika> i dont think "oh an edit" when i see a footnote |
11:24:09 | FromDiscord | <Rika> i think "oh a reference" |
11:24:15 | FromDiscord | <ache of head> it's explicitly named "edit" |
11:24:22 | FromDiscord | <ache of head> and it's not numbered |
11:24:22 | FromDiscord | <Rika> oh, so its not the [1] things |
11:24:23 | FromDiscord | <Rika> ok |
11:24:32 | * | waleee-cl joined #nim |
11:25:10 | FromDiscord | <Rika> also nim has the same implicit return w/o return keyword or result assignment as rust |
11:25:11 | FromDiscord | <Recruit_main707> its pretty good overall |
11:26:05 | FromDiscord | <ache of head> I mean, I definitely got to know Nim much better since I wrote it |
11:26:11 | * | aachh joined #nim |
11:26:51 | FromDiscord | <ache of head> Thanks for the feedback! |
11:27:51 | FromDiscord | <Rika> i think nim needs more generics in the stdlib, stuff like `streams` has a lot of `readType` style names for its procs and i think it could be better |
11:28:35 | FromDiscord | <Ricky Spanish> theres some interesting things that would be worth adding imo like outputing c from nim which iv not seen from rust but maybe im wrong on that one |
11:28:43 | FromDiscord | <Ricky Spanish> good read tho π |
11:28:43 | Yardanico | well, rust has a variant of an HM type system |
11:28:58 | Yardanico | so let data: u32 = parse("15") is same as let data = parse<u32>("15") |
11:29:09 | Yardanico | (roughly, not exact Rust's syntax) |
11:29:21 | FromDiscord | <Recruit_main707> lets just leave the readers some surprises just in case they get to know nim better :p |
11:29:55 | FromDiscord | <ache of head> You're all right, Nim surely has many more features, but I didn't want to feel like the article was biased π |
11:30:11 | FromDiscord | <ache of head> More like an objective comparison. |
11:30:33 | FromDiscord | <ache of head> Or subjective? Most of what I wrote were only my opinions after all. |
11:30:50 | FromDiscord | <Ricky Spanish> true, im just zealous about the features i found in nim i suppose, since for me the ability to turn gc on and off was a huge part and getting to read the c was like willy wonka handing the keys to charlie and telling him to take what he likes |
11:31:19 | FromDiscord | <Rika> though nim's c output is not exactly readable perse |
11:31:21 | FromDiscord | <Ricky Spanish> yeh all true, dont wanna start a flame war online about programming languages... |
11:31:51 | FromDiscord | <ache of head> I mean, as long as you're on Nim's side, I think you can spark all the wars you want here. xD |
11:32:28 | FromDiscord | <ache of head> AND |
11:32:37 | FromDiscord | <ache of head> One big feature I realized I haven't touched upon are macros. |
11:32:48 | FromDiscord | <ache of head> I just kind of mushed them into "I like Nim's more" |
11:32:57 | FromDiscord | <ache of head> But now I see I should've wrote some more about them |
11:33:19 | * | rockcavera joined #nim |
11:33:39 | FromDiscord | <Rika> you'll need to compare them with rust macros though |
11:33:46 | FromDiscord | <Rika> good luck with that if you know neither |
11:33:48 | FromDiscord | <ache of head> Yp |
11:33:50 | FromDiscord | <ache of head> (edit) 'Yp' => 'Yep' |
11:34:08 | FromDiscord | <ache of head> I haven't done anything with Rust, let alone macros, for some time now |
11:34:17 | FromDiscord | <ache of head> (edit) 'I haven't done anything with Rust, let alone ... macros,' => 'I haven't done anything with Rust, let aloneRust' |
11:35:27 | aachh | fromdiscord: yardanico |
11:35:35 | aachh | sorry sorry accident |
11:35:40 | FromDiscord | <Rika> wonder how dumb reader macros would be on nim |
11:35:49 | * | aachh quit (Remote host closed the connection) |
11:49:14 | * | luis_ joined #nim |
11:53:27 | FromDiscord | <haxscramper> sent a code paste, see https://play.nim-lang.org/#ix=2v5K |
12:05:28 | * | FromDiscord quit (Remote host closed the connection) |
12:05:44 | * | FromDiscord joined #nim |
12:06:02 | * | supakeen quit (Quit: WeeChat 2.9) |
12:06:43 | * | supakeen joined #nim |
12:06:50 | * | superbia quit (Quit: WeeChat 2.9) |
12:17:20 | * | kinkinkijkin quit (Ping timeout: 244 seconds) |
12:21:29 | * | endragor quit (Quit: Leaving...) |
12:23:51 | * | endragor joined #nim |
12:25:16 | * | luis_ quit (Quit: luis_) |
12:25:54 | * | luis_ joined #nim |
12:28:09 | FromDiscord | <dom96> > Nice, I'm going to read it later π Btw I think I will end up trying nim, even though it won't help me find a new job anytime soonβ΅@maiagallo most languages are similar, knowing and contributing to a "new" programming language will give you far more knowledge/experience than simply writing Python and copy and pasting solutions from StackOverflow. And good companies do understand that. |
12:30:32 | FromGitter | <alehander92> one can learn both (popular tech and more experimental stuff) |
12:30:42 | * | kinkinkijkin joined #nim |
12:31:34 | FromDiscord | <dom96> Curious what everyone's thoughts are on the conversation I'm having here with a package maintainer: https://github.com/c-blake/hldiff/issues/1#issuecomment-678832853 (it's related to how Nimble handles package directory structures). |
12:31:34 | disbot | β₯ Add `installExt` to `hldiff.nimble` |
12:33:13 | FromDiscord | <dom96> (And you can tell me here instead of spamming that issue :)) |
12:33:22 | ForumUpdaterBot | New thread by Alexeypetrushin: How to convert tuple to JSON?, see https://forum.nim-lang.org/t/6720 |
12:34:15 | FromDiscord | <maiagallo> @dom96 true, but having some experience with a specific language definitely helps if it's the one the company's using π |
12:36:18 | * | lritter joined #nim |
12:43:51 | * | thomasross joined #nim |
12:46:33 | FromDiscord | <maiagallo> Dependencies have to be added manually to the nimble file, right? |
12:47:06 | FromGitter | <alehander92> dom96 what do you think about nix |
12:47:39 | FromGitter | <alehander92> a bit offtopic, just wondering if it's getting popular outside of haskell/enthusiasm people |
12:47:56 | FromDiscord | <dom96> > Dependencies have to be added manually to the nimble file, right?β΅@maiagallo yes |
12:48:22 | FromDiscord | <dom96> > dom96 what do you think about nixβ΅@alehander92[Gitter]#0000 haven't used it, so not much thoughts on it. |
12:49:17 | FromDiscord | <Rika> i like nix and nixos, the thought of a consolidated config for everything is nice |
12:49:26 | FromDiscord | <Rika> means the syntaxes for everything is mainly the same |
12:51:11 | FromDiscord | <maiagallo> Thanks! Just to understand if I'm missing something: I can search for stuff in the stdlib from the docs page, but on nimble I have to navigate to the package since it doesn't seem to index packages' docs, right? |
12:51:25 | FromDiscord | <dom96> yep |
12:51:35 | FromDiscord | <maiagallo> great thanks! |
12:51:48 | FromDiscord | <maiagallo> And there's nothing like `nimble build --file-watch` |
12:52:14 | FromDiscord | <maiagallo> (Sorry for the obvious questions, I just want to be sure I'm not doing unnecessary things π ) |
12:52:28 | solitudesf | no, there isn't |
12:53:23 | FromDiscord | <maiagallo> Thanks a lot guys! |
12:54:20 | FromDiscord | <maiagallo> I'm following some examples (the nim days right now) and there's a lot of deprecated/broken code. It could be a nice project to learn the language better |
12:54:39 | Yardanico | in nim days? |
12:54:44 | Yardanico | I think it's still working |
12:55:35 | FromGitter | <alehander92> @dom96 thanks :) |
12:55:38 | FromDiscord | <maiagallo> the URL shortening is not working for me now |
12:55:54 | FromDiscord | <maiagallo> I think I had some other issues here and there, deprecated functions for sure |
12:57:51 | * | Senketsu joined #nim |
13:03:28 | * | Senketsu quit (Ping timeout: 256 seconds) |
13:06:10 | FromDiscord | <krisppurg> hey guys, do you know how to remove an item in a json array or at least change a json array? |
13:08:26 | FromDiscord | <Rika> does `delete` (supplying the json array and the index) not work |
13:09:11 | FromDiscord | <krisppurg> hold on |
13:10:40 | * | Senketsu joined #nim |
13:11:09 | FromDiscord | <krisppurg> nope |
13:11:29 | FromDiscord | <krisppurg> @Rika |
13:12:59 | FromDiscord | <Rika> let me read the docs then |
13:14:30 | FromDiscord | <Rika> @krisppurg try `jsonarr.elems.delete(idx)` (tho im not sure how safe or correct this is) |
13:14:56 | FromDiscord | <krisppurg> Okay |
13:15:22 | * | Senketsu quit (Ping timeout: 256 seconds) |
13:16:44 | FromDiscord | <ache of head> Can macros recur? |
13:16:56 | FromDiscord | <Rika> you mean recurse? |
13:16:59 | FromDiscord | <ache of head> yes |
13:17:00 | Yardanico | not infinitely, but yes |
13:17:01 | Yardanico | why not? |
13:17:12 | FromDiscord | <ache of head> How would I recur with a static parameter? |
13:17:28 | FromDiscord | <ache of head> I have a static[seq[string]] and I want to pass a modified version of it every time I recur |
13:18:45 | FromDiscord | <ache of head> As in, when I try to recur the error I get a type error, that a seq[string] was received where a static[seq[string]] was expected |
13:18:53 | FromDiscord | <ache of head> (edit) 'error,' => 'error' |
13:18:57 | FromDiscord | <krisppurg> oh it worked thank you @Rika |
13:19:27 | * | leorize quit (Quit: WeeChat 2.8) |
13:19:42 | FromDiscord | <Rika> π |
13:20:38 | * | thomasross quit (Ping timeout: 260 seconds) |
13:21:17 | FromGitter | <alehander92> macros dont return |
13:21:27 | FromGitter | <alehander92> they expand |
13:21:39 | FromGitter | <alehander92> compile time functions return |
13:21:53 | Zevv | real men dont return, the expand |
13:21:56 | FromGitter | <alehander92> ah sorry, i read return instead of recur |
13:22:09 | FromGitter | <alehander92> hm, so yeah, they can recur |
13:22:18 | Zevv | real men dont retcur, they expand |
13:22:22 | FromGitter | <alehander92> haha |
13:22:23 | Zevv | damn typos |
13:22:32 | Zevv | typing is hard |
13:22:40 | FromGitter | <alehander92> real man use real numbers |
13:23:12 | Zevv | i'm a very integer person, tho |
13:23:25 | FromGitter | <alehander92> integerman! |
13:23:32 | Zevv | disruptek, he's a complex dude |
13:23:33 | FromGitter | <alehander92> inte german?? |
13:24:09 | FromGitter | <alehander92> at least we're not double persons |
13:24:14 | FromDiscord | <ache of head> xDD |
13:25:57 | * | luis_ quit (Quit: luis_) |
13:28:30 | FromDiscord | <ache of head> Oh wait |
13:28:39 | FromDiscord | <ache of head> I think there's such a thing as `static()` |
13:28:45 | * | Kaivo quit (Quit: WeeChat 2.9) |
13:28:45 | FromDiscord | <ache of head> Will this work? |
13:29:11 | FromDiscord | <ache of head> Nope, can't evaluate at compile time |
13:29:11 | FromDiscord | <ache of head> makes sense |
13:30:26 | FromGitter | <alehander92> what are you trying to do |
13:30:59 | * | luis_ joined #nim |
13:32:09 | FromDiscord | <ache of head> Hmmm, how can I put this |
13:32:49 | FromGitter | <alehander92> just tell us as it is man |
13:32:58 | FromGitter | <alehander92> we're here to help you |
13:33:00 | FromGitter | <alehander92> and make bad puns |
13:33:04 | FromGitter | <alehander92> and zevv is out of puns |
13:33:04 | FromGitter | <alehander92> maybe |
13:33:06 | * | awe00 joined #nim |
13:33:17 | FromDiscord | <ache of head> xD |
13:33:19 | FromDiscord | <ache of head> Okay, so: |
13:33:50 | FromDiscord | <ache of head> For every seq[string] the macro gets, it should generate something like this: |
13:36:40 | FromDiscord | <maiagallo> is it possible to call a macro from another macro? |
13:36:55 | FromDiscord | <ache of head> Okay, wait |
13:36:59 | FromDiscord | <ache of head> I think I solved my problem |
13:37:02 | FromDiscord | <ache of head> I don't need to recur |
13:37:40 | * | endragor quit (Remote host closed the connection) |
13:38:21 | FromGitter | <alehander92> real man! |
13:38:26 | FromDiscord | <lqdev> @maiagallo sure |
13:38:37 | FromGitter | <alehander92> you can expand a macro from another macro |
13:38:38 | FromDiscord | <lqdev> it's even possible to generate a call to a macro from a macro |
13:41:28 | * | endragor joined #nim |
13:41:33 | FromGitter | <alehander92> yes, very useful ^ |
13:44:32 | FromDiscord | <maiagallo> does it need some special syntax? How do I call it? |
13:44:58 | Yardanico | you just generate code which calls another macro in your macro |
13:45:13 | Yardanico | compiler will expand everything over and over until it's fully expanded |
13:45:29 | Yardanico | or at least until the recursion depth limit wasn't reached :) |
13:45:52 | FromDiscord | <ache of head> how many ritual sacrifices have been made in order to create the Nim compiler? |
13:46:15 | Yardanico | it was initially written in Free Pascal |
13:46:26 | Yardanico | then translated to nim with pas2nim |
13:47:08 | FromDiscord | <ache of head> Wait, really? |
13:47:12 | Yardanico | of course? |
13:47:19 | FromDiscord | <Hearthstone> O |
13:47:50 | Yardanico | https://github.com/nim-lang/Nim/blob/devel/compiler/readme.md |
13:48:33 | Yardanico | https://github.com/nim-lang/Nim/tree/405b86068e6a3d39970b9129ceec0a9108464b28/nim |
13:49:18 | FromDiscord | <ache of head> This is like |
13:49:19 | FromDiscord | <ache of head> mindblowing |
13:49:54 | FromDiscord | <ache of head> I didn't know it was translated |
13:50:15 | Yardanico | well since then it has been developed in nim |
13:50:16 | FromDiscord | <dom96> Other fun fact: Nim used to live in Canonical's launchpad and use Bazaar π |
13:50:27 | Yardanico | ah yeah I saw the bug tracker |
13:51:08 | FromDiscord | <dom96> Took me some time to convince Araq to move to GitHub. Good times. |
13:55:12 | FromDiscord | <Hearthstone> Lmao |
13:55:28 | FromDiscord | <Hearthstone> Why not make a mirror to GitLab btw |
13:55:36 | FromDiscord | <Hearthstone> A one way mirror |
13:55:43 | Yardanico | it was there |
13:55:48 | Yardanico | but then was abandoned, not sure why :P |
13:55:55 | Yardanico | ask @dom96 about it :D |
13:55:56 | FromDiscord | <Hearthstone> Oh? |
13:56:07 | FromDiscord | <dom96> https://gitlab.com/nim-lang/nim |
13:56:13 | Yardanico | yep |
13:56:16 | FromDiscord | <dom96> > Repository mirroring has been paused due to too many failed attempts, and can be resumed by a project maintainer. |
13:56:17 | FromDiscord | <dom96> lol |
13:56:23 | Yardanico | " Pull mirroring failed 2 years ago." |
13:56:30 | Yardanico | I thought you knew :P |
13:56:45 | FromDiscord | <dom96> Seems nobody cares otherwise they'd complain |
13:56:48 | FromDiscord | <Hearthstone> Oof |
13:56:53 | Yardanico | no one knows* |
13:57:29 | FromDiscord | <lqdev> >5 stars |
13:57:34 | FromDiscord | <lqdev> yeah pretty mcuh |
13:57:36 | FromDiscord | <lqdev> (edit) 'mcuh' => 'much' |
14:06:24 | * | superbia joined #nim |
14:08:43 | * | endragor quit (Remote host closed the connection) |
14:08:54 | FromDiscord | <ache of head> Okay, turns out I need the macro |
14:09:00 | FromDiscord | <ache of head> the recursion* |
14:09:11 | * | endragor joined #nim |
14:10:54 | FromDiscord | <ache of head> Basically for every `seq[string]` the macro gets, it should generate this. For this case the `seq[string]` is `@["me", "location", "city"]` |
14:11:31 | FromDiscord | <ache of head> https://media.discordapp.net/attachments/371759389889003532/747458066072600697/Zrzut_ekranu_2020-08-24_o_16.11.01.png |
14:11:44 | FromDiscord | <ache of head> So it would always start with `globalObject` |
14:11:59 | FromDiscord | <ache of head> And in the bracket expression there would go the first element of the seq |
14:12:36 | FromDiscord | <ache of head> and then repeat `.value` with the next element in brackets |
14:13:14 | FromDiscord | <ache of head> I think I got the macro right but I don't know how I can pass a `static[seq[string]]` down |
14:18:13 | * | endragor quit (Ping timeout: 264 seconds) |
14:24:32 | ForumUpdaterBot | New thread by Doongjohn: Generic vs static parameter, see https://forum.nim-lang.org/t/6721 |
14:27:22 | * | narimiran quit (Ping timeout: 265 seconds) |
14:28:02 | Zevv | ping @clyybber |
14:31:44 | * | endragor joined #nim |
14:36:05 | * | endragor quit (Ping timeout: 240 seconds) |
14:38:41 | * | Vladar quit (Quit: Leaving) |
14:44:38 | Zevv | I am surprised by some things I learn from inspecting what happens under ARC |
14:44:44 | Yardanico | like? |
14:44:53 | * | thomasross joined #nim |
14:45:04 | Zevv | I get COW behaviour when copying strings around |
14:45:09 | Zevv | I was not aware nim did that |
14:45:14 | Yardanico | yes it does that now :) |
14:45:56 | Zevv | dude |
14:46:00 | Zevv | who made up that shit |
14:46:06 | Yardanico | wat |
14:46:22 | Zevv | well, I just realized I know this |
14:46:28 | Zevv | it was the bad performance in base64.nim |
14:47:38 | Zevv | every mutation of a string makes nim go out to NimPrepareStrMutationV2() |
14:47:57 | Zevv | I hadn't put 1&1 together yet that this means strings get COWed |
14:49:05 | Zevv | I'm trhing to create some small, obvious test programs to illustrate what ARC does under the hood |
14:49:08 | Zevv | but's not easy |
14:49:13 | * | hnOsmium0001 joined #nim |
14:52:36 | * | hzx joined #nim |
14:58:00 | * | krux02_ joined #nim |
14:58:25 | * | solitudesf- joined #nim |
15:01:30 | * | euantorano_ joined #nim |
15:02:05 | * | hnOsmium0001_ joined #nim |
15:02:29 | * | drewr` joined #nim |
15:03:16 | * | hnOsmium0001 quit (Ping timeout: 240 seconds) |
15:03:16 | * | krux02 quit (Ping timeout: 240 seconds) |
15:03:16 | * | euantorano quit (Ping timeout: 240 seconds) |
15:03:16 | * | solitudesf quit (Ping timeout: 240 seconds) |
15:03:16 | * | drewr quit (Ping timeout: 240 seconds) |
15:03:16 | * | dddddd quit (Ping timeout: 240 seconds) |
15:03:17 | * | euantorano_ is now known as euantorano |
15:03:18 | * | hnOsmium0001_ is now known as hnOsmium0001 |
15:03:38 | * | kwilczynski quit (Ping timeout: 240 seconds) |
15:03:39 | * | jwm224 quit (Ping timeout: 240 seconds) |
15:03:40 | FromGitter | <ynfle> Is it a bug that https://github.com/nim-lang/Nim/blob/devel/lib/pure/json.nim#L361 doesn't have `[T: object | tuple]`? It would work for both |
15:04:13 | * | Mortir joined #nim |
15:05:05 | * | jwm224 joined #nim |
15:05:21 | Mortir | hello |
15:06:02 | * | muffindrake quit (Ping timeout: 240 seconds) |
15:06:02 | * | schurig quit (Ping timeout: 240 seconds) |
15:06:07 | * | solitudesf- is now known as solitudesf |
15:06:27 | Mortir | Was taking a look at this example: https://gist.github.com/zacharycarter/846869eb3423e20af04dea226b65c18f, it mentions the possibility of using C libraries. |
15:06:54 | Yardanico | yes |
15:07:04 | * | muffindrake joined #nim |
15:07:05 | FromGitter | <ynfle> Was that to me? |
15:07:15 | Yardanico | no :) i don't know |
15:07:25 | Yardanico | try changing it by adding "tuple" and see if it works |
15:07:25 | * | schurig joined #nim |
15:07:34 | Yardanico | also check anonymous tuples |
15:07:40 | FromGitter | <ynfle> I will |
15:07:58 | Mortir | But, is it possible to use the OS version of a library or it has to be included among the compiled binary? |
15:08:05 | Yardanico | Mortir: yes, it is |
15:08:11 | Yardanico | you'll have to use the dynlib pragma |
15:08:22 | * | thomasross quit (Ping timeout: 256 seconds) |
15:08:36 | Yardanico | https://nim-lang.org/docs/manual.html#foreign-function-interface-dynlib-pragma-for-import |
15:09:56 | * | endragor joined #nim |
15:09:58 | * | stefantalpalaru_ joined #nim |
15:09:59 | * | stefantalpalaru quit (Remote host closed the connection) |
15:10:03 | * | kwilczynski joined #nim |
15:10:05 | Mortir | Yardanico: thank you |
15:11:13 | * | Mortir left #nim (#nim) |
15:11:43 | FromDiscord | <Clyybber> Zevv: Ayy |
15:11:59 | FromDiscord | <Clyybber> Zevv: The solution to your mutating thing is that its now inlined |
15:12:08 | FromDiscord | <Clyybber> the COW behaviour is just cursor inference |
15:13:53 | FromDiscord | <Clyybber> HA! I just realized one problem with shadow scopes is not a thing, because compiles has a scope |
15:13:56 | FromDiscord | <Clyybber> which is great |
15:14:09 | * | arecacea1 quit (Remote host closed the connection) |
15:14:17 | * | dddddd joined #nim |
15:15:03 | * | arecacea1 joined #nim |
15:15:10 | Zevv | no way cursor inference. I have an object F with a string in there. I do 'let a = F(s: "foo")` and then `let b = a`. Now a and b share the same string data. |
15:15:17 | * | hzx quit (Quit: Going offline, see ya! (www.adiirc.com)) |
15:15:49 | Zevv | Oh waaait it's a constant initially |
15:15:56 | Zevv | that's the strv2 doing that |
15:16:20 | Zevv | and what's my mutated thing? |
15:16:44 | * | schurig_ joined #nim |
15:17:24 | * | schurig quit (Ping timeout: 240 seconds) |
15:17:49 | * | apahl_ joined #nim |
15:17:55 | * | apahl quit (Ping timeout: 240 seconds) |
15:17:56 | * | supakeen quit (Ping timeout: 240 seconds) |
15:18:27 | * | supakeen joined #nim |
15:20:35 | * | endragor quit (Ping timeout: 240 seconds) |
15:21:32 | disruptek | i think he's talking about your kids. |
15:22:40 | * | gangstacat quit (*.net *.split) |
15:22:41 | * | silvernode[m] quit (*.net *.split) |
15:22:41 | * | darrion_oakenbow quit (*.net *.split) |
15:22:42 | * | MTRNord[m] quit (*.net *.split) |
15:22:42 | * | alfabetacain[m] quit (*.net *.split) |
15:22:42 | * | D_ quit (*.net *.split) |
15:22:43 | * | LyndsySimon quit (*.net *.split) |
15:22:43 | * | Hotbees quit (*.net *.split) |
15:22:43 | * | hpyc9 quit (*.net *.split) |
15:22:43 | * | crem quit (*.net *.split) |
15:22:43 | * | alehander92 quit (*.net *.split) |
15:22:43 | * | zielmicha__ quit (*.net *.split) |
15:22:44 | * | GitterIntegratio quit (*.net *.split) |
15:22:51 | Zevv | oh is that it. I already wondered where these little people came from |
15:23:12 | Zevv | well there has been some considerable mutation going on from my genes, I'm sure of that |
15:23:42 | Zevv | these are some bad mouthed pricks with an attention span of about 4 seconds each |
15:25:27 | * | leorize[m] quit (Ping timeout: 240 seconds) |
15:25:36 | * | jklhyd[m] quit (Ping timeout: 246 seconds) |
15:25:36 | * | ee7[m] quit (Ping timeout: 246 seconds) |
15:25:36 | * | skrylar[m] quit (Ping timeout: 246 seconds) |
15:25:36 | * | vycb[m] quit (Ping timeout: 246 seconds) |
15:25:36 | * | planetis[m] quit (Ping timeout: 246 seconds) |
15:25:44 | * | torbencarstens[m quit (Ping timeout: 244 seconds) |
15:26:21 | Zevv | is 'owned' still relevant these days? |
15:26:37 | * | ee7[m] joined #nim |
15:26:37 | * | vycb[m] joined #nim |
15:26:38 | * | jklhyd[m] joined #nim |
15:26:39 | * | planetis[m] joined #nim |
15:27:25 | * | torbencarstens[m joined #nim |
15:27:49 | * | leorize[m] joined #nim |
15:29:36 | FromDiscord | <Clyybber> not yet |
15:29:47 | FromDiscord | <Clyybber> its in limbo |
15:30:00 | * | alfabetacain[m] joined #nim |
15:30:29 | FromDiscord | <Clyybber> but I have an idea, replacing owned by nocopy |
15:30:50 | FromDiscord | <Clyybber> doesn't even need to be implemented in the compiler I think |
15:31:10 | FromDiscord | <Clyybber> nocopy[T] is T but with `=` {.error.} |
15:31:23 | FromDiscord | <Clyybber> Then lent and cursors/views can be united |
15:31:42 | FromDiscord | <Clyybber> and if you explicitly want a lent that you want to prevent copies from |
15:31:47 | FromDiscord | <Clyybber> you can do nocopy lent T |
15:32:50 | Zevv | hmm i need to let that sink in I guess :) |
15:33:54 | Zevv | I think my writeup ends up simplere then I expected it to be |
15:33:56 | * | gangstacat joined #nim |
15:33:56 | * | silvernode[m] joined #nim |
15:33:56 | * | D_ joined #nim |
15:33:56 | * | LyndsySimon joined #nim |
15:33:56 | * | Hotbees joined #nim |
15:33:56 | * | hpyc9 joined #nim |
15:33:56 | * | crem joined #nim |
15:34:08 | FromDiscord | <Clyybber> destructors.md is simple itself |
15:34:14 | * | MTRNord[m] joined #nim |
15:34:14 | * | darrion_oakenbow joined #nim |
15:34:14 | * | skrylar[m] joined #nim |
15:34:14 | * | alehander92 joined #nim |
15:34:14 | * | zielmicha__ joined #nim |
15:34:14 | * | GitterIntegratio joined #nim |
15:34:27 | Zevv | it's now telling what a GC is. How nim got smarter so it does no longer need a GC. How it does refcounting and restructors. And the rest will be examples of the smarts it can do to allow moves, sinks, rvos and the like |
15:34:37 | * | skrylar[m] quit (Changing host) |
15:34:37 | * | skrylar[m] joined #nim |
15:34:38 | * | MTRNord[m] quit (Changing host) |
15:34:38 | * | MTRNord[m] joined #nim |
15:34:38 | * | darrion_oakenbow quit (Changing host) |
15:34:38 | * | darrion_oakenbow joined #nim |
15:34:50 | Zevv | hmm, i like that word. restrutctor. I will have to find a use for it |
15:35:00 | * | abm quit (Ping timeout: 256 seconds) |
15:35:29 | * | luis_ quit (Quit: luis_) |
15:36:35 | * | hyiltiz quit (Ping timeout: 258 seconds) |
15:37:43 | * | endragor joined #nim |
15:41:59 | FromDiscord | <Clyybber> can I see it |
15:42:57 | FromDiscord | <Clyybber> ah, found it |
15:43:06 | FromDiscord | <Clyybber> nice introduction |
15:44:29 | Zevv | it should take the fear away and try to answer the recurring questions here on #nim |
15:44:50 | Zevv | you can't send people to ar4qs "destructors and move semantics" doc. they will cry and run away |
15:45:01 | disruptek | that's the idea. |
15:50:39 | * | endragor quit (Ping timeout: 246 seconds) |
15:56:48 | * | endragor joined #nim |
15:59:25 | * | PMunch quit (Quit: leaving) |
15:59:28 | * | hyiltiz joined #nim |
15:59:28 | * | hyiltiz quit (Changing host) |
15:59:28 | * | hyiltiz joined #nim |
16:05:36 | ForumUpdaterBot | New thread by Clonk: Nim - Julia bridge , see https://forum.nim-lang.org/t/6723 |
16:15:09 | * | endragor quit (Ping timeout: 265 seconds) |
16:16:36 | * | endragor joined #nim |
16:22:45 | FromGitter | <Knaque> Am I stupid? `let x = letters[rand(letters.len-1)].string`, where `letters` is `('a'..'z').toSeq`, throws `Error: type mismatch: got <char> but expected 'string'`. |
16:22:48 | shashlick | @leorize - have we finally moved to the new nightlies? |
16:24:28 | * | awe00 quit (Ping timeout: 246 seconds) |
16:26:19 | FromGitter | <Knaque> The first thing I came up with to get around that was doing `x & ""`, but that seems janky. What was I doing wrong? |
16:27:50 | ForumUpdaterBot | New thread by Dsrw: Pause/resume the Nim VM, see https://forum.nim-lang.org/t/6724 |
16:29:12 | FromDiscord | <Rika> @Knaque use $ instead |
16:30:12 | FromGitter | <Knaque> Well now that you mention it, I've literally had that *exact* issue before, and came to that *exact* solution, and apparently just forgot. Guess I'm way too used to casting numbers with `.int` and `.float` that I forget `$` exists. |
16:31:39 | FromGitter | <Knaque> Thank you for reminding me that I am, in fact, stupid. |
16:32:33 | * | awe00 joined #nim |
16:35:35 | * | endragor quit (Remote host closed the connection) |
16:35:41 | * | endragor joined #nim |
16:42:32 | FromDiscord | <lqdev> Knaque: also `('a'..'z').toSeq` is inefficient, you're better off using a set `{'a'..'z'}` |
16:42:45 | FromDiscord | <lqdev> and then just `sample(letters)` |
16:42:47 | FromDiscord | <Rosen> is casting numbers with `.int` etc considered proper practice over `toInt` etc or is it personal preference |
16:43:40 | FromDiscord | <Rosen> (edit) 'preference' => 'preference?' |
16:43:49 | * | endragor quit (Remote host closed the connection) |
16:49:22 | FromDiscord | <Rika> its conversion, not casting, and im pretty sure its preference |
16:58:23 | * | superbia1 joined #nim |
17:00:49 | * | superbia quit (Ping timeout: 264 seconds) |
17:04:28 | FromDiscord | <Rosen> oh that's right, my b |
17:08:47 | FromDiscord | <haxscramper> When wrapping C `{.pure.}` annotation on enums is necessary only to avoid name clashes, not for compatibility with C code? |
17:10:00 | disruptek | correct. |
17:14:16 | * | endragor joined #nim |
17:18:44 | disruptek | Zevv: s/more work then/more work than/ |
17:18:58 | FromGitter | <alehander92> disruptek |
17:19:01 | FromGitter | <alehander92> give me cool project |
17:19:32 | disruptek | i have so many blockers. |
17:19:49 | FromGitter | <alehander92> so inventing a new os |
17:19:52 | FromGitter | <alehander92> is not the solution |
17:20:01 | FromGitter | <alehander92> ok, something small |
17:20:18 | FromGitter | <alehander92> do you want a different editor |
17:20:22 | FromGitter | <alehander92> or vcs |
17:20:28 | FromGitter | <alehander92> or a different LETTER |
17:20:43 | disruptek | do you want a real project? |
17:20:51 | FromGitter | <alehander92> something small |
17:21:15 | disruptek | !repo ndoc |
17:21:17 | disbot | https://github.com/nodeca/ndoc -- 9ndoc: 11js port of pdoc, with extentions 15 93β 8π΄ 7& 29 more... |
17:21:22 | disruptek | not that one. |
17:21:25 | disruptek | !repo disruptek/ndoc |
17:21:26 | disbot | https://github.com/disruptek/ndoc -- 9ndoc: 11like pydoc but for nim 15 0β 0π΄ |
17:21:30 | disruptek | i always make that mistake. |
17:21:31 | FromDiscord | <dom96> !repo nim-lang/needed-packages |
17:21:31 | disbot | no results π’ |
17:21:46 | FromDiscord | <dom96> !repo nim-lang/needed-libraries |
17:21:47 | disbot | https://github.com/nim-lang/needed-libraries -- 9needed-libraries: 11This repository contains a list a needed libraries. 15 82β 2π΄ |
17:21:50 | FromGitter | <alehander92> i created the needed libs |
17:21:51 | FromGitter | <alehander92> repo |
17:21:59 | FromGitter | <alehander92> and still i forget about it |
17:22:04 | FromDiscord | <dom96> lol |
17:22:10 | FromDiscord | <dom96> time for you to resolve its issues π |
17:22:18 | FromGitter | <alehander92> noo |
17:22:26 | FromDiscord | <Clyybber> disruptek: Wait, so a smart doc? |
17:22:31 | FromGitter | <alehander92> i can write down some rfc-s tjo |
17:22:34 | FromGitter | <alehander92> tho* |
17:22:36 | FromDiscord | <Clyybber> basically, you ask a question and it answers you? |
17:22:51 | FromDiscord | <Clyybber> since when does pydoc do that |
17:22:59 | FromDiscord | <dom96> Surprised you're looking for projects though |
17:23:01 | disruptek | the stories are examples of questions you want to use ndoc to answer. |
17:23:03 | FromDiscord | <dom96> I have sooooo many ideas |
17:23:04 | FromGitter | <alehander92> we need to stop relying on google |
17:23:08 | FromGitter | <alehander92> dom96 me too |
17:23:15 | FromGitter | <alehander92> but that's exactly the reason |
17:23:24 | FromGitter | <alehander92> i burn out from the choice |
17:23:42 | FromDiscord | <Clyybber> make music |
17:23:55 | disruptek | gimme a link to some good chants. |
17:25:25 | * | endragor quit (Ping timeout: 240 seconds) |
17:25:42 | disruptek | testes doesn't work in c due to a nim codegen bug in inheritance. |
17:25:51 | disruptek | don't get me started on cps. |
17:25:54 | FromDiscord | <Clyybber> heh |
17:26:01 | disruptek | and now nimph is blocked by truly insane concepts bugs. |
17:26:07 | FromDiscord | <Clyybber> bugs? |
17:26:17 | FromDiscord | <Clyybber> i saw your groups thing |
17:26:17 | disruptek | no two ways about it. |
17:26:36 | FromDiscord | <dom96> Why use concepts when they're up for a redesign at this point? |
17:26:49 | disruptek | they've been "up for a redesign" for ages. |
17:26:52 | FromDiscord | <Clyybber> they are not |
17:27:04 | disruptek | and i've been promised repeatedly that they are stable enough to use. |
17:27:12 | disruptek | so i finally said, fuck it. |
17:27:55 | disruptek | they've worked for me in the past but admittedly, i'm starting to lean in. |
17:28:10 | disruptek | clyybber: also, adding .explain causes an apparent hang. |
17:28:23 | disruptek | so that's extra fun. |
17:29:17 | FromDiscord | <dom96> clyybber: what makes you so sure? |
17:29:41 | FromGitter | <alehander92> disruptek : https://www.youtube.com/watch?v=TvoVuOC_KKE |
17:29:47 | Yardanico | lol |
17:30:00 | FromDiscord | <Clyybber> disruptek: Nice |
17:30:01 | FromGitter | <alehander92> dom96 : concepts have their place |
17:30:18 | FromDiscord | <Clyybber> @dom96 I think a redesign should be build around them |
17:30:20 | disruptek | alehander92: thanks. |
17:30:23 | FromDiscord | <Clyybber> so more like sugar |
17:30:25 | FromGitter | <alehander92> iirc even if their impl changes, their existence would be useful |
17:30:26 | disruptek | this stuff is great. |
17:30:31 | FromGitter | <alehander92> it is. |
17:31:03 | FromDiscord | <dom96> clyybber: I'm sure you've seen Araq's RFC https://github.com/nim-lang/RFCs/issues/168 |
17:31:05 | disbot | β₯ Concepts and type-checking generics ; snippet at 12https://play.nim-lang.org/#ix=23U8 |
17:31:20 | FromGitter | <alehander92> it helps the soul |
17:31:24 | FromDiscord | <Clyybber> yeah |
17:31:25 | FromDiscord | <Clyybber> I have |
17:31:30 | disruptek | afaic, the problem isn't the design but the impl. really unclear what these RFCs are addressing. |
17:31:34 | FromDiscord | <dom96> alehander92: I'm not suggesting we should remove them, but I've been for changing how they work for a while. |
17:31:44 | FromGitter | <alehander92> but you can still use them |
17:32:10 | FromGitter | <alehander92> i think Araq's point in one issue was that using existing concepts (if they work fine) should be good |
17:32:16 | disruptek | dom96: what don't you like? |
17:32:24 | bung | testament errormsg: matchs substring ? |
17:32:33 | FromGitter | <alehander92> the syntax which is used for writing might change |
17:32:50 | FromDiscord | <dom96> disruptek: that the concept body needs to be evaluated by the VM as if it's a compile-time procedure |
17:32:52 | disruptek | clyybber: also, testes is really nice to use. |
17:33:03 | FromDiscord | <Clyybber> @dom96 thats the power |
17:33:20 | disruptek | i can't imagine giving that up. |
17:33:50 | FromDiscord | <dom96> That power is entirely unnecessary as Araq has demonstrated in his RFC |
17:33:55 | FromGitter | <alehander92> what do you use them for |
17:34:14 | FromDiscord | <Clyybber> except that it wasn't demonstrated |
17:34:17 | FromDiscord | <dom96> Also, I would argue that what is far more important are runtime interfaces |
17:34:27 | FromDiscord | <Clyybber> fair |
17:34:32 | FromDiscord | <Clyybber> but those can be built today |
17:34:34 | FromDiscord | <dom96> So that I don't have to merge things like this https://github.com/nim-lang/irc/pull/20/files :/ |
17:34:35 | disbot | β₯ Added TOR support |
17:34:36 | FromDiscord | <Clyybber> via macros |
17:35:02 | FromDiscord | <Clyybber> all of this stuff can be build ontop of concepts and case objects via macros |
17:35:12 | FromDiscord | <dom96> yes, that has been the message since I started using Nim |
17:35:14 | FromGitter | <alehander92> yep |
17:35:15 | disruptek | we need to take better advantage of types and types are compile-time. there's just no way around that. |
17:35:21 | FromGitter | <alehander92> we should just include them in stdlib |
17:35:28 | disruptek | runtime is never the weak link ime. |
17:35:29 | FromGitter | <alehander92> something like a default interface macro |
17:35:30 | FromDiscord | <dom96> We need runtime interfaces in the stdlib, whether those are implemented in the compiler or via macros (I don't really care which) |
17:35:45 | disruptek | it can be a library. |
17:35:53 | FromDiscord | <Clyybber> !repo interfaced |
17:35:55 | disbot | https://github.com/andreaferretti/interfaced -- 9interfaced: 11 15 24β 4π΄ & 29 more... |
17:35:58 | FromGitter | <alehander92> too much fragmentation |
17:36:10 | FromDiscord | <dom96> The stdlib needs to use them. |
17:36:12 | FromDiscord | <Clyybber> yeah |
17:36:12 | FromGitter | <alehander92> i start to turn back to not small stdlibs |
17:36:53 | FromDiscord | <Clyybber> alehander92: https://www.youtube.com/watch?v=01SOLEftSOA |
17:37:07 | disruptek | stdlib shouldn't adopt this stuff until it is much more polished. |
17:37:14 | bung | does testament errormsg matchs substring ? |
17:37:36 | disruptek | dunno, but something tells me you have the source. |
17:37:44 | * | jdorr joined #nim |
17:37:51 | FromDiscord | <dom96> > stdlib shouldn't adopt this stuff until it is much more polished.β΅yes, it's time for it to be polished |
17:38:23 | disruptek | well, 3 years, no update. not even proper docs. |
17:38:54 | disruptek | Yardanico: how often is interfaced referenced in .nimble files? |
17:38:59 | FromDiscord | <Clyybber> this is newer https://github.com/xflywind/shene |
17:39:03 | Yardanico | disruptek: lol |
17:39:19 | FromDiscord | <dom96> It's a chicken and egg problem |
17:39:42 | FromDiscord | <dom96> I've got little reason to use interfaced because I don't know if others will abide by it |
17:40:01 | Yardanico | disruptek: as far as I can see - in 0 modules :) |
17:40:04 | disruptek | this attitude is infuriating to me, honestly. |
17:40:26 | disruptek | it's just a general distrust of dependencies that makes growth impossible. |
17:40:26 | FromDiscord | <dom96> And actually, the one thing I want to use interfaced for I cannot |
17:40:30 | jdorr | Hello, anyone got time for what I suspect is an very basic Nim question? |
17:40:32 | FromDiscord | <dom96> because it's in the stdlib... |
17:40:36 | Yardanico | jdorr: sure, ask away |
17:40:40 | FromDiscord | <dom96> jdorr: don't ask to ask, just ask |
17:40:46 | Yardanico | dontasktoask.com :) |
17:41:49 | jdorr | If I declare a table with `var tbl = initTable[int, int]()`, whats the syntax for when I want to pass it as a parameter? |
17:41:49 | jdorr | I've tried `proc doStuff(tbl2:[int, int])` and some other permutations, but no luck |
17:41:53 | * | tane joined #nim |
17:41:58 | Yardanico | Table[int, int] |
17:42:18 | Yardanico | https://nim-lang.org/docs/tables.html#Table you can see the "Table" type has two generic types |
17:42:25 | Yardanico | well, uses two of them |
17:42:32 | Yardanico | so you just use the same syntax |
17:43:22 | Zevv | I just realized someting thats source for confusion in the arc discussion |
17:43:25 | Yardanico | so proc doStuff(tbl2: Table[int, int]) |
17:43:35 | Zevv | we start rambling about refs first |
17:43:47 | Zevv | and then all this move semantics complexity to avoid copies |
17:44:11 | Zevv | but when using refs, there is no copying because we just have a ref thing |
17:44:20 | FromDiscord | <Clyybber> yeah :P |
17:44:23 | Zevv | thats mostly relevant with non-ref things |
17:44:29 | FromDiscord | <Clyybber> you could talk about seqs and strings |
17:44:33 | Zevv | so why the hell is all that in one document |
17:44:49 | FromDiscord | <Clyybber> because it makes sense |
17:44:59 | Zevv | yes but no but yes |
17:45:10 | FromDiscord | <Clyybber> seqs and strings are the kind-of-value-but-ref types |
17:45:14 | FromDiscord | <Clyybber> that arc enables |
17:46:35 | FromDiscord | <haxscramper> If I have `typedef struct Impl* Api` but the `Impl` is not defined anywhere and C api uses `Api` for function parameters is it ok to map `type Api = distinct pointer` or it is better to do something like `type Impl = object` - no implementation and `type Api = ptr[Impl]`. |
17:46:56 | FromDiscord | <haxscramper> E.g defined dummy `Impl` type and use `ptr[Impl]` |
17:47:10 | jdorr | Thanks, Yardanico! |
17:48:00 | Zevv | clyybber: yeah maybe that is the bridge i need to go from one subject to the next |
17:48:45 | FromDiscord | <haxscramper> `Api` is just 'opaque pointer' according to documentation, so I assume it is safe to use either of these alternatives |
17:48:45 | disruptek | i still think you have to start with manual mm. |
17:48:55 | FromDiscord | <Clyybber> @haxscramper I prefer the distinct pointer way |
17:49:28 | FromDiscord | <Clyybber> prevents people from accidently dereffing your pointer and then causing bugs |
17:50:37 | * | jdorr quit (Quit: Leaving) |
17:53:12 | Zevv | disruptek: I tried that, but I don't think there's a gap there |
17:53:29 | Zevv | its pretty obvious how stuff works in a few lines. |
17:54:09 | Zevv | but the problem is brining up move semantics after that. Because why the hell do I need to move things if I just learned that stuff is reffed anyway |
17:54:42 | disruptek | moves are about the rc. |
17:55:04 | Zevv | yeah but rcs are about refs, I just explained |
17:55:08 | Zevv | its a *ref* count |
17:55:19 | disruptek | so what? |
17:55:57 | Zevv | I have an object called `Thing` and `var a = Thing()`. Now `a` is not a ref. |
17:56:02 | Zevv | I do `var b = a` |
17:56:04 | Zevv | b is not a ref |
17:56:14 | * | Zectbumo joined #nim |
17:56:21 | Zevv | so how the hell should I explain that these move tricks are related to refcounts |
17:56:28 | Zevv | there are no refs :) |
17:57:00 | disruptek | also there are no moves. |
17:57:58 | Zevv | fair enough, bad example :) |
17:58:23 | Zevv | but clyybber is right, strings and seqs are important |
17:58:46 | disruptek | sure. and people understand their weight. |
17:58:52 | * | narimiran joined #nim |
17:58:54 | disruptek | so moves and copies have some kind of value to them. |
17:58:57 | Zevv | clyybber is walking on thin ice. he's right more often then i am. he should learn to watch his back. |
17:59:53 | FromDiscord | <Clyybber> *hides |
18:03:50 | * | awe001 joined #nim |
18:05:50 | * | awe00 quit (Ping timeout: 265 seconds) |
18:06:02 | * | superbia1 is now known as superbia |
18:08:32 | FromDiscord | <dom96> 13watiopam |
18:08:42 | Yardanico | what |
18:08:46 | disruptek | dragons123 |
18:09:04 | FromDiscord | <dom96> the name of my new project |
18:09:11 | FromDiscord | <dom96> can you guess what it is? |
18:09:30 | disruptek | a password manager. |
18:09:46 | Zevv | correct horse battery staple |
18:15:17 | disruptek | i've long wanted to write a password generator that was respectful of mnemonics and hand position. |
18:15:31 | disruptek | there's your tiny project, alehander92. |
18:17:26 | Zevv | I got a nasty look from my local sysop the other day. The usual crap rules about "at least 12 chars, so much capital, so much digits, so much special chars" |
18:17:29 | Zevv | so i do 123qwe!@#QWE |
18:17:38 | Zevv | and all his rules were green |
18:17:46 | Zevv | so that's my default password now, everywhere. |
18:17:53 | Zevv | oops |
18:18:22 | disruptek | i still use passwords from servers i admin'd 20+ years ago. |
18:18:23 | Yardanico | hey, look, if you type your password out it's replaced! ******************* |
18:18:39 | Zevv | Dude. Are you new to irc? |
18:18:49 | Yardanico | actually comparatively yes |
18:18:57 | Yardanico | I've known it for ~4 years |
18:19:01 | Zevv | ok, fair enough |
18:22:16 | * | NimBot joined #nim |
18:22:52 | * | endragor joined #nim |
18:22:57 | * | solitudesf quit (Remote host closed the connection) |
18:23:00 | narimiran | Zevv: nobody said it yet, so i need to: nice xkcd reference! |
18:23:22 | * | solitudesf joined #nim |
18:23:52 | FromGitter | <martinium> hello everyone |
18:24:35 | FromGitter | <martinium> I am parsing a bunch of json objects where a specific key is in one and it isn't in the others. |
18:25:00 | FromGitter | <martinium> I am trying to iterate through and ignore that key when it exists and include it's output when it does |
18:25:20 | FromGitter | <martinium> I tried using .hasKey() but there is no pass keyword to skip? |
18:25:44 | FromGitter | <martinium> hasKey() == false then inside of conditional I wish to skip or pass. Is there any way to do that |
18:25:49 | FromDiscord | <dom96> `continue`? |
18:26:47 | narimiran | usually, python's pass is nim's discard |
18:26:59 | * | endragor quit (Ping timeout: 240 seconds) |
18:31:11 | * | stefantalpalaru_ is now known as stefantalpalaru |
18:31:14 | * | stefantalpalaru quit (Changing host) |
18:31:14 | * | stefantalpalaru joined #nim |
18:34:17 | FromGitter | <martinium> I thought continue keyword didn't exist in Nim |
18:34:21 | FromGitter | <martinium> usually gives me erros |
18:34:24 | FromGitter | <martinium> errors* |
18:34:53 | disruptek | we decided it should only be allowed in loops. |
18:35:37 | FromDiscord | <martinium> needs to get added to index on site |
18:35:54 | FromDiscord | <martinium> also, when dark mode is enabled search results box is pretty unreadable |
18:36:04 | Yardanico | fixed in devel |
18:36:07 | FromDiscord | <martinium> have to make a conditional to adjust the CSS to match dark mode |
18:36:17 | disruptek | https://nim-lang.org/docs/manual.html#statements-and-expressions-continue-statement |
18:36:20 | Yardanico | yes it's already fixed :) |
18:36:26 | FromDiscord | <martinium> ok good |
18:36:46 | FromDiscord | <martinium> 1.2.6 doesn't have this fix then I need to upgrade to latest nightly correct? |
18:37:18 | Yardanico | about CSS? yes |
18:37:36 | FromDiscord | <Rika> disruptek: wait python allows for continue outside of loops? |
18:37:52 | Yardanico | no |
18:38:13 | * | bung quit (Ping timeout: 265 seconds) |
18:38:35 | FromDiscord | <martinium> sent a long message, see http://ix.io/2v7N |
18:38:47 | FromDiscord | <martinium> spot the error |
18:38:59 | FromDiscord | <martinium> getting node.kind == JObject` [AssertionError] |
18:39:25 | Yardanico | well, does data["resources"] exist? |
18:39:26 | FromDiscord | <Rika> scan is probably a json object |
18:39:35 | FromDiscord | <Rika> wait |
18:39:37 | FromDiscord | <Rika> misread |
18:39:43 | Yardanico | also you can really just use https://nim-lang.org/docs/json.html#getOrDefault%2CJsonNode%2Cstring |
18:39:50 | * | apahl_ quit (Ping timeout: 246 seconds) |
18:39:53 | FromDiscord | <Rika> data["resources"] is prolly tje json object |
18:40:06 | FromDiscord | <martinium> correct and it exists |
18:40:21 | FromDiscord | <martinium> the key that exists sometimes and other times doesn't is called scanName |
18:41:02 | FromDiscord | <martinium> so python's pass == discard in Nim |
18:41:12 | FromDiscord | <martinium> discard was my first choice and what I had before |
18:41:16 | Yardanico | yes, but discard can also be used to discard stuff |
18:41:32 | Yardanico | but with "discard" you'll be getting an error, yes |
18:41:41 | Yardanico | because it'll try to check the "elif" then |
18:41:46 | Yardanico | ah nvm sorry |
18:42:02 | * | apahl joined #nim |
18:42:16 | FromDiscord | <martinium> funnnn |
18:42:18 | FromDiscord | <martinium> π |
18:42:24 | FromDiscord | <martinium> btw, I love this language |
18:42:29 | FromDiscord | <martinium> it really is best of all worlds |
18:42:39 | FromDiscord | <martinium> looks heavily influenced by OCaml |
18:42:50 | FromDiscord | <martinium> option types included here is a fantastic thing |
18:42:52 | Yardanico | but it's not :P |
18:42:56 | FromDiscord | <Rika> in what way? |
18:43:05 | FromDiscord | <Rika> option types are pretty common elsewhere isnt it |
18:43:08 | FromDiscord | <martinium> simplifies code |
18:43:16 | FromDiscord | <martinium> go doesn't have option types |
18:43:25 | FromDiscord | <martinium> let alone proper error handling |
18:43:26 | FromDiscord | <martinium> lol |
18:44:00 | FromDiscord | <martinium> also working with json is annoying since it requires marshaling into custom structs |
18:44:07 | FromDiscord | <Rika> go is like python but with all the downsides of static typing with less of its upsides |
18:44:08 | FromDiscord | <martinium> instead of direct key access |
18:44:37 | FromDiscord | <martinium> makes you go around by marshalling but its not the end of the world |
18:44:54 | FromDiscord | <Rika> you should probably get back to programming π |
18:45:12 | FromDiscord | <martinium> yeah, still a noob hehe |
18:45:26 | FromDiscord | <martinium> (edit) 'yeah, ... still' => 'yeah,I'm' |
18:47:28 | FromDiscord | <martinium> changed code to this and no output |
18:47:40 | FromDiscord | <martinium> do I need to specify to alone discard the iteration? |
18:47:44 | FromDiscord | <martinium> aka discard scan? |
18:47:57 | FromDiscord | <martinium> trying |
18:48:14 | FromDiscord | <martinium> no output either |
18:48:25 | Yardanico | no |
18:48:28 | Yardanico | you just "discard" |
18:48:34 | Yardanico | "discard scan" will discard the value of "scan" |
18:48:42 | Yardanico | we need more context of what exactly fails, and on what line :) |
18:49:43 | FromDiscord | <martinium> just noticed something |
18:49:52 | FromDiscord | <martinium> its complaining about a function called before it |
18:51:37 | FromDiscord | <martinium> jeez found the error |
18:52:13 | FromDiscord | <martinium> iterator variable matched name of a returned table's key |
18:54:59 | FromDiscord | <martinium> actually error still there argh |
18:55:23 | Yardanico | we can't help if you only complain :P |
18:55:51 | FromDiscord | <martinium> sent a long message, see http://ix.io/2v7T |
18:56:00 | * | FromDiscord quit (Remote host closed the connection) |
18:56:16 | * | FromDiscord joined #nim |
18:56:19 | FromDiscord | <martinium> line 49 is teh one that begins with sitesMap |
18:57:03 | Yardanico | how is sitesMap defined? |
18:57:15 | FromDiscord | <martinium> > sitesMap = newTable[int, string]() |
18:57:21 | FromDiscord | <martinium> using var keyword |
18:57:47 | Yardanico | and on what line it fails in that code snippet? |
18:57:59 | FromDiscord | <martinium> sitesMap[item["id"].getInt()] = item["name"].getStr() |
18:58:25 | kinkinkijkin | trying to figure out how to pass glesHandle.symAddr() as a proc, the compiler considers that a LibHandle for some reason, the GLAD automated gl loader requires a proc to load symbols from the gles library to be passed to it... |
18:59:17 | kinkinkijkin | try to wrap it in another proc and i can't get it to accept the return value of symAddr |
18:59:24 | Yardanico | kinkinkijkin: you need to cast it to a proc tpye |
18:59:25 | Yardanico | type* |
18:59:36 | Yardanico | @martinium so try doing "echo item" before that line? |
18:59:48 | Yardanico | to see if stuff actually exists |
19:00:09 | kinkinkijkin | just a cast? easier than i thought then |
19:00:34 | Yardanico | kinkinkijkin: yeah, if what you get is a function pointer, you can "cast" it to a proc |
19:01:06 | FromDiscord | <martinium> that's part of diff function where I get all the IDs I need of type int into a seq called idList |
19:01:12 | kinkinkijkin | oh no, I need to pass the proc itself |
19:01:17 | kinkinkijkin | it does that casting on its end |
19:01:29 | Yardanico | pass it where? |
19:02:08 | kinkinkijkin | "assert gladLoadGLES2([here])" |
19:02:17 | Yardanico | you just pass the proc as it is |
19:02:34 | kinkinkijkin | yes, but then it doesn't find the loaded GLES2 library since it doesn't have the handle |
19:02:45 | kinkinkijkin | the loader just sets the functions |
19:04:02 | kinkinkijkin | https://dpaste.org/UjP0 loader code generated by GLAD, and glesHandle.symAddr in the spot of load doesn't compile |
19:04:14 | Yardanico | "load: proc" nonono |
19:04:30 | Yardanico | you need to specify the exact proc type |
19:04:42 | Yardanico | "proc" might work, but might not |
19:04:59 | Yardanico | kinkinkijkin: oh, maybe you misunderstood |
19:05:04 | kinkinkijkin | it's auto-generated code from a code generator with alpha nim support |
19:05:04 | Yardanico | glesHandle.symAddr returns a pointer |
19:05:08 | Yardanico | which you need to cast to a proc type |
19:05:16 | Yardanico | so you can call it |
19:06:11 | kinkinkijkin | yes, but again, the loader runs the given proc itself to load the library, and there is no built-in loader for nim in the generated code |
19:06:32 | Yardanico | I don't think I understand, sorry :) |
19:06:42 | kinkinkijkin | it needs to run symAddr, not the result of symAddr |
19:07:32 | kinkinkijkin | GLAD generates a complete loader in C, C++, and Volt, but not for Nim, as Nim support in GLAD is experimental right now |
19:07:59 | kinkinkijkin | this loader you have to pass your own loader, all it does is run it against all the things it has to |
19:08:21 | kinkinkijkin | would you like the full GLAD-generated .nim file I'm compiling against? |
19:10:59 | disruptek | new bot feature lets you scan for package usage: |
19:11:02 | disruptek | !requires irc |
19:11:04 | disbot | irc: 11Yardanico[witchrelay,3ircord,3nimeventer], 11Xe[3nagios,3hbot], 11nim-lang[3nimbot,3irc], 11cderwin/3ircc, 11blandcr/3coriolis, 11disruptek/3xs, 11smt923/3tinytwitch, 11moon-chilled/3Goodbot, 11Heartmender/3sobot, 11mateodif/3irc_nim, 11GoogleBot42/3NimBot 715 total |
19:11:21 | Yardanico | !requires dimscord |
19:11:21 | disbot | dimscord: 11ire4ever1190[occat,3disjoke], 11Yardanico/3ircord, 11broad-well/3dimscommander, 11snus-kin/3hemulen, 11krisppurg/3dimscord 76 total |
19:11:28 | kinkinkijkin | https://dpaste.org/7HdW in case you're curious |
19:11:33 | Yardanico | disruptek: cool, how? |
19:11:38 | Yardanico | nimble.directory ? |
19:11:45 | disruptek | pure magic. |
19:11:57 | disruptek | !requires shene |
19:11:58 | disbot | shene: 70 total |
19:12:04 | disruptek | !requires interfaced |
19:12:04 | disbot | interfaced: 70 total |
19:12:18 | disruptek | so apparently, no one but dom96 cares about runtime interfaces. |
19:12:57 | Yardanico | kinkinkijkin: okay, and what do I call to test it? |
19:13:18 | kinkinkijkin | gladLoadGLES2 is the loader, it's at the bottom of the file |
19:13:28 | Yardanico | I mean to test :) |
19:14:05 | kinkinkijkin | oh, just glEnable(GL_DEPTH_TEST) or something similar, if loading failed that'll crash |
19:14:28 | * | awe002 joined #nim |
19:14:50 | Yardanico | but wait, that way it won't work because load_GL_ES_VERSION_2_0 isn't called? |
19:15:09 | FromDiscord | <dom96> disruptek: people care about interfaces when they're first class citizens in the language/stdlib |
19:15:11 | Yardanico | I see gladLoadGLES2, but as you said it needs a loader proc, so I'm asking which one :P |
19:15:17 | disruptek | dom96: who? |
19:15:17 | kinkinkijkin | ooooh |
19:15:23 | kinkinkijkin | there's no loader proc included |
19:15:35 | FromDiscord | <dom96> otherwise Go's interfaces wouldn't be as popular |
19:15:39 | kinkinkijkin | and all the loader proc does in this case is load symbols |
19:15:39 | FromDiscord | <dom96> !requires jester |
19:15:41 | disbot | jester: 11emekoi/oker, 11alextanhongpin/3nim-jester, 11Rakesh243/3loginform-nim, 11iris-contrib/3third-party-benchmarks, 11NabeKz/3nim-buildpack, 11dalinim/3dalim, 11zurs/3url-shortener, 11Tangdongle/3TangBlog, 11vic/3nim-heroku-example, 11nim-lang/3Nim, 11itsumura-h/3Nim, 11the-benchmarker/3web-frameworks, 11MagnificentPako/3RoyalNim, 11sharkguto/3teste_carga, 11dsrw/3en |
19:15:57 | Yardanico | well honestly, I've seen that interface{} in Go is sometimes horribly abused |
19:16:00 | FromDiscord | <dom96> Nim requires Jester? lol |
19:16:06 | Yardanico | people use it as "void*" in C |
19:16:08 | FromDiscord | <martinium> is there a way to cast a jsonNode to a JObject? |
19:16:08 | Yardanico | sometimes |
19:16:11 | FromDiscord | <haxscramper> Is it possible to dereference pointer to variable without copying? Or just some to convert `var T` to `ptr T` and then back again and don't create any new objects in the process. I want to make similar to C++'s capture by reference in order to work with C library that heavily relies on callbacks |
19:16:14 | * | awe001 quit (Ping timeout: 258 seconds) |
19:16:15 | Yardanico | @martinium there's no need to "cast" |
19:16:23 | Yardanico | JsonNode itself might be of kind JObject |
19:16:31 | Yardanico | if it's not - then that's the problem of the original jsonm |
19:16:32 | Yardanico | *json |
19:16:42 | Yardanico | so did you get it to output, and if so, what's the output of "echo item"? |
19:17:06 | FromDiscord | <haxscramper> Ideally it would be just some annotation on `var obj = p[]` that makes `obj` and `p` still point to the same memory |
19:17:07 | Yardanico | @haxscramper would https://nim-lang.org/docs/decls.html#byaddr.t%2C%2C%2C work for you? |
19:17:12 | FromDiscord | <martinium> that function works fine |
19:17:29 | FromDiscord | <martinium> seems to be the assertion of jsonNode and JObject per the error |
19:17:41 | Yardanico | yes, this means that the JsonNode you're trying to access as a map isn't one |
19:17:47 | Yardanico | JObject is a kind used for key: value json objects |
19:18:03 | Yardanico | echo the json node before the line where the assertion happens |
19:18:08 | FromDiscord | <martinium> JObject is {} in json no? |
19:18:13 | FromDiscord | <martinium> json Objects |
19:18:24 | Yardanico | {"a": {"b": 3}} |
19:18:30 | Yardanico | {"a": {"b": 3}} and {"b": 3} here are both JObject |
19:19:21 | Yardanico | also, are you using --gc:arc on devel or not? just so it's not an arc issue :) |
19:19:32 | FromDiscord | <martinium> am not |
19:19:40 | FromDiscord | <martinium> doubt its a GC issue |
19:19:43 | FromDiscord | <martinium> but lets try it |
19:19:46 | Yardanico | nonono |
19:19:53 | Yardanico | if it's not arc, don't try right now :) |
19:19:59 | FromDiscord | <martinium> π |
19:20:12 | Yardanico | but yeah, as I said, if that assertion happens - you're trying to use something as a map (JObject is essentially a map) when it's not |
19:20:24 | FromDiscord | <martinium> so data["resources"] is an array that contains json objects |
19:20:40 | FromDiscord | <martinium> some of these objects have a key named "scanName" and some do not |
19:20:53 | FromDiscord | <martinium> If I don't try to filter I get all the output no problem |
19:21:04 | Yardanico | wait |
19:21:05 | kinkinkijkin | Yardanico, basically im trying to figure out how to make the loader proc that the GLAD generated code wants |
19:21:13 | FromDiscord | <martinium> but I am trying to use the conditional to only output the objects that have that key |
19:21:23 | kinkinkijkin | im testing glesHandle.symAddr but that's not compiling |
19:21:23 | Yardanico | yes, but maybe some objects which don't have that key are not maps at all? |
19:21:34 | FromDiscord | <martinium> that's the thing |
19:21:38 | FromDiscord | <martinium> am not using the map at all |
19:21:42 | Yardanico | JObject is a map |
19:21:45 | Yardanico | that's what I meant |
19:21:47 | FromDiscord | <martinium> I am calling a seq called idList |
19:21:59 | Yardanico | try changing |
19:22:00 | Yardanico | if scan.hasKey("scanName") == false: |
19:22:00 | Yardanico | to |
19:22:19 | Yardanico | if scan.kind != JObject or scan.hasKey("scanName") == false: |
19:23:38 | Yardanico | kinkinkijkin: well I'm not really accustomed with OpenGL and stuff so if you have time, please make kinda self-sufficient code to reproduce the error you're having :) |
19:23:42 | FromDiscord | <martinium> still fails |
19:23:47 | disruptek | dom96: i think it's stupid that nim requires jester, too. |
19:23:58 | FromDiscord | <martinium> sent a long message, see http://ix.io/2v81 |
19:24:16 | Yardanico | what's on line 59 ? |
19:24:34 | FromDiscord | <martinium> elif "Internal" in scan["scanName"] == true: |
19:24:58 | FromDiscord | <dom96> disruptek: how does it though? What is the Nimble file there? |
19:25:21 | Yardanico | @martinium well I honestly can't help like that, do you might sharing the code or not? or at least the JSON data |
19:25:29 | disruptek | dom96: Tweeter.nimble |
19:25:30 | FromDiscord | <martinium> yeah 1 sec |
19:25:35 | FromDiscord | <haxscramper> Yes, `{.byaddr.}` works just as expected. And another question - it is possible to cut off access to all variables not defined in current scope? |
19:25:50 | Yardanico | wdym? |
19:25:55 | Yardanico | I don't think you should worry about that in callbacks |
19:26:10 | FromDiscord | <dom96> disruptek: ahh. Nice. I like that it finds these |
19:26:12 | FromDiscord | <haxscramper> I'm interfacing with C and I had to explicitly capture all variables |
19:26:24 | disruptek | dom96: yeah, it should be useful. |
19:26:37 | FromDiscord | <haxscramper> In order to pass pointers to variables via ` void* client_data` |
19:26:41 | Yardanico | let's check how disruptek handled this edge-case |
19:27:03 | Yardanico | !requires treesitter |
19:27:03 | disbot | treesitter: 11genotrance[imtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter,3nimtreesitter] 720 total |
19:27:06 | Yardanico | :P |
19:27:27 | FromDiscord | <dom96> So here is a query that the new NimForum uses: https://gist.github.com/dom96/4c73f7a2a341b2710ce6bf7d31d27bdf. Any SQL experts know why it would hang? (it doesn't hang if I remove `c.id = 0`) |
19:27:37 | FromDiscord | <dom96> er wait |
19:27:40 | FromDiscord | <dom96> why's it `==` |
19:28:04 | FromDiscord | <dom96> oh nvm, it still hangs with `=` |
19:28:28 | kinkinkijkin | https://dpaste.org/T41p yadarnico if the loader worked, you will get "true" followed by the application not crashing. |
19:28:46 | disruptek | Yardanico: what do you think it should say? |
19:29:16 | kinkinkijkin | GLAD is not a nimble library btw, in this specific implementation you have to have the GLAD-generated gl.nim in a subdirectory called "GLAD" |
19:29:19 | FromDiscord | <haxscramper> Oh, nvm `{.cdecl.}` callback already gives adequate error message about captures, sorry |
19:30:37 | FromDiscord | <martinium> how can you quote text here in discord? |
19:30:53 | Yardanico | triple single quote code triple single quote |
19:30:59 | FromDiscord | <martinium> thanks |
19:31:06 | FromDiscord | <martinium> sent a long message, see http://ix.io/2v83 |
19:31:37 | Yardanico | kinkinkijkin: and what's the signature for a loader supposed to be? |
19:31:46 | FromDiscord | <martinium> (edit) 'http://ix.io/2v83' => 'http://ix.io/2v84' |
19:32:05 | FromDiscord | <martinium> sent a long message, see http://ix.io/2v85 |
19:32:05 | Yardanico | @martinium well stuff looks fine there |
19:32:11 | kinkinkijkin | it has to be the symbol loader |
19:32:14 | FromDiscord | <martinium> see the scanName key |
19:32:21 | FromDiscord | <martinium> sometimes it doesn't exist |
19:32:38 | kinkinkijkin | https://glad.dav1d.de/ this is the website used to generate the glad/gl.nim file |
19:32:39 | FromDiscord | <martinium> I was trying to implement a check with hasKey() |
19:32:41 | Yardanico | kinkinkijkin: I mean what's the signature for it in C for example ? |
19:33:04 | kinkinkijkin | oh sec, there's good documentation for c which doesn't work in nim for reasons unknown |
19:33:57 | kinkinkijkin | https://github.com/Dav1dde/glad readme has some documentation on how this us usually run in c |
19:33:57 | Yardanico | oh found it |
19:33:58 | Yardanico | typedef void* (* GLADloadproc)(const char *name); |
19:34:27 | * | Guest41431 quit (Remote host closed the connection) |
19:35:16 | kinkinkijkin | my issue is that I don't know enough plain C to translate C memory shenanigans into nim |
19:35:20 | kinkinkijkin | in this case |
19:35:22 | FromDiscord | <dom96> argh, the legacy db design strikes again |
19:35:30 | * | superbia quit (Quit: WeeChat 2.9) |
19:35:36 | * | snowolf joined #nim |
19:35:52 | FromDiscord | <dom96> silly not to put the author of a thread in the thread table... |
19:36:07 | Yardanico | kinkinkijkin: I think I almost figured it out |
19:37:03 | kinkinkijkin | I'll be grateful even if you get close and just dump the close code on me |
19:37:39 | kinkinkijkin | cause right now I'm stuck, never done much with others' libraries |
19:38:19 | disruptek | dom96: normalization at its finest. |
19:38:27 | disruptek | !requires treesitter |
19:38:27 | Yardanico | kinkinkijkin: https://play.nim-lang.org/#ix=2v8a |
19:38:28 | disbot | treesitter: 11genotrance/imtreesitter 71 total |
19:38:33 | disruptek | i guess this is what you want. |
19:38:38 | Yardanico | it currently fails on " var glVersion = cast[cstring](glGetString(GL_VERSION))" |
19:38:43 | Yardanico | actually on the next one, but yeah |
19:38:45 | Yardanico | I'll check why |
19:38:51 | Yardanico | it loads glGetString successfully |
19:40:36 | FromDiscord | <martinium> I FIXED IT |
19:40:46 | FromDiscord | <martinium> dude |
19:40:58 | FromDiscord | <martinium> was missing .getStr() |
19:41:05 | FromDiscord | <martinium> on scan["scanName"] |
19:41:10 | FromDiscord | <martinium> π |
19:41:18 | FromDiscord | <martinium> (edit) 'π' => 'π' |
19:41:40 | FromDiscord | <martinium> (edit) 'π ... ' => 'ππ€£' |
19:42:10 | FromDiscord | <dom96> Yay, fixed the SQL |
19:44:35 | * | Prestige quit (Ping timeout: 272 seconds) |
19:45:15 | * | Prestige joined #nim |
19:45:24 | FromDiscord | <martinium> I started a trenf |
19:45:29 | FromDiscord | <martinium> (edit) 'trenf' => 'trend' |
19:47:49 | FromDiscord | <martinium> what was the fix for the sql btw? |
19:47:55 | Yardanico | kinkinkijkin: I think there's another problem |
19:47:57 | FromDiscord | <martinium> curious |
19:47:59 | Yardanico | https://stackoverflow.com/questions/6288759/why-could-glgetstringgl-version-be-causing-a-seg-fault |
19:48:04 | Yardanico | "I doubt you can call even something as simple as glGetString without an OpenGL context." |
19:48:37 | kinkinkijkin | yes |
19:48:46 | kinkinkijkin | that is correct |
19:48:59 | kinkinkijkin | oh crap i just realized the implication to that |
19:49:21 | FromDiscord | <martinium> what does the danger compiler flag do? |
19:49:31 | Yardanico | everything what -d:release does + disabling ALL runtime checks |
19:49:35 | FromDiscord | <martinium> does it make a release program even faster? How? |
19:49:38 | Yardanico | it's what -d:release did before 0.20 release :) |
19:49:41 | Yardanico | by disabling all runtime checks |
19:50:04 | Yardanico | overflow, range, float range, asserts, etc |
19:50:14 | Yardanico | ah asserts are disabled with -d:release too I think |
19:50:30 | Yardanico | anyway release - https://github.com/nim-lang/Nim/blob/devel/config/nim.cfg#L72 |
19:50:34 | Yardanico | only danger - https://github.com/nim-lang/Nim/blob/devel/config/nim.cfg#L55 |
19:50:46 | Yardanico | yeah -d:release still has asserts working, -d:danger disables them |
19:51:23 | FromDiscord | <dom96> One step closer to deploying the new forum https://github.com/nim-lang/nimforum/commit/e62ae672b30de239830526ce032f1a1f10427387 |
19:51:23 | FromDiscord | <martinium> so without the asserts can be faster if you are 1000% your code is correct |
19:51:41 | Yardanico | yeah, -d:danger is what you should use when you're 100% sure the code is correct :0 |
19:51:50 | Yardanico | but even then for a lot of cases it's better not to use it |
19:51:55 | Yardanico | unless you really want the MOST performance |
19:52:11 | FromDiscord | <martinium> so for benchmarking |
19:52:12 | FromDiscord | <martinium> lol |
19:59:10 | FromDiscord | <martinium> @dom96 https://media.discordapp.net/attachments/371759389889003532/747545554094915704/unknown.png |
19:59:29 | FromDiscord | <martinium> dark mode search box needs to get correct coloring |
19:59:36 | Yardanico | ? |
19:59:37 | FromDiscord | <martinium> you prob already know this |
19:59:44 | Yardanico | check how it looks on devel |
19:59:49 | FromDiscord | <dom96> didn't someone already tell you that this was fixed on devel? |
19:59:52 | Yardanico | I did |
19:59:56 | FromDiscord | <martinium> ah did they |
20:00:01 | FromDiscord | <martinium> thought you meant continue keyword |
20:00:01 | Yardanico | yes :P |
20:00:04 | Yardanico | you ignored it :D |
20:00:04 | Yardanico | http://nim-lang.github.io/Nim/manual.html |
20:00:06 | Yardanico | check how it looks there |
20:00:08 | FromDiscord | <martinium> π€£ |
20:00:33 | FromDiscord | <martinium> ah yeah its sexy/fixed in devel |
20:00:44 | FromDiscord | <martinium> nice |
20:09:22 | FromDiscord | <dom96> To this day I love the NimForum CI https://travis-ci.org/github/nim-lang/nimforum/builds/720776030 |
20:09:29 | * | leorize joined #nim |
20:11:35 | leorize | shashlick: it's in a PR but not merged yet |
20:11:54 | FromDiscord | <dom96> Sooo, get ready for me to update the forum |
20:11:59 | FromDiscord | <dom96> first time in two years |
20:12:00 | FromDiscord | <dom96> what can go wrong |
20:12:48 | leorize | database migration failed :) |
20:14:10 | shashlick | @leorize who is it waiting on |
20:14:30 | leorize | no idea, ask Araq and/or narimiran |
20:16:44 | FromGitter | <ynfle> How do I rebuild the compiler and run tests? |
20:17:50 | disruptek | ./koch boot; ./koch tests |
20:18:04 | disruptek | ./koch temp is generally the wiser option. |
20:18:20 | FromGitter | <ynfle> Why? |
20:18:20 | disruptek | but then you get to mess with testing bin/nim_temp. |
20:18:39 | disruptek | it just depends on how extensive your changes are... |
20:18:52 | FromGitter | <ynfle> Fixing json encoding for tuples |
20:19:08 | disruptek | why would you need to rebuild the compiler for that? |
20:19:20 | Yardanico | @ynfle stdlib isn't in the compiler |
20:19:25 | Yardanico | it's not "built into the compiler" |
20:19:37 | Yardanico | if you modify the stdlib modules, you don't need to recompile the compiler |
20:19:39 | Yardanico | you can just check :P |
20:19:42 | Yardanico | straight away |
20:21:14 | FromGitter | <ynfle> I don't understand? When the test `import json` I should just use `import ../../lib/pure/json`? |
20:21:32 | FromGitter | <ynfle> ie. it uses my nim installation's json.nim |
20:23:44 | * | lritter quit (Quit: Leaving) |
20:26:25 | * | narimiran quit (Ping timeout: 240 seconds) |
20:29:07 | * | quetzalb joined #nim |
20:30:28 | FromGitter | <ynfle> Ie. It fails on the CI and I want to do more investigation without having to push to my fork ever time |
20:31:13 | leorize | just modify it in the source tree, then run `./koch tests` |
20:31:32 | leorize | now if you know exactly which test fail, test it with: `./koch tests r <category>/<test>` |
20:32:15 | * | awe003 joined #nim |
20:32:23 | * | arecacea1 quit (Remote host closed the connection) |
20:33:15 | * | arecacea1 joined #nim |
20:33:40 | * | awe002 quit (Ping timeout: 258 seconds) |
20:40:04 | * | abm joined #nim |
20:41:54 | FromGitter | <ynfle> So `/tjson`? |
20:42:05 | FromGitter | <ynfle> stdlib/tjson? |
20:44:26 | ForumUpdaterBot | New thread by Dom96: Nimforum 2.1.0 is here, see https://forum.nim-lang.org/t/6725 |
20:44:46 | FromDiscord | <dom96> ^^^ |
20:49:53 | Yardanico | FINALLLLLLLLLYYYYYYYYYYYYYYY |
20:52:36 | FromDiscord | <Hearthstone> What's up? |
20:52:45 | FromDiscord | <Hearthstone> What did you do?- |
20:54:22 | FromDiscord | <dom96> Deployed new Nimforum with support for categories |
20:54:56 | FromDiscord | <Hearthstone> Nice |
20:57:06 | * | bung joined #nim |
21:00:05 | Yardanico | @dom96 now create a new thread to discuss which categories we should add :P |
21:00:10 | Yardanico | from the top of my head - Off-topic, Bug Reports |
21:03:15 | leorize | Installation seems to be a category that would be useful :P |
21:03:35 | leorize | and a section for Documentations please |
21:03:38 | Yardanico | or give me moderation rights so I label all threads :P |
21:03:59 | Yardanico | well not all, but it certainly would help with discovering older stuff |
21:04:07 | Yardanico | 1 |
21:07:39 | leorize | bug report for the forum: the login form should hook on "submit" event |
21:10:33 | FromDiscord | <dom96> yeah, can't wait for the bikeshedding |
21:10:39 | bung | any recommanded lib implemented Geometry Class ? |
21:10:47 | FromDiscord | <dom96> where everyone wants categories and we end up with overlapping categories |
21:11:23 | Yardanico | but you know that nim forum's search isn't the best :( |
21:12:45 | FromGitter | <ynfle> What is this error? `Error: unknown trait: isNamedTuple` |
21:13:14 | FromDiscord | <Varriount> dom96: If bikeshedding generated power, I truly believe that the Nim issue tracker could power at least a couple of homes |
21:18:11 | FromDiscord | <Recruit_main707> @dom96 lovely the new style |
21:36:18 | FromDiscord | <dk> what's the name of the stdlib lib that gives you default values of fields if the object is nil etc? |
21:37:57 | * | thomasross joined #nim |
21:38:34 | FromDiscord | <Clyybber> wrapnils I think |
21:38:48 | FromDiscord | <Clyybber> @dk https://nim-lang.github.io/Nim/wrapnils |
21:39:11 | * | Kaivo joined #nim |
21:40:26 | FromDiscord | <dk> yes, thanks |
21:40:27 | disruptek | that category label is thicc. |
21:41:27 | Yardanico | now my https://forum.my-toolbox.xyz/ is finally (almost) obsolete :P |
21:41:38 | Yardanico | one thing which it has is the hacky OpenGraph support |
21:43:45 | disruptek | the wut |
21:44:59 | Yardanico | disruptek: the thing most services use to generate previews |
21:45:02 | Yardanico | for websites |
21:45:09 | Yardanico | https://ogp.me/ |
21:45:14 | Yardanico | it's just additional metadata in html |
21:47:28 | * | tane quit (Quit: Leaving) |
21:47:40 | disruptek | i'd settle for more metadata in html. i can't even fetch the fucking title to a forum thread. |
21:48:19 | disruptek | anyway, i don't mean to shit all over dom's work. |
21:48:31 | disruptek | i'm sure forum users are very happy to see improvements being made. |
21:48:46 | disruptek | i just have this stupid ticket from pmunch asking for this feature... |
21:48:54 | Yardanico | well yeah, server-side rendering might be very good, but I don't think that Karax has proper support for it |
21:48:58 | Yardanico | e.g. like JS frameworks do it |
21:49:11 | disruptek | which means absolutely no sense, since, y'know, it's all nim anyway. |
21:49:15 | disruptek | s/means/makes/ |
21:49:24 | Yardanico | they render the "initial" version (they also call this "hydration") on the server |
21:49:34 | Yardanico | and then do state changes with JS in the browser |
21:49:39 | FromDiscord | <dom96> yeah, not my department |
21:49:47 | FromDiscord | <dom96> I just used what was there |
21:50:03 | FromDiscord | <dom96> The priority was shipping a product |
21:50:26 | disruptek | weird. |
21:54:26 | kinkinkijkin | Yardanico, I got it working, just needed a context for it |
21:54:46 | Yardanico | nice |
22:01:25 | * | awe003 quit (Ping timeout: 240 seconds) |
22:02:11 | FromDiscord | <Clyybber> hmm, so shadowscopes are working fine now |
22:02:20 | FromDiscord | <Clyybber> only a small problem |
22:02:25 | disruptek | oh? |
22:03:04 | FromDiscord | <Clyybber> declaredInScope returns "wrong" results |
22:03:16 | disruptek | it so rarely works for me anyway. |
22:03:25 | FromDiscord | <Clyybber> chronos breaks because of that |
22:03:52 | FromDiscord | <Clyybber> I think we should be relatively pessimistic and say "yeah its declared in scope" |
22:04:01 | FromDiscord | <Clyybber> oh actually |
22:04:06 | FromDiscord | <Clyybber> that makes perfect sense |
22:04:08 | FromDiscord | <Clyybber> and isn't even wrong |
22:04:09 | FromDiscord | <Clyybber> :D |
22:16:51 | * | awe003 joined #nim |
22:32:31 | disruptek | added some styling to testes. |
22:32:35 | disruptek | !repo testes |
22:32:37 | disbot | https://github.com/disruptek/testes -- 9testes: 11a small unittest framework with decent support π΄π‘π’ 15 6β 0π΄ 7& 29 more... |
22:32:51 | disruptek | much easier to read stack traces now. |
22:35:17 | disruptek | clyybber: so this fix also might fix declaredInScope? |
22:35:25 | disruptek | because that would be awesome. |
22:43:14 | FromDiscord | <Clyybber> whats there to fix? |
22:43:47 | shashlick | What a name |
22:44:04 | disruptek | are you telling me chronos was already failing tests? |
22:44:40 | disruptek | it's the package with three balls, shashlick. |
22:45:30 | FromDiscord | <Clyybber> disruptek whats there to fix |
22:45:45 | FromDiscord | <Clyybber> aside from the regression from my pr |
22:45:51 | disruptek | i dunno, it's rare that declaredInScope works for me. |
22:45:52 | disruptek | maybe it's me. |
22:46:21 | disruptek | i need to build a better code search tool. |
22:46:39 | FromDiscord | <Clyybber> disruptek wdym rare, gimme a snippet |
22:46:44 | disruptek | maybe that's really what ndoc should be. |
22:46:52 | FromDiscord | <Clyybber> if i d0nt know whats broken |
22:46:59 | FromDiscord | <Clyybber> i can't know what to fix |
22:47:08 | disruptek | i will file a bug next time. |
22:47:17 | disruptek | i don't usually bother; i just work around stuff. |
22:47:46 | FromDiscord | <Clyybber> what do you think declaredInScope does? |
22:48:03 | FromDiscord | <Clyybber> mayhe you think of it as what declared does |
22:48:16 | disruptek | maybe. |
22:48:28 | disruptek | i think it works for my check in nimph.. for ConfigRef.nimbleSubs. |
22:48:49 | disruptek | do you want a bug report for my failing testes? |
22:48:55 | disruptek | inheritance codegen? |
22:48:58 | FromDiscord | <Clyybber> yeah |
22:49:02 | disruptek | damnit. |
22:49:06 | FromDiscord | <Clyybber> always bug report |
22:49:18 | FromDiscord | <Clyybber> we need more bugs |
22:49:20 | disruptek | well, what do you make of this one? |
22:49:27 | disruptek | !issue author:disruptek macro |
22:49:28 | disbot | https://github.com/nim-lang/Nim/issues/15160 -- 3exceptions codegen broken inside macros 7& 1 more... |
22:49:34 | FromDiscord | <Elegant Beef> *stale bot says no more bugs* π |
22:49:34 | shashlick | Don't you call it pool then |
22:50:02 | FromDiscord | <Clyybber> hqven't l9oked at it yet |
23:00:31 | disruptek | who here knows something about food? |
23:00:56 | disruptek | i found some soup called "cream of bacon". it's expired but i'm pretty hungry. does it actually have cream in it? |
23:01:04 | disruptek | how do you get cream out of bacon, anyway? |
23:02:51 | FromDiscord | <Elegant Beef> Is it canned? |
23:02:56 | FromDiscord | <Elegant Beef> If so it's probably fine |
23:03:17 | FromDiscord | <Elegant Beef> Also i know reading is hard for you, but just read the ingredients |
23:03:24 | disruptek | yeah, how would i get uncanned soup out of a dumpster? |
23:03:34 | disruptek | i'm not a magician. |
23:03:48 | disruptek | it doesn't have all of the label. |
23:04:04 | disruptek | it does say something like whatsinmyfood.com |
23:04:37 | disruptek | ah, that's a real site. |
23:05:00 | disruptek | maybe it's not cream of bacon, though. no search results. |
23:06:13 | disruptek | i guess it does have cream in it. |
23:06:22 | disruptek | or, it did. |
23:06:34 | disruptek | well, whatever. i like cheese, too. |
23:07:01 | * | awe00 joined #nim |
23:08:55 | * | awe003 quit (Ping timeout: 258 seconds) |
23:11:52 | * | abm quit (Quit: Leaving) |
23:20:12 | * | krux02_ quit (Remote host closed the connection) |
23:21:57 | * | solitudesf quit (Ping timeout: 258 seconds) |
23:22:50 | * | ptdel joined #nim |
23:26:02 | disruptek | that was truly horrible. |
23:27:27 | * | vicfred quit (Quit: Leaving) |
23:33:11 | FromDiscord | <Elegant Beef> Going to be worse going out then in |
23:38:24 | FromDiscord | <martinium> My goodness βcream of baconβ? That sounds awful |
23:38:47 | FromDiscord | <martinium> Should name your next project cream of bacon lol |
23:39:14 | disruptek | i cannot recommend. |