<< 30-09-2024 >>

00:00:11*albe quit (Quit: The Lounge - https://thelounge.chat)
00:00:43FromDiscord<.bobbbob> In reply to @chronos.vitaqua "like transforming loops to": when you break from a loop you can return a value with it, so it treats the loop like an expression
00:01:24FromDiscord<Robyn [She/Her]> In reply to @.bobbbob "when you break from": ah, issue with that is that Nim has labels and you can break using labels
00:01:46FromDiscord<Robyn [She/Her]> Imo making a loop `yield`able makes more sense
00:02:17FromDiscord<.bobbbob> yeah it's not a big deal
00:03:10*albe joined #nim
00:29:33*lucasta quit (Remote host closed the connection)
00:52:06*beholders_eye quit (Ping timeout: 246 seconds)
01:27:51FromDiscord<Jennifer Hammitt> So what have you learnt so far concerning the Nim language and what advancement have you come across.↵(@nnsee)
01:49:09FromDiscord<aurelian5014> can I do `JsonNode.to(T)` if `T` is a generic param?
01:49:35FromDiscord<Elegantbeef> Yes
02:19:39FromDiscord<aurelian5014> sent a code paste, see https://play.nim-lang.org/#pasty=SwNPoSJz
02:19:53*lucasta joined #nim
03:31:04*lucasta quit (Remote host closed the connection)
03:32:26FromDiscord<bung8954> anyone use darwin library on arm64 ? seems nsstring related procedures not work on arm64 https://github.com/yglukhov/darwin/issues/24
08:03:46*PMunch joined #nim
08:42:49*jjido joined #nim
09:48:10*alexdaguy joined #nim
09:48:51FromDiscord<arm_3_d> Trying to compile for win32 (winxp) and getting `could not import: InitializeConditionVariable` passing `passC:"-D_WIN32_WINNT=0x0501"` doesn't help. `std/private/syslocks` does not support winxp?
10:11:58*om3ga joined #nim
10:21:04Amun-Rait's a prive proc
10:21:11Amun-Raprivate
10:26:03Amun-Rause initSysCond instead, it calls InitializeConditionVariable
10:26:24FromDiscord<arm_3_d> I started getting this errors when added Locks to codebase. I'm not importing `std/private/syslocks` , it is used by `std/locks` . It seems that nim's locks are not working in winxp. Not sure is it a bug or winxp is not supported officially anymore. ↵In `windows.h` that functions are defined only for Vista and up https://media.discordapp.net/attachments/371759389889003532/1290258437128851538/image.png?ex=66fbce4f&is=66fa7ccf&hm=4a83d41
10:29:41Amun-Rathat might be the issue - no such function defined in older os' dll
10:36:52Amun-Rahttps://learn.microsoft.com/en-us/windows/win32/api/synchapi/nf-synchapi-initializeconditionvariable
10:36:56Amun-Rayes, Vista and up
10:38:49FromDiscord<arm_3_d> Now I remember that I used locks before and had no issues. So it might be third party library which is triggering conditional variable init by calling other api in std/locks.
10:56:03*beholders_eye joined #nim
11:00:22FromDiscord<arm_3_d> ok its not third party lib, simple channel `open()` calls `initSysCond` which is directly mapped to that function from kernel32 lib.
11:01:06*om3ga quit (Ping timeout: 246 seconds)
11:01:34*om3ga joined #nim
11:19:07FromDiscord<arm_3_d> sent a code paste, see https://play.nim-lang.org/#pasty=DzITrDAN
11:34:55FromDiscord<janakali> https://learn.microsoft.com/en-us/windows/win32/api/synchapi/nf-synchapi-initializeconditionvariable↵This function is only available in Vista and up.
11:40:56*alexdaguy quit (Quit: WeeChat 4.4.2)
11:58:30*ryuukk quit (Remote host closed the connection)
12:00:21*ryuukk joined #nim
12:04:23*jjido quit (Quit: My laptop has gone to sleep. ZZZzzz…)
12:13:33*jjido joined #nim
12:38:46FromDiscord<lui1187> sent a code paste, see https://play.nim-lang.org/#pasty=fpjqFScq
12:39:03FromDiscord<lui1187> (edit) "https://play.nim-lang.org/#pasty=xnAhQiRe" => "https://play.nim-lang.org/#pasty=PkyYgcUc"
12:40:05FromDiscord<lui1187> template can't hook `=copy`
12:51:51FromDiscord<demotomohiro> It seems that proc only works with templates not procs: https://nim-lang.org/docs/system.html#instantiationInfo%2Cint↵> While similar to the caller info of other languages, it is determined at compile time.
12:53:47FromDiscord<lui1187> sent a code paste, see https://play.nim-lang.org/#pasty=lCFvcaEe
12:54:48FromDiscord<lui1187> (edit) "https://play.nim-lang.org/#pasty=GTqeyijU" => "https://play.nim-lang.org/#pasty=LrQeJhLy"
12:54:48FromDiscord<demotomohiro> sent a code paste, see https://play.nim-lang.org/#pasty=nDTOtLEd
12:55:07FromDiscord<lui1187> In reply to @demotomohiro "If you just want": no, i need log
12:55:37FromDiscord<lui1187> who and where make copies
12:56:12FromDiscord<odexine> --expandArc
12:56:15FromDiscord<odexine> https://nim-lang.github.io/Nim/mm.html
12:56:21FromDiscord<odexine> > Nim performs a fair share of optimizations for ARC/ORC; you can inspect what it did to your time critical function via --expandArc:functionName. Likewise, you can inspect the whole module via --expandArc:fileName.
13:14:54FromDiscord<lui1187> sent a code paste, see https://play.nim-lang.org/#pasty=MbeQXFDh
13:15:00FromDiscord<lui1187> (edit) "https://play.nim-lang.org/#pasty=wyJQFNqr" => "https://play.nim-lang.org/#pasty=CRKoNhOn"
13:16:07FromDiscord<lui1187> need filename and line in hooks overrides
13:20:04FromDiscord<odexine> `mm=none` does not execute `=copy`
13:20:29FromDiscord<demotomohiro> sent a code paste, see https://play.nim-lang.org/#pasty=blCODgWe
13:34:30FromDiscord<lui1187> sent a code paste, see https://play.nim-lang.org/#pasty=VJdCXyJF
13:36:15FromDiscord<lui1187> In reply to @demotomohiro "I tried to get": and needs with no StackTrace. 🙂 compile time only checks
13:38:43FromDiscord<lui1187> sent a code paste, see https://play.nim-lang.org/#pasty=FEffkoBx
13:40:00FromDiscord<demotomohiro> In reply to @lui1187 "hmm... and something strange": That is probably because `a` was moved to `b` and not copied as `a` is not read after assign.
13:40:04FromDiscord<demotomohiro> https://nim-lang.org/docs/destructors.html#move-semantics
13:41:20FromDiscord<lui1187> In reply to @demotomohiro "That is probably because": ye, i think this happens, need checks `=move`
13:53:07FromDiscord<lui1187> sent a code paste, see https://play.nim-lang.org/#pasty=WBdtLYuv
13:57:00*ryuukk quit (Remote host closed the connection)
13:59:39*ryuukk joined #nim
14:13:23*PMunch quit (Quit: Leaving)
14:17:52FromDiscord<demotomohiro> https://wandbox.org/permlink/Qk0BKX788gBQ5GZI↵`=wasMoved` was called with `a` not `b`.
14:24:26FromDiscord<lui1187> sent a code paste, see https://play.nim-lang.org/#pasty=RcJuVtET
14:25:36FromDiscord<lui1187> `echo` get copy or move in this case?
14:30:50FromDiscord<demotomohiro> https://wandbox.org/permlink/eMWfQfTaHZjufA6X
14:32:09FromDiscord<demotomohiro> Please read `--expandArc: test` in the compiler message.
14:32:21*lucasta joined #nim
14:58:31FromDiscord<lui1187> yep, understand, but main q is how hook `let b = a` ?
15:05:25FromDiscord<lui1187> and timestamp ↵ who and where - compiletime
15:14:35FromDiscord<lui1187> sent a code paste, see https://play.nim-lang.org/#pasty=AnJqmdKA
15:20:03FromDiscord<lui1187> sent a code paste, see https://play.nim-lang.org/#pasty=RVISuZGd
15:23:15FromDiscord<demotomohiro> sent a code paste, see https://play.nim-lang.org/#pasty=fsFNdDdL
15:25:36FromDiscord<demotomohiro> sent a code paste, see https://play.nim-lang.org/#pasty=eRMTGiLi
15:29:01FromDiscord<lui1187> thanks 🙂
15:29:02FromDiscord<demotomohiro> In most cases, when you initialize `y` after initializing `x`, you want to destroy `x` after destroying`y` as `y` can depends on `x`.
15:56:31FromDiscord<lui1187> sent a code paste, see https://play.nim-lang.org/#pasty=PyVTNgSO
16:22:16FromDiscord<arm_3_d> Why I can't register on nim-forum? Getting "Couldn't send email" error. Tried several mail addresses.
16:24:08Amun-Ra^ Phil
16:49:01*lucasta quit (Remote host closed the connection)
17:37:08*ntat joined #nim
18:01:19FromDiscord<lui1187> sent a code paste, see https://play.nim-lang.org/#pasty=cPXeJudK
18:01:34FromDiscord<lui1187> (edit) "https://play.nim-lang.org/#pasty=PWWlmxcf" => "https://play.nim-lang.org/#pasty=kUzXrmrf"
18:29:11*derpydoo joined #nim
19:21:54*derpydoo quit (Quit: derpydoo)
19:29:54*xet7 joined #nim
19:30:29*ntat quit (Quit: Leaving)
21:58:33FromDiscord<aurelian5014> how do I `.unwrap()` an option?
22:04:34Amun-Rahttps://nim-lang.org/docs/options.html#get%2COption%5BT%5D%2CT
22:51:07*oprypin_ quit (Quit: Bye)
22:51:17*oprypin joined #nim
23:00:02*marcus quit (Remote host closed the connection)
23:00:43*marcus joined #nim
23:07:34*jjido quit (Quit: My laptop has gone to sleep. ZZZzzz…)
23:30:07*Amun-Ra quit (Remote host closed the connection)