<< 04-07-2020 >>

00:00:59bung_https://github.com/nim-lang/needed-libraries
00:01:18*pietroppeter quit (Quit: Connection closed for inactivity)
00:01:55FromDiscord<𝓑𝓮𝓷𝓾𝓶𝓫𝓮𝓭> Thank you kindly bung
00:03:13bung_np,I looked it multiple times.
00:12:14shashlickhello @bung_
00:12:20shashlicksorry had to log off last night
00:12:28shashlickyou still stuck with that nimterop build stuff?
00:14:37bung_shashlick I give up yesterday
00:18:07*Lord_Nightmare quit (Quit: ZNC - http://znc.in)
00:19:35*Lord_Nightmare joined #nim
00:20:45*Zambyte[m] joined #nim
00:21:18shashlickYou're on osx right, which version
00:21:39shashlickI didn't see any clang version 11 released yet so was wondering
00:21:58bung_catalina 10.15.1 (19B88)
00:25:47shashlickAh OK
00:26:05shashlickI don't have a way to test that - only 13 at home and 14 on Travis
00:26:36shashlickDid you see the error message after git clone and nim c nimterop/toast
00:27:21bung_it get stucked, so I dont get any information, that's make it not easy to handle
00:29:06shashlickNothing prints to screen?
00:29:19shashlickNimble install does hide stuff, but Nim c should
00:29:25shashlickWeird
00:29:44bung_you mean using nim c to check?
00:31:21bung_oh not problem with it now
00:32:17bung_nimble build, nim c both work, dont know why not work yesterday
00:42:54shashlicki pushed v0.6.1 couple minutes ago - many changes but doubt anything would have impacted this
00:45:40bung_shashlick it's successfully installed, I reinstall it now.
00:46:05bung_before this, It installed but have no toast binary.
00:46:16shashlickokay no idea then - random failures
00:46:40*lritter quit (Ping timeout: 246 seconds)
00:47:07bung_shashlick nimterop not like nimgen will generate a nimble package automaticlly?
00:48:34shashlicknimgen would generate the wrappers at install time
00:48:54shashlicknimterop generates them at compile time
00:49:13shashlickthis is because i had many issues with nimble not copying the payload at install time
00:49:18shashlickbeforeInstall wasn't reliable
00:49:27shashlickbut now with nimterop, you can do it in many ways
00:49:42shashlickhttps://github.com/nimterop/nimterop#usage
00:50:16*krisppurg quit (Quit: Connection closed for inactivity)
00:52:08bung_I see the wrapper comment, can I avoid toast params specify to absolute path?
00:53:13shashlickright now i convert to absolute paths to ensure that the right headers get imported when recursing through #includes
00:53:26shashlickbut once the wrapper is done, you could change it to a relative path
00:53:32shashlickno good answer for that yet
01:01:34bung_dont know how to download git source automaticlly
01:05:47bung_`nim c -d:headerGit src/htm/quickjs.nim` not right?
01:06:24*oddp quit (Ping timeout: 256 seconds)
01:07:04shashlickquickjsGit
01:07:12shashlickheader is a placeholder
01:07:28shashlickhas to be same as the header = "" param in cImport()
01:07:52Yardanicojust for fun ran cloc on all packages in nimble (although it's not exactly current), but anyway, the result
01:07:53Yardanicohttps://gist.github.com/Yardanico/7c4538b458eebcf6e29f1d7bf0e12bba
01:08:02Yardanico6594771 lines of nim code (that's excluding comments and blank lines)
01:08:28Yardanicowonder where most of the cloc comes from
01:13:52bung_ok , error occurs during build https://pastebin.com/G0fBArG6
01:14:34shashlicklooks like quickjs is not compiling on your machine
01:15:40shashlickcan you git clone https://github.com/ldarren/quickjs and see if make works by itself?
01:17:59shashlickif it isn't compiling for you, need to report it to that repo
01:20:17shashlickworked fine on my mac
01:20:21shashlicktry `make libquickjs.a`
01:22:23bung_"mod branch contained mac fixes for undefined environ in ./quickjs-libc.c"
01:22:38bung_it documented this problem.
01:22:43shashlickneat
01:23:57shashlickamusingly it pulled mod branch for me since it is the default
01:25:50shashlicknimterop is pulling master by default if no branch specified - i need to fix that
01:26:10*vicfred joined #nim
01:29:10bung_it not follow the git uri ? append `#mod` not work
01:29:11*endragor quit (Read error: Connection reset by peer)
01:31:00*endragor joined #nim
01:33:20shashlickfor now, just go to the cache directory and git checkout mod and make
01:33:25shashlicki'll have to fix nimterop
01:35:21bung_ok
01:43:52*chemist69 quit (Ping timeout: 244 seconds)
01:44:27Yardanicoso guys uhh I'm a bit confused
01:44:31Yardanicowhy do we have a go library in nimble?
01:44:37Yardanicohttps://github.com/recoilme/pudge.git is in nimble :D
01:45:33Yardanicowell maybe it was rewritten in Go, idk
01:45:41Yardanicobut doesn't seem so
01:46:02*chemist69 joined #nim
01:46:20Yardanicogonna PR to packages to remove it
01:46:44Yardanico(found it by my pkgraph thing, I'm checking if there wasn't a nimble file found in package at all, and if so, I error and exit)
01:47:22FromDiscord<codic> it's in nimble?
01:47:25Yardanicoyes
01:47:30Yardanicohttps://github.com/nim-lang/packages/pull/431
01:47:31disbotpudge db verification
01:47:34Yardanicoseems like the author recreated the repo
01:47:36FromDiscord<codic> that's weird
01:47:38Yardanicoit was in nim at first it seems
01:47:49Yardanicobut then they removed all commits (or recreated the repo) and rewrote it in Go
01:47:53FromDiscord<codic> ah
01:47:58FromDiscord<codic> that's sad
01:48:20FromDiscord<codic> what happens if you install it then?
01:48:55Yardanicoit'll fail
01:49:04Yardanicotry "nimble install pudge"
01:50:59bung_no,it has no nim files in history
01:51:04bung_https://github.com/recoilme/pudge/commit/bfc88101a3ace6b6deedfb0fc57cb224f1a6baf4
01:51:07*endragor quit (Remote host closed the connection)
01:51:07Yardanicobung_: yes, as I said
01:51:13Yardanicothe author probably removed the nim repo
01:51:17Yardanicoand recreated a go repo with same name
01:51:20Yardanicoso there are no nim commits
01:52:49bung_the author also has no nim project.
01:52:58Yardanicowell, they seem to have been using nim in the past
01:55:30bung_that's weird ,create someting , then delete everything
01:55:39Yardanicohttps://github.com/nim-lang/packages/pull/1548
01:55:40disbotRemove pudge (it's a Go library now)
02:00:54shashlick@bung_ hope you are unblocked for now, will take a bit to fix this
02:13:34FromGitter<bung87> dont worry, it's low priority on my list
02:17:41FromDiscord<KingDarBoja> Lmao
02:20:31*lmariscal0 quit (Remote host closed the connection)
02:22:58*marnix joined #nim
02:31:24*marnix quit (Ping timeout: 256 seconds)
02:34:30*muffindrake quit (Ping timeout: 244 seconds)
02:36:38*muffindrake joined #nim
02:40:57*endragor joined #nim
02:45:19*endragor quit (Ping timeout: 246 seconds)
03:02:07*thomasross quit (Ping timeout: 246 seconds)
03:05:59*endragor joined #nim
03:09:56*tiorock joined #nim
03:09:56*tiorock quit (Changing host)
03:09:56*tiorock joined #nim
03:09:56*rockcavera is now known as Guest49950
03:09:56*Guest49950 quit (Killed (card.freenode.net (Nickname regained by services)))
03:09:56*tiorock is now known as rockcavera
03:18:39*endragor quit (Remote host closed the connection)
03:20:33*waleee-cl quit (Quit: Connection closed for inactivity)
03:27:16*endragor joined #nim
03:32:02*endragor quit (Ping timeout: 256 seconds)
03:43:48*sagax quit (Quit: Konversation terminated!)
03:45:17*chemist69 quit (Ping timeout: 244 seconds)
03:46:29*chemist69 joined #nim
03:48:41FromDiscord<JackFly26> is there a good way to remove a child from a nimnode at an index
03:49:00FromDiscord<JackFly26> or do i have to convert to a seq and back
03:51:15Yardanicohttps://nim-lang.org/docs/macros.html#del%2CNimNode%2Cint%2Cint
03:56:19FromDiscord<Technisha Circuit> Would ```nim↵type Command = object↵ nams:string↵ commandProc:proc(s:Shard, m:Message) {.async.}``` be valid code?
03:56:40Yardanicoon devel it is
03:56:43Yardanicosince async is a template
03:56:49FromDiscord<Technisha Circuit> Thanks!
03:56:58FromDiscord<Technisha Circuit> And yeah I'm using devel :P
03:57:28FromDiscord<juan_carlos> is possible to improve `when nimvm:` into more like other compile defines?, something like `when defined(nimvm):` would be awesome, I dunno the limitations of the vm.
04:06:01*supakeen quit (Quit: WeeChat 2.8)
04:06:41*supakeen joined #nim
04:29:02Yardanicoso guys, top 50 packages by how many other packages depend on them (in nimble):
04:29:28Yardanicohttps://gist.github.com/Yardanico/4eed919089764176df8f4f71c4435adf
04:42:31*audiophile joined #nim
04:44:15FromDiscord<Elegant Beef> You now make me realize i want a "Packages that depend on this" on nimble 😄
04:52:28leorizejuan_carlos: it's not possible, when nimvm is a kind of when statement
04:53:01leorizeactually read it like this: it's possible but the semantics are not compatible, which is why it's separate
04:53:54FromDiscord<juan_carlos> ok.
04:58:32shashlickwhat's faster github actions or azure pipelines
04:58:45leorizesame
04:59:02*fredrikhr joined #nim
04:59:07leorizegithub rent out azure's infra, and their runner software is a fork of azure's
04:59:25shashlickok which one offers more limits for free users
04:59:33leorizegithub
05:00:49*vr0n quit (Ping timeout: 264 seconds)
05:01:05shashlicki need faster turnaround on my nimterop test matrix but really not keen on investing time on CI stuff
05:04:16*solitudesf joined #nim
05:06:21leorizeyea then go for github
05:06:45leorizeyou can copy the setup I made for fusion as a start
05:07:02shashlickmaybe i'll setup a gitster matrix like my travister setup to run random tests
05:08:13Yardanicocontiuning on my pkgraph adventure
05:08:19Yardaniconow also parsing author/version/license
05:08:20Yardanicocreate (id1065:package {pkgname: 'nimwc', author: 'Thomas T. Jarløv (https://github.com/ThomasTJdev) & Juan Carlos (https://github.com/juancarlospaco)', license: 'PPL', version: '6.0.5'})
05:08:34Yardanico(that's neo4j's cypher statement)
05:14:51Yardanicohttps://i.imgur.com/a9qMr3x.png
05:28:19Yardanicohttps://i.imgur.com/hsNv4NQ.png :P
05:33:36*audiophile quit (Quit: Default Quit Message)
05:35:32*Romanson joined #nim
05:35:53*marnix_ joined #nim
05:42:03*hyiltiz_ joined #nim
05:43:17*hyiltiz_ quit (Changing host)
05:43:17*hyiltiz_ joined #nim
05:50:21FromDiscord<mattrb> sent a long message, see http://ix.io/2qPn
05:52:29FromDiscord<Varriount> @mattrb Have you used GDB or LLDB before?
05:54:29FromDiscord<mattrb> I used gdb while building a toy language a few months ago, but all I did at that point was step through asm and check regs :p Beyond that, I really have no clue how to use gdb at a deeper level :/
05:55:46*dzamo[m] left #nim ("User left")
05:56:05*dzamo[m] joined #nim
05:56:44FromDiscord<Varriount> @mattrb Hm, well if you compile your program with `--debugger:native` and omit any flags such `-d:release`, you should be able to run the program with GDB, and at least get a stack trace when it crashes.
05:57:02*marnix_ quit (Ping timeout: 244 seconds)
05:57:07FromDiscord<Varriount> I'd help, but I'm currently setting up my Nim environment (newly fixed computer).
05:59:55FromDiscord<Varriount> @mattrb How complex is a Gameboy emulator? I've heard it's a good way to get experience with emulation in general.
06:00:03leorizescoped mm got merged
06:00:19leorizeYardanico: benchmark please :)
06:00:24Yardanicolol
06:00:39Yardanicoin the end 4raq redone everything using the existing backend :P
06:00:46FromDiscord<Varriount> @leorize I recall seeing that PR... does it have any semantic impact on the language?
06:00:56Yardanicoit only matters for destructors
06:01:00Yardaniconow destructors will actually be scoped
06:01:14Yardanicoso if you create a string in a for loop, it'll be destroyed on each iteration, not after it
06:01:18Yardanicoor even "block: "
06:01:44leorizefor the language, it doesn't affect much
06:02:10leorizeI'm more interested in potential optimization gained via scoping variables properly :P
06:02:19FromDiscord<Varriount> Hm, on the one hand, that behavior is much more expected. On the other, it means careless string creation is even more of a performance hole
06:03:10FromDiscord<mattrb> @Varriount If you're familiar with hardware, I'd say an mvp would take a couple weeks in your free time. For me, the more interesting part is the cycle-accurate interaction between components, which tends to take a little longer. I also had to spend a fair bit of time wrapping my head around digital audio, which I had no experience with before
06:04:11*dddddd quit (Remote host closed the connection)
06:06:50FromDiscord<mattrb> sent a code paste, see https://play.nim-lang.org/#ix=2qPt
06:08:26leorizeVarriount: move optimizations are designed to help with that
06:09:43Yardanicomagic
06:09:43Yardanicohttps://i.imgur.com/Vm85sAd.png
06:09:53Yardanicoall packages which indirectly depend on dom's packages
06:09:58Yardanico(and also his other packages)
06:12:33FromDiscord<Varriount> @mattrb When you run the program normally, does it crash (no exception or stack trace) or does it emit an exception?
06:15:16FromDiscord<mattrb> Typically just segfaults with no message `[1] 110702 segmentation fault (core dumped) ./chip8 ~/Downloads/ch8/PONG`
06:15:30Yardanicoif you compile without -d:release or -d:danger there should be a stack trace
06:16:12FromDiscord<Varriount> (unless something has gone horribly wrong)
06:16:31FromDiscord<Varriount> Yardanico: do you know if GDB dumps stack traces from all threads by default?
06:16:38YardanicoI think it doesn't
06:16:42YardanicoI was talking about nim itself :P
06:18:31FromDiscord<mattrb> I'm just compiling with `nimble build`
06:21:30Yardanicowell that builds a release version
06:21:35Yardanicoah, no
06:21:48Yardanicotry with nim c -r yourfile
06:22:14*marnix joined #nim
06:23:36FromDiscord<mattrb> I've been trying for a few minutes now and I can't get it to crash when I compile with `nimble build --d:release`.....
06:23:46FromDiscord<mattrb> I'll try nim c -r though..
06:25:51Yardanico@dom96 https://i.imgur.com/36hez6l.png :P
06:26:07Yardanicoall your packages, and all packages depending on your packages (with their authors)
06:26:33FromDiscord<mattrb> sent a code paste, see https://play.nim-lang.org/#ix=2qPx
06:26:42Yardanicoreally strange
06:26:45Yardanicono nim stack trace
06:26:52Yardanicowhat's your version of nim?
06:27:21leorizecan I see the code?
06:27:23shashlick@leorize - remember you mentioned that a dll can load a proc from the main executable
06:27:32FromDiscord<Varriount> https://github.com/mattrberry/chip-8_nim/blob/master/src/chip8.nimhttps://github.com/mattrberry/chip-8_nim/blob/master/src/chip8.nim
06:27:37leorizeshashlick: yes
06:28:14FromDiscord<mattrb> sent a code paste, see https://play.nim-lang.org/#ix=2qPy
06:28:51*Vladar joined #nim
06:29:23FromDiscord<mattrb> https://github.com/mattrberry/chip-8_nim
06:30:26FromDiscord<mattrb> The stack trace above from gdb seems to point to this line, although that doesn't make sense.. https://github.com/mattrberry/chip-8_nim/blob/master/src/chip8.nim#L37
06:32:29shashlicki tried `symAddr(nil, "procName")` but it is nil
06:32:46shashlicki added {.exportc, dynlib.} to procName
06:33:21shashlickoh wait
06:34:20*pietroppeter joined #nim
06:34:36*Nilium left #nim (#nim)
06:35:30shashlick@leorize - nah - even using `loadLib()` to get current executable handle and using that in symAddr doesn't work
06:36:12leorizeyou have to use --passL:-Wl,--export-dynamic
06:36:22leorizeor else the executable symbols will not be exported
06:36:35shashlickah
06:36:41leorize(this is why no one ever wants to do this sort of thing on linux)
06:37:07shashlickdo I still need the exportc, dynlib
06:37:19leorizeyes
06:40:50FromDiscord<mattrb> I'm gonna get a bit of sleep for now. If anyone sees anything I might be doing wrong here or has any other ideas for debugging, please @ me. Greatly appreciated! 🙂
06:42:19FromDiscord<Varriount> @mattrb I'll try working it out.
06:44:25shashlickokay it works now but segfaulting elsewhere
06:44:50shashlicki tried --gc:none but still does - need to debug
06:45:50leorizeyou might want to add cdecl
06:51:04shashlickyep it is and it works but now failing when calling another proc from the dll
06:51:17shashlickso i called a proc in the dll which called a proc in the executable and that worked
06:51:41shashlickthen finally, i call another proc in the dll which refers to some globals and it crashes in gc
06:52:05leorizeeither use gc:arc/orc or use nimrtl
06:52:33shashlickarc/orc doesn't work yet for toast
06:53:03shashlickeven boehm crashes which is nifty
06:53:17leorizetry --stacktrace:off
06:53:21*marnix quit (Ping timeout: 244 seconds)
06:55:40shashlickhttp://ix.io/2qPC
06:55:58shashlick#4 = onSymbolOverrideFinal which is the proc in the dll
06:56:45shashlickhttps://github.com/nimterop/nimterop/blob/master/nimterop/plugin.nim#L21
06:57:57shashlicksame story with --stacktrace:off
07:10:35shashlick@leorize - I think it has to do with the `--export-dynamic`
07:10:47shashlickeven if i don't call the executable, if that flag is on, it crashes
07:15:31FromDiscord<Technisha Circuit> Is it possible to get a type that i made from a .so file in dynlib?
07:15:43FromDiscord<Technisha Circuit> The fields of the type are populated
07:15:56Yardanicotypes don't exist at runtime at all
07:15:57leorizeshashlick: ooooh I know why :P
07:16:01shashlickyou'd need to share the nim source
07:16:02FromDiscord<Technisha Circuit> And i know what fields the type have
07:16:05FromDiscord<Technisha Circuit> Oh okay
07:16:09Yardanicoyou just copy the definitioon then
07:16:11FromDiscord<Technisha Circuit> Hm
07:16:13shashlicklike a header file
07:16:16FromDiscord<Technisha Circuit> Oh?
07:16:22shashlick@leorize - do tell!
07:16:44shashlicki think it is related to cOverrides being a global
07:17:07shashlickbut amusingly it doesn't fail in the normal case
07:17:44*ForumUpdaterBot quit (Remote host closed the connection)
07:17:51*ForumUpdaterBot joined #nim
07:20:33leorizeshashlick: do you use nimrtl?
07:20:39shashlickno
07:20:46shashlicki use markAndSweep
07:21:00shashlickthat's the only gc that allows these dll shenanigans
07:21:06leorizeswitch to boehm, you can't pass memory around without nimrtl if you use built in gc
07:21:13shashlickof course, i didn't use boehm
07:21:19shashlickbut it crashes the same way with boehm as well
07:21:24shashlickthat's the first thing i tried
07:21:31shashlickboth exe and dll are compiled with boehm
07:21:31leorizecompiles your dlls with -d:noSignalHandler
07:22:58leorizeif you're not using nimrtl that ruled out certain issues
07:23:27leorize--export-dynamic can cause NimMain of loaded DLLs to be overwritten with the main executable
07:23:49leorizeI encountered this with Haiku, where every binary is also a shared library (kinda implies --export-dynamic)
07:24:28leorizeyou might need to use --passL:-Bsymbolic to pre-bound symbols
07:24:33shashlick-d:noSignalHandler didn't help - with markAndSweep nor boehm
07:25:00leorizeat this point you should use boehm tbh
07:25:08leorizehave you reported the issue with arc?
07:26:59*Trustable joined #nim
07:27:13shashlickI had mentioned earlier
07:27:39shashlickhttp://ix.io/2qPH
07:28:02shashlicksimply change markAndSweep to arc or orc in toast.nims and run nimble test
07:28:39Yardanicoi guess time to re-test some packages after the scope PR :P
07:28:46shashlickhttps://github.com/nim-lang/Nim/issues/14074 is also still open
07:28:48disbot--gc:arc does not retain global HashSet in --app:lib ; snippet at 12https://play.nim-lang.org/#ix=2j7k
07:28:55leorizeit's fixed
07:29:08leorizeAraq forgot to close it I think
07:29:10shashlickokay
07:29:12leorizeshould double check
07:29:53Yardanicotime to check my arc issues too to see if they're fixed after the scope pr
07:30:10*Vladar quit (Quit: Leaving)
07:30:17Araqprobably not, I reverted to the old implementation
07:30:23Yardanicowell yeah I saw that :D
07:30:37leorizedoes that one still fix a bunch of weave issues?
07:30:38Araqbut at least now I can focus on bugs once again
07:30:57shashlickBsymbolic didn't help either
07:31:22leorizeI'm gonna try building it myself them
07:31:27leorizehow to reproduce?
07:31:45leorizethen*
07:31:55Yardanicoat least https://github.com/nim-lang/Nim/issues/14383 seems to be fixed now
07:31:57disbot[ARC] Internal compiler error when calling an iterator from an inline proc ; snippet at 12https://play.nim-lang.org/#ix=2qPI
07:31:58Yardanicowill re-test the original package
07:32:06shashlick#14074? or the experiment i'm doing now
07:32:07disbothttps://github.com/nim-lang/Nim/issues/14074 -- 3--gc:arc does not retain global HashSet in --app:lib ; snippet at 12https://play.nim-lang.org/#ix=2j7k
07:34:28*krisppurg joined #nim
07:36:09leorizeshashlick: the experiment
07:37:01Yardanicoso https://github.com/nim-lang/Nim/issues/14383 seems to be fixed, do I need to make a PR with a test-case or no? :P
07:37:03disbot[ARC] Internal compiler error when calling an iterator from an inline proc ; snippet at 12https://play.nim-lang.org/#ix=2qPI
07:37:56shashlick@leorize - I created an exportdynamic branch for nimterop
07:38:06shashlicksimply clone and nimble test
07:38:17Yardanicoactually https://github.com/nim-lang/Nim/issues/14864 seems to be working with latest devel after the scoped PR too lol
07:38:18disbot[ARC] C compiler error with inline iterators and imports ; snippet at 12https://play.nim-lang.org/#ix=2qBN
07:38:45shashlickdiff shows you what all i changed - https://github.com/nimterop/nimterop/compare/exportdynamic
07:39:55shashlickturn off -export-dynamic and it no longer crashes but fails cause the cOverrides table doesn't get populated - so issues in either case
07:40:04shashlickgoing to bed - let me know what you find - thanks!
07:42:18ForumUpdaterBotNew thread by Valeriue: Questions about nim, see https://forum.nim-lang.org/t/6516
07:44:12shashlickNote that the plugins get cached so you might want to update loadPlugin to always recompile in case you change compile args
07:44:28Yardanicoforum thread "Hi! I recently came across a language nim, I would like to ask a couple of questions about this language. Is it suitable for low-level programming? What is created with its help? Where is this language used? For interest - is it suitable for writing Malware?How is he doing with networks, web and gui applications? If you answer, I will be grateful."
07:44:30Yardanicoa lot of questions :P
07:44:53Yardanicoand yes you can check contents even if it's "moderated" since the forum backend still gives you all posts
07:46:17Yardanicooh nim-random didn't compile with arc
07:46:21Yardanicointernal compiler error, yess
07:47:35leorizeThe answer for that should be: "yes" :P
07:54:48Yardanicooh no I broke nim forum
07:54:58Yardanicoi replied, and now my post is the "starting" post of the thread lol
07:55:03Yardanicoand it is displayed on the main forum page
08:06:04Yardanicook im moving closer to reproducing
08:06:13Yardanicoseems to be an iterator-related issue
08:11:49Yardanicohttps://gist.github.com/Yardanico/68ac519419d2bd459941e1fe2f7de58e
08:12:30Yardanicoah actually not related to iterators sorry
08:14:33FromDiscord<dom96> > @dom96 https://i.imgur.com/36hez6l.png :P↵@Yardanico[IRC]#0000 basic2d depends on redis? lol?
08:14:42Yardanicono
08:14:46Yardanicoit's just that they're too close :P
08:14:55Yardanicoif you zoom you can see the arrow passes through redis
08:15:14YardanicoI still didn't find good enough tools to visualize the whole graph
08:16:24Yardanicobut now I also parse version + license + author (author being a separate node)
08:17:34Yardanicohttps://github.com/nim-lang/Nim/issues/14899 done
08:17:36disbot[ARC] Template with a block results in a compiler crash ; snippet at 12https://play.nim-lang.org/#ix=2qPU
08:31:36*kenran joined #nim
08:37:06Yardanicoseems like templates got a bit broken with scoped PR
08:37:11Yardanicosequtils templates I mean :P
08:39:25*fanta1 joined #nim
08:42:08*Romanson quit (Quit: Connection closed for inactivity)
08:43:09*pietroppeter quit (Quit: Connection closed for inactivity)
08:43:41Yardanicohttps://github.com/nim-lang/Nim/issues/14900
08:43:43disbot[ARC] Weird issue with if expressions and algorithm.sortedByIt ; snippet at 12https://play.nim-lang.org/#ix=2qQ0
08:44:03FromGitter<gogolxdong> Anyone serialization library better than protobuf/cbor?
08:44:11Yardanico"better" is subjective
08:44:14Yardanicobut there's msgpack in nim
08:44:18Yardanicohttps://github.com/jangko/msgpack4nim
08:49:05FromGitter<gogolxdong> http://vstack.co/opensource1.html
08:54:10*marnix_ joined #nim
09:00:23FromGitter<gogolxdong> http://tutorials.jenkov.com/rion/rion-vs-other-formats.html
09:02:33*Vladar joined #nim
09:14:02*oddp joined #nim
09:17:22*marnix_ quit (Ping timeout: 256 seconds)
09:19:07FromDiscord<impbox> in JS backend, is this a reasonable way to do feature detection?↵```proc newAudioContext*(): AudioContext {.importjs: "new AudioContext() || new window.webkitAudioContext() || null".}```
09:19:26*marnix_ joined #nim
09:19:37FromDiscord<impbox> if not, is there a idiomatic way to do it?
09:21:06*kenran quit (Ping timeout: 256 seconds)
09:25:22FromDiscord<impbox> ^ AudioContext doesn't exist on Safari, but webkitAudioContext does, and older platforms might not have it at all.
09:37:39FromDiscord<Shucks> I've wrapped this cpp code from a library. But once I use it from nim the fields get mixed up for any reason (so Flags becomes Method for example). Any Idea? https://paste.sh/43qXAuVz#N9OY7Cj6d5QRpzRuWCRzEEeo
09:37:58Yardanicomaybe you need alignment or packing?
09:39:11FromDiscord<Shucks> Also this library is coded in cpp. Im using importc and `nim c`, does that matter?
09:49:42Yardanico@Clyybber you around?
09:50:13*al1ranger joined #nim
09:50:16YardanicoI was trying to compile (I know it'll leak but anyway) nitter with gc:orc, but got an infinite recursion in injectdestructors.nim line 240 isFirstWrite instead. what would be a good way to debug it?
09:51:39Yardanicoah wait it's actually kinda not infinite
09:51:52Yardanicobut fails with default of 2k call depth
09:52:44Yardanicowhen making depth higher it crashes in the c codegen instead
09:53:59*haxscramper joined #nim
09:54:11*krisppurg quit (Quit: Connection closed for inactivity)
09:57:06haxscramperIs it possible to suppress macro/template expansion when outputting compilation errors? I just got 250-lines in compilation errors, most of which are 'expected ... but expression <40-60 lines of template expansion> is of type X'.
09:58:17haxscramperShow original source code for expression instead of expanded version.
09:58:36*Vladar quit (Quit: Leaving)
10:02:31*marnix_ is now known as marnix
10:04:38FromDiscord<impbox> how can i catch TypeError? `except TypeError:` gives `Error: undeclared identifier: 'TypeError'` but if i don't try to catch it I get `Uncaught TypeError: AudioContext is not a constructor`
10:04:48Yardanicothat's a js error
10:05:16Yardanicoyou need to importc it
10:05:31Yardanicoah no
10:05:37Yardanicoit's actually already defined in jsffi module
10:05:43Yardanico"except JsTypeError:"
10:06:11Yardanicohttps://nim-lang.org/docs/jsffi.html#JsTypeError
10:06:21FromDiscord<impbox> thanks!
10:06:23FromDiscord<impbox> that does it
10:13:03*dddddd joined #nim
10:19:24FromDiscord<Clyybber> @Yardanico Sup
10:19:50FromDiscord<Clyybber> Hmm, interesting, it should also occur with just arc, does it?
10:20:11Yardanicoah yes of course
10:20:25Yardanicoit does
10:20:53PrestigeWho was working on adding curly bracket support? Curious about the progress
10:21:00YardanicoPrestige: @Zed-Inc
10:21:24FromDiscord<Clyybber> Araq: Ping
10:21:27FromDiscord<Zed> You called
10:21:36Yardanicothey're asking about your curly bracket support :D
10:21:44FromDiscord<Zed> lol
10:21:47FromDiscord<Zed> You hate it
10:21:50Yardanicoi do
10:22:00FromDiscord<Zed> :P
10:22:12PrestigeI am missing them :P
10:22:18FromDiscord<Zed> Prestige, curly bracket support works
10:22:31FromDiscord<Zed> Doesn't work on folders though
10:22:59FromDiscord<Zed> So you do have to pass in every file you want converted
10:23:09FromDiscord<Zed> The GitHub is nim_braces
10:23:14ForumUpdaterBotNew thread by Ftsf: How to do feature detection with JS backend?, see https://forum.nim-lang.org/t/6517
10:23:59FromDiscord<Varriount> @mattrb I wasn't able to get my Nim environment set up yet, however one option to hunt down the big is to use `--gc:arc` and valgrind/address sanitizer.
10:24:14Prestigehmm could it be configured in a nimble task very easily? Also I think nimpretty is going to throw a fit
10:24:27*al1ranger quit (Remote host closed the connection)
10:24:53*al1ranger joined #nim
10:25:14FromDiscord<Zed> Yeah you probably could
10:25:22FromDiscord<Zed> You'll have to do some testing though
10:27:48*al1ranger quit (Client Quit)
10:28:50FromDiscord<Varriount> @Avahe What are you doing with braces?
10:30:12FromDiscord<Zed> Nim
10:30:16FromDiscord<Zed> But with braces
10:30:24FromDiscord<Zed> Like C
10:30:28PrestigeI'd like to have them in my code for readability
10:30:46FromDiscord<Zed> Just don't use vscode lol
10:30:59FromDiscord<Zed> Or any editor really
10:31:11FromDiscord<Zed> Unless you like those squiggles
10:31:12PrestigeWhat do you mean?
10:31:21FromDiscord<Zed> Errors
10:32:08Prestigeoh are you talking about my comment on nimpretty?
10:33:27FromDiscord<Zed> No, just that if you use something like vscode and nim but with the braces all your code will have those syntax error red squiggles
10:33:42Yardanicowell of course
10:34:14FromDiscord<flywind> Maybe make a vscode plugin only for Nim syntax highlight.
10:34:49PrestigeI do like seeing errors though
10:35:49PrestigeCurly brace support is the one thing I'd change about nim, it seems so hard to format/read atm
10:35:58*endragor joined #nim
10:39:31*endragor quit (Remote host closed the connection)
10:40:20FromDiscord<Vindaar> > Curly brace support is the one thing I'd change about nim, it seems so hard to format/read atm↵say that again after looking at C code where the indentation is all messed up (yes, of course you can auto indent there, but still)
10:42:17PrestigeI'm fine w/enforced indentation, I'd just also like braces
10:42:38PrestigeHaving both would be nice
10:44:22FromDiscord<Zed> Braces are nice because you can define your own formatting
10:44:29FromDiscord<Zed> What suits you best
10:44:40Yardanicowdym
10:44:46FromDiscord<Zed> But forced indentation is better for multiple people working on the same project
10:44:48FromDiscord<impbox> until other people need to read it =)
10:45:03FromDiscord<lqdev> but then you can easily trigger people like me by placing a newline before your opening brace
10:45:17FromDiscord<Zed> @impbox you're a mod now??
10:45:26FromDiscord<impbox> am I?
10:45:32FromDiscord<Zed> Yup
10:45:34FromDiscord<impbox> first i've heard of it
10:45:42FromDiscord<Zed> Well your names green
10:45:47FromDiscord<impbox> _modifies some stuff_
10:46:09FromDiscord<Zed> > but then you can easily trigger people like me by placing a newline before your opening brace↵@lqdev disgusting
10:46:15FromDiscord<Zed> Never do this
10:46:18FromDiscord<Yardanico> @impbox well I did that
10:46:24FromDiscord<impbox> hmm yeah, weird I have mod perms
10:46:26FromDiscord<Yardanico> dom didn't decide on the moderator thing in discord yet
10:46:33FromDiscord<Yardanico> so maybe they'll be removed later lol
10:46:37FromDiscord<Yardanico> or I can remove if you don't want to have them
10:46:46FromDiscord<lqdev> `) {` is the best style, period.
10:46:49FromDiscord<impbox> I guess I'm pretty cool, so I totally won't abuse my powers for evil
10:46:53FromDiscord<Zed> Yup
10:47:03FromDiscord<Zed> That's what they all say impbox
10:47:15FromDiscord<impbox> @Yardanico I don't mind, but I guess I'd wanna know what we're expected to mod
10:47:22FromDiscord<Yardanico> usually nothing
10:47:31FromDiscord<Yardanico> unless in **extremely** rare situations
10:47:31FromDiscord<impbox> I suppose I can read the <#712684648454684752>
10:47:45FromDiscord<Yardanico> we literally only have 3 people banned on this discord
10:47:51FromDiscord<Yardanico> and it exists for like 3 years
10:47:51FromDiscord<Zed> What did they do
10:47:56FromDiscord<Yardanico> it's a secret
10:48:03FromDiscord<impbox> sounds reasonable
10:48:27FromDiscord<Zed> Ok you have seriously piqued my interest
10:48:37FromDiscord<Zed> But you can't tell
10:49:22FromDiscord<Zed> (edit) 'But you can't tell ... ' => 'But you can't tellwhat they did'
10:49:35FromDiscord<Yardanico> because I don't remember for two of them
10:49:36*kenran joined #nim
10:49:52FromDiscord<Yardanico> i wasn't really active on discord until this year (even though i'm *technically* the creator of this server)
10:50:02FromDiscord<impbox> we don't talk about _the incident_
10:51:42*marnix_ joined #nim
10:51:46FromDiscord<Clyybber> @Zed just spamming, both accounts are deleted by now
10:52:00FromDiscord<Yardanico> but the third one *is the incident*
10:52:06FromDiscord<Yardanico> you can't talk about that one
10:52:21FromDiscord<Clyybber> First rule of the incident: You don't talk about the incident
11:03:06*oculux joined #nim
11:03:13*marnix_ quit (Ping timeout: 264 seconds)
11:11:36*kenran quit (Ping timeout: 256 seconds)
11:22:02FromDiscord<exelotl> Prestige: if you're using vscode, have you tried the rainbow indent plugin? It helps Nim readability quite a lot :)
11:22:43haxscramper`strutils.split` returns `seq[string]`, right? At least in documentation it says this. But `assert split("Hello", "\n") is seq[string]` fails assertion: https://play.nim-lang.org/#ix=2qQM . I think I'm doing something extremely stupid, just cant figure out what exactly.
11:22:44haxscramper
11:25:50YardanicoI don't think "is" is exactly what you want here
11:26:20FromDiscord<impbox> sent a code paste, see https://play.nim-lang.org/#ix=2qQP
11:26:43PrestigeUsing noevim @exelotl
11:26:49Prestigeneovim lol
11:26:59Yardanicomoevim
11:27:01YardanicoAYAYA
11:28:23FromDiscord<Clyybber> @haxscramper Looks like a bug, can you create an issue?
11:28:27haxscramperThere is a `split(string, string): string` iterator and `split(string, string): seq[string]` proc. I'm not using `for` loop, so it should call `proc`, right?
11:28:34Yardanicono
11:28:38*pietroppeter joined #nim
11:28:40Yardanicoiterator *is* for loops
11:29:12Yardanicofor part in split("hello world", " "): echo part
11:29:16haxscramperAnd I don't have for loop. Which means the only thing it can possibly call is a `proc`.
11:29:20Yardanicoyes
11:29:41FromDiscord<Clyybber> ah, thats the bug then
11:29:50Yardanicomaybe it's even already reported
11:30:01FromDiscord<Clyybber> its getting the iterator, and echoing its type
11:30:10FromDiscord<Clyybber> still worth reporting IMO
11:30:13haxscramperAdding `toSeq` into assertion works - because it contains for loop internally and generates `seq[string]` as result?
11:30:24FromDiscord<Clyybber> yeah
11:31:28FromDiscord<Clyybber> @Yardanico What kind of error do you get when you expand the call limit?
11:31:35Yardanicooh lemme run it again
11:32:33Yardanicohttps://gist.github.com/Yardanico/33aae9c37d666c14e195c49be74493c7
11:33:00Yardanicoi'll try to make a small example *maybe*
11:33:10Yardanicobut it's not so easy since nitter is purely async-based :P
11:35:41FromDiscord<Clyybber> would be extremely nice if you manage to :D, but you can report it as is too.
11:36:46haxscramperJust to make sure it is really a bug and not misunderstanding on my side: https://play.nim-lang.org/#ix=2qQT - this should not raise any exceptions.
11:46:32FromDiscord<Clyybber> Its not clear that it should actually call the the proc instead
11:46:44FromDiscord<Clyybber> Perhaps it should give an ambiguity warning
11:47:11FromDiscord<Clyybber> But its tricky because currently iterators and procs reside in different namespaces
11:47:15FromDiscord<Clyybber> Thats the problem here
11:49:01FromDiscord<Clyybber> hah, actually the splitLines proc even gets mentioned in the issue about that
11:54:40*marnix quit (Ping timeout: 256 seconds)
11:55:50*Vladar joined #nim
11:57:27FromDiscord<dom96> so, it seems it is time I unwatch the Nim repo
11:58:09FromDiscord<dom96> argh, I might miss some interesting issues/PRs though
11:58:25FromDiscord<dom96> Anyone aware of a service/bot that can subscribe me to GitHub issues with certain keywords?
12:03:04FromDiscord<Vindaar> > so, it seems it is time I unwatch the Nim repo↵why?
12:03:17FromDiscord<dom96> too many notifications
12:04:29planetis[m]aha, found a bug!
12:04:37FromDiscord<Vindaar> never really understood that thought. do people actually try to keep github notifications at zero?
12:04:47planetis[m]with arc that causes oom
12:04:59FromDiscord<dom96> @Vindaar the problem is that I know I am missing things that I care about
12:05:13FromDiscord<dom96> Because of this I'd rather have less notifications that I have a chance to go through
12:05:57FromDiscord<Vindaar> I just use the repo filters for that
12:06:02*supakeen quit (Quit: WeeChat 2.8)
12:06:17FromDiscord<Clyybber> planetis: Nice!
12:06:44*supakeen joined #nim
12:07:07FromDiscord<Clyybber> @haxscramper Ah, found what you are searching for, you can do split(...).typeof(typeOfProc) is seq[string]
12:10:05FromDiscord<Clyybber> Araq: https://github.com/nim-lang/Nim/pull/14793 is ready, but please see my answer to your review comment
12:10:05disbotFix #14396
12:12:15haxscramper> If typeof is used to determine the result type of a proc/iterator/converter call c(X) ... , the interpretation where c is an iterator is **preferred over the other interpretations**, ... can be changed by passing typeOfProc as the second argument to typeof:
12:12:15haxscramper
12:12:15haxscramper
12:12:30haxscramperRight. Just missed this in documenation.
12:28:46*Trustable quit (Remote host closed the connection)
12:33:03*PMunch joined #nim
12:35:15FromDiscord<Shucks> So I figured out that wrapped enums doesn't work for me correctly. If I use `cint` for `Mode` or `Method` it works how it should be. But once I use the enums like `INJECTION_MODE(0)` wrong data passes to the library. Are there any pragmas I'm missing? https://paste.sh/VpLI_-br#Z0XrbDKgZWsqaMVwW7rx_iEL
12:36:39Yardanicoyeah
12:37:05Yardanicohttps://nim-lang.org/docs/manual.html#set-type-bit-fields
12:39:07Yardanicobut even then it might not work, you have to check that the enum you're wrapping really has powers of 2
12:43:10FromDiscord<Shucks> with that pragma it works
12:43:11FromDiscord<Shucks> finally
12:44:36*vikfret joined #nim
12:44:55FromDiscord<Clyybber> planetism: Are you on the latest devel?
12:45:15FromDiscord<Clyybber> oh, I see you are
13:13:30*lritter joined #nim
13:15:06PrestigeAre there many game libs available written in nim? I've just been playing around w/nico
13:16:31PMunchNimgame2 and Frag, not sure how updated they are though
13:17:03PMunchFrag seems to be outdated.. But Nimgame2 seems to still be going
13:17:40PMunchThis might help to answer your question: https://nimble.directory/search?query=game
13:17:48PrestigeLooks neat
13:17:56*marnix_ joined #nim
13:21:09PMunchBy the way Prestige there is #nim-gamedev as well
13:24:56ZevvMan I'm cringing all the time trying to do usefull stuff in go. No enums, no sum types or inheritence. Not even a way to check if a key exists in a map. It's truly a bit *too* spartan for me
13:25:41PrestigeYeah, I gave up on go pretty quickly
13:25:46PMunchWhat? No way to check if a key exists in a map?
13:26:24FromDiscord<Recruit_main707> We also have updated gosot bindings, but they are a bit wonky imo.↵They are bot bad nevertheless, and gokr recently wrapped ORX which might me a good option if you only need 2d
13:27:01FromDiscord<Recruit_main707> godot* i need to go back home and type on a keyboard soon or i will go crazy
13:27:21FromDiscord<Recruit_main707> (edit) 'bot' => 'not'
13:28:03PMunchWhat are you typing on now? A guitar?
13:33:44FromDiscord<Recruit_main707> Phone
13:34:07Zoom[m]Hm, you could probably hook up an audio-to-midi converter to a keyboard...
13:34:36PMunchZoom[m], bit limiting to only be able to write with A-G though..
13:34:47Yardanicodo default values for proc arguments propagate effects of these default values to the proc?
13:35:00YardanicoI mean if you do proc myproc(a = someCallWithSideEffects())
13:35:10PMunchAnyways, got to go
13:35:21PMunchHmm, that is a very interesting question Yardanico, I'd guess not
13:35:25Zoom[m]Nah, just use three strings and map frets to keys in your favourite layout
13:35:28Yardanicoa person in telegram has just asked about the reason why parsing time can't be side-effect free
13:35:32Yardanicoeven when you provide all values yourself
13:35:37Yardanicoas zone or locale
13:35:47*PMunch quit (Quit: leaving)
13:35:48Yardanicoit still will have TimeEffect
13:37:47FromDiscord<Rika> PMunch: ez, frets for keys
13:38:24FromDiscord<Rika> Still kinda limits you to the range of the highest string and a few more
13:38:28FromDiscord<Rika> But that should be enough
13:39:42*audiophile joined #nim
13:39:54*marnix_ quit (Ping timeout: 240 seconds)
14:04:45*Kaivo quit (Quit: WeeChat 2.8)
14:08:48*waleee-cl joined #nim
14:23:36*NimBot joined #nim
14:39:55ForumUpdaterBotNew thread by HashBackupJim: NvP: creating and sorting a large array of tuples, see https://forum.nim-lang.org/t/6518
14:40:21Yardanicowhat is NvP in this title^ ?
14:41:01*marnix joined #nim
14:41:45supakeenmaybe they meant mvp?
14:41:54YardanicoIt's the second time they're using this
14:41:57Yardanicoe.g. https://forum.nim-lang.org/t/6481
14:42:02supakeenoh, i've never seen it before
14:42:11Yardanicoah
14:42:15Yardanico"N-version programming (NVP), also known as multiversion programming or multiple-version dissimilar software, is a method or process in software engineering where multiple functionally equivalent programs are independently generated from the same initial specifications."
14:42:20Yardanicobasically when comparing different versions
14:42:29YardanicoPython vs Nim for these threads
14:42:45supakeenoh wait
14:42:47supakeenmaybe they mean
14:42:51supakeen'Nim vs Python'
14:42:58Yardanico:D
14:43:25supakeensince they're comparing python and nim each time
14:51:13*dddddd quit (Ping timeout: 264 seconds)
14:56:41FromDiscord<zetashift> yea they mean Nim vs Python
15:01:19FromDiscord<flywind> Does Nim has object construction hooks? I need to do generics type checking when object is initialized?
15:01:30FromDiscord<flywind> (edit) 'has' => 'have'
15:02:33FromDiscord<flywind> ```nim↵# needs to check U is subclass of T when d is initialized↵var d: Must[T, U]↵```
15:03:46FromDiscord<flywind> just like implicit hooks such as `=sink`, `=`, and `=destroy`
15:14:33FromDiscord<Rika> Don't think so
15:20:56*nkoz joined #nim
15:22:51FromDiscord<JackFly26> so i was trying to make that currying macro
15:22:56FromDiscord<JackFly26> and i think i got it
15:23:06FromDiscord<JackFly26> but now im getting a message that it isnt used
15:23:22FromDiscord<JackFly26> ```nim↵ let curried = curry(proc(x, y: int): int {.closure.} = x + y)↵ echo curried(3, 6)↵```
15:23:29FromDiscord<JackFly26> wait
15:23:38FromDiscord<JackFly26> curried(3)(6)
15:24:29FromDiscord<JackFly26> ```↵Error: expression 'proc (x: int): proc (y: int): int {.closure.} = result = proc (y: int): int {.closure.} = result = x +↵ ... y' is of type 'proc (x: int): proc (y: int): int{.closure.}{.closure, noSideEffect, gcsafe, locks: 0.}' and has to be discarded; for a function call use ()```
15:24:57FromDiscord<KingDarBoja> Yardanico: Sweet graph
15:24:58FromDiscord<KingDarBoja> ❤️
15:25:05FromDiscord<KingDarBoja> The package-author one ofc
15:26:01Yardanicowell yeah, I had to spend a few hours in the morning because I didn't know neo4j at all (Jeff in telegram recommended it), and fixing stuff in the pkgraph thing
15:26:08Yardanicosrc is in https://github.com/Yardanico/nim-snippets/tree/master/pkgraph btw
15:27:00Yardanicomost magic is in https://github.com/Yardanico/nim-snippets/blob/master/pkgraph/parse.nim
15:27:08Yardanicofetch is just boring fetching of all git repos
15:30:42Yardanico(which are in nimble)
15:38:21*pietroppeter quit (Quit: Connection closed for inactivity)
15:47:04*nikita` joined #nim
15:47:33FromDiscord<KingDarBoja> Ah, I knew it was familiar to me
15:47:40FromDiscord<KingDarBoja> Neo4J, I used it a little bit
15:47:46Yardanicowell I can also emit .dot graph
15:47:50Yardanicoit's much easier to do that :D
15:48:25FromDiscord<KingDarBoja> 😛
16:01:25*audiophile quit (Ping timeout: 264 seconds)
16:09:40*marnix quit (Ping timeout: 256 seconds)
16:12:23*vikfret quit (Quit: Leaving)
16:16:10*marnix joined #nim
16:25:09AvatarfighterHello everyone !
16:26:39FromDiscord<Rika> hi
16:29:53FromDiscord<KingDarBoja> Helloo
16:29:54FromDiscord<KingDarBoja> ❤️
16:32:54*marnix quit (Ping timeout: 256 seconds)
16:37:45leorizeshashlick: how can I build the exportdynamic branch to reproduce again?
16:38:25shashlickhey
16:38:34shashlickjust clone, checkout branch and then nimble test
16:39:04shashlickyou could even nimble minitest - will build toast and then run the first wrapper test which will fail
16:42:14leorizeshashlick: do you have some finer reproduction step that let me focus on one exact issue? :P
16:42:45*marnix joined #nim
16:42:56shashlickthat's what i have right now but i can work on a minimal version
16:46:33FromDiscord<jseb> first versions of nim were written in Pascal. Interesting… seeing what Pascal has become after all those years of dominations (i believe it's Python, because Pascal was very popular in schools in the past)
16:46:46FromDiscord<jseb> (edit) 'dominations' => 'domination'
16:48:13*marnix quit (Ping timeout: 264 seconds)
16:48:43FromDiscord<Rika> ?
16:49:11leorizeAraq said he wrote Nim in pascal because the alternatives were terrible iirc :P
16:50:39leorizeshashlick: please do :) I'm trying this on my musl machine so the results might be different
16:50:48leorizefor example I do have a stacktrace :P
16:52:48FromDiscord<lqdev> yeah I remember he said he didn't want to do it in c++ because switch case break sucks
16:53:24shashlicksure, i'm close
16:54:06leorizethough I'd say that Nim does borrow element from the pascal line of languages, though they're closer to Writh later inventions of modula and oberon than pascal
16:55:11FromDiscord<jseb> is `x..y` (with x>y) the same thing as `countdown` function ?
16:55:17leorizeno
16:55:29leorizex..y is countup only
16:55:44FromDiscord<Rika> wonder if itll be possible for that to be countdown when drnim comes
16:55:50FromDiscord<Rika> countdown *too
16:56:03Yardanicodrnim won't be default anyway
16:56:09leorizeit's deliberately designed to not countdown :)
16:56:15leorizecopied from pascal/ada I think
16:56:17FromDiscord<Rika> why?
16:56:24leorizeprevent bugs
16:56:29Yardanicodrnim? because solving all the equations is slow
16:56:32Yardanicoeven with Z3
16:58:26FromDiscord<jseb> ok. And is concurrency the same thing as a coroutine ?
16:58:35FromDiscord<jseb> (sleep/yield)
16:58:37Yardanico?
16:58:53Yardanicothere are both concurrency and parallelism in nim
16:58:53leorizeyes and no
16:58:58Yardanicoconcurrency is isually done via async
16:59:00Yardanicoparallelism - threads
16:59:12leorizeand async is not goroutines :P
16:59:35FromDiscord<jseb> i don't know go, i was thinking of Lua
16:59:57leorizedefinitely not the same as in lua if Zevv is to be trusted
17:00:21FromDiscord<jseb> ok, i will go back on this later anyway
17:00:26FromDiscord<jseb> thank you
17:00:41FromDiscord<Rika> lua's coroutines are stronger in a way
17:00:47leorizehe was working on a library to make it work like Lua, but postponed the work iirc
17:02:51leorizeshashlick: where can I see the new nightlies test failures again? I'm gonna see if I can solve them
17:02:52FromDiscord<lilah ▸ 🎀> how to get the future value when calling poll() manually assuming future.finished == true?
17:03:03leorizefuture.get
17:03:25*thomasross joined #nim
17:05:25FromDiscord<lilah ▸ 🎀> oo
17:05:39shashlick@leorize - here's the last run - https://travis-ci.org/github/genotrance/nightest/builds/702584173
17:05:42FromDiscord<lilah ▸ 🎀> it's read() but lead me to the correct answer so thanx
17:06:19leorizenp
17:09:23FromDiscord<JackFly26> hmm my error seems to be the same as the one in https://gist.github.com/cooldome/0f334cc0feaf5ac1c60082b73eec8a25
17:09:28FromDiscord<JackFly26> not that that helps at all
17:10:36shashlick@leorize - my minimal example works fine with arc
17:10:41shashlickfails with boehm
17:11:38leorizeJackFly26: can we see the code?
17:11:51leorizeshashlick: interesting, still the same sigsegv?
17:14:08shashlicknot exactly
17:15:17FromDiscord<JackFly26> um i sent some of the code earlier
17:16:14FromDiscord<JackFly26> https://play.nim-lang.org/#ix=2qU6
17:16:30FromDiscord<JackFly26> im sure there are better ways to do this but im new to macros so ¯\_(ツ)_/¯
17:17:14*nkoz quit (Ping timeout: 240 seconds)
17:17:48leorizeso... what are you trying to do?
17:18:42FromDiscord<JackFly26> make a macro that curries a function
17:18:53disruptek!repo currying
17:18:54disbothttps://github.com/t8m8/currying -- 9currying: 11Currying Library for Nim 15 36⭐ 4🍴
17:19:10FromDiscord<JackFly26> i swear i looked up "nim currying" and nothing came up
17:19:38Yardanicoalso https://github.com/zer0-star/nim-curry
17:20:02leorizehttps://play.nim-lang.org/#ix=2qU9
17:20:12leorizeyour macro does work if that's what you're wondering about
17:20:52FromDiscord<JackFly26> what it didnt earlier
17:20:57FromDiscord<JackFly26> i tried binding it to a var
17:21:29FromDiscord<JackFly26> weird
17:21:33FromDiscord<JackFly26> works in playground
17:21:42Yardanicowhat's your nim version?
17:21:57FromDiscord<JackFly26> i upgraded like 3 days ago
17:21:58FromDiscord<JackFly26> idk
17:22:06FromDiscord<JackFly26> 1.2.0
17:22:13shashlick@leorize - my minimal version works fine with arc so i think once arc supports toast, we might be able to get it to work
17:22:17leorizeyea the latest is 1.2.4 now :p
17:22:33FromDiscord<JackFly26> ok it works now weird
17:23:00FromDiscord<JackFly26> well the aur says otherwise
17:23:07FromDiscord<JackFly26> is there a better place to install nim from
17:23:14leorizeshashlick: well I just built toast with arc if you're wondering
17:23:24FromDiscord<Recruit_main707> Official page
17:23:25shashlickcompiling toast with --gc:arc now with latest head and get an internal error
17:24:09leorizeshashlick: it just works here
17:24:14leorizethough I'm one commit behind
17:24:37shashlicki'm on af27e6bdea63bbf66718193ec44bc61e745ded38
17:24:46leorize1854d29781aff913ca6892cbf73df91b0399397e here
17:24:59leorizeJackFly26: https://www.archlinux.org/packages/community/x86_64/nim/
17:25:03leorizeit's marked out of date
17:25:08FromDiscord<JackFly26> oh
17:25:13Yardanicochoosenim
17:25:33leorizeiirc manjaro have an updated version (which is kinda insulting to see :P)
17:25:38FromDiscord<JackFly26> oof
17:25:42FromDiscord<JackFly26> ok ill get choosenim
17:25:52disruptek~gitnim
17:25:53disbotgitnim: 11https://gitnim.com/ -- choosenim for choosey nimions -- disruptek
17:26:10leorizeI never understand why the maintainer just doesn't let the package go if they don't want to maintain it
17:26:30FromDiscord<JackFly26> yeah idk
17:26:55disruptek!repo disruptek/skiplists
17:26:55disbothttps://github.com/disruptek/skiplists -- 9skiplists: 11 15 0⭐ 0🍴
17:27:02leorizeif there's demand I can push an AUR package for Nim (and if there's someone willing to maintain it)
17:27:14FromDiscord<JackFly26> well theres also nim-git
17:27:18FromDiscord<JackFly26> would that be up to date
17:27:39disruptekgit nim is updated almost daily.
17:28:04shashlick@leorize - nope, even with that commit, get the internal error
17:28:14shashlickwhat did you change to get arc working
17:28:16Yardanicoshashlick: can you compile with koch temp c?
17:28:17leorizeshashlick: I'm building from exportdynamic branch
17:28:20Yardanicoto show full stacktrace
17:28:22leorizejust swapped boehm with arch
17:28:25leorizearc*
17:29:21leorizejackfly26: the git one is also out of date in term of the build script...
17:29:26shashlick@leorize - try the master branch and change to arc - both in toast.nims and in getters
17:30:07leorizegetters?
17:30:22shashlicknimterop/toastlib/getters.nim - it compiles the plugin
17:30:29shashlicki don't have code yet to detect the gc
17:30:37shashlickloadPlugin
17:30:41leorizecompiled toast and working
17:30:44Oddmongernim arch is 1.2.0
17:31:45shashlickhmm - doesn't even compile for me
17:31:55Oddmongerwhy is it flagged out-of-date ?
17:32:02leorizebecause it's out of date
17:32:07leorizewe're now at 1.2.4
17:32:31Oddmongeroh
17:32:43leorizeand there are many many things that are wrong with that build script...
17:32:45FromDiscord<JackFly26> ok well the macro now magically works
17:32:46FromDiscord<JackFly26> thanks
17:33:00Yardanicoleorize: cross-compilation is one of them :P
17:33:04FromDiscord<JackFly26> it would be nice to make it also work as a pragma but im lazy
17:33:19Yardanicohttps://bugs.archlinux.org/task/67092 no replies, although they assigned the current "maintainer" of the nim packages
17:33:22Yardanicopackage*
17:33:45*krux02 joined #nim
17:33:56leorizeI can hack up a PKGBUILD for you if you would like to maintain it
17:36:51Oddmongerthe arch problem is good to know, i was just trying to set up NDK env for android (don't know it it uses GCC)
17:37:05shashlick@leorize @yardanico - here's the koch temp output - http://ix.io/2qUd
17:39:32leorizeI'm gonna try clearing out my nimble dir
17:40:11leorizeyep, that does the trick
17:41:15leorizeI'm using an older version of pretty much all packages :P
17:41:20leorizeunicodedb 0.7.2
17:41:34leorizecligen #head but like 5 months old
17:41:49shashlickya i never keep #head versions around - they override all version checks
17:55:42*lmariscal0 joined #nim
17:59:07*pietroppeter joined #nim
18:00:13Oddmongeris it ok to use nim-git from AUR, for archlinux ?
18:01:21krux02Oddmonger, probably.
18:01:59Oddmongeri ask this, because there is no «conflict» defined on the community/nim , in the PKGBUILD
18:02:20Oddmongeroops
18:02:24Oddmongermy bad, there is
18:03:02leorizenim-git from AUR make less wrong choices but still plenty of them
18:03:56leorizenot their fault, really, we haven't got a streamlined way to easily package nim, which I'll have to tackle eventually
18:04:54Oddmongerit seems complicated indeed
18:05:12disrupteknim-git?
18:05:45disruptekoh, it's an os package?
18:06:35Oddmongeruser repo for archlinux
18:06:54Oddmongerbut seems better than the official :/
18:07:27disruptekjust try gitnim.
18:10:03Oddmongerok i'll try, thank you
18:10:21leorize@timotheecour how does your testament batching thing works?
18:10:39leorizeis it windows-only and how many splits can it do?
18:11:06krux02I wrote testament batching
18:11:19krux02if you talk about megatest
18:11:37leorizeno, it's the new NIM_TESTATMENT_BATCH thingy
18:11:55leorizesplit the suite into smaller chunks which we can parallelize by spawning more builders
18:12:11leorize(read: different machines to run them concurrently)
18:12:14*laqq3 joined #nim
18:12:42krux02ok, can't help with that.
18:15:33*laqq3 is now known as legendre6891
18:16:03*legendre6891 is now known as laqq3
18:19:09*vsantana joined #nim
18:26:35Zevvleorize: I'm not to be trusted
18:32:06disruptekleorize: me either.
18:36:54*fredrikhr quit (Read error: Connection reset by peer)
18:37:20*fredrikhr joined #nim
18:37:48*fredrikhr quit (Read error: Connection reset by peer)
18:38:15*fredrikhr joined #nim
18:44:23*nsf joined #nim
18:53:32*PMunch joined #nim
19:05:43*Vladar quit (Quit: Leaving)
19:11:19*couven92 joined #nim
19:11:58*kenran joined #nim
19:14:25*fredrikhr quit (Ping timeout: 246 seconds)
19:19:27*dddddd joined #nim
19:23:02*laqq3 quit (Ping timeout: 244 seconds)
19:28:27*laqq3 joined #nim
19:40:03*nsf quit (Quit: WeeChat 2.8)
19:41:30FromDiscord<lilah ▸ 🎀> https://media.discordapp.net/attachments/371759389889003532/729059329906573473/unknown.png
19:41:48FromDiscord<lilah ▸ 🎀> how to pass req by reference here?
19:42:32FromDiscord<lilah ▸ 🎀> i've tried to read about it but i'm failing to understand exactly what ref is in nim 😅
19:42:55FromDiscord<Rika> use var if you need to modify it
19:43:03FromDiscord<lilah ▸ 🎀> but if i just try to pass a Request around i get gcsafe errors
19:43:24FromDiscord<Rika> then just change request itself to be a `ref object`?
19:43:30FromDiscord<Rika> not sure what you want tbh
19:44:54FromDiscord<Elegant Beef> A reference is a managed pointer, one that the collection system can see and handle. Atleast that's my understanding
19:46:36FromDiscord<Rika> yes
19:49:15FromDiscord<Elegant Beef> And references being pointers means that the values are mutable even without specification, in the case you use `let a = refObject` a can be mutated, but not reassigned
19:50:55FromDiscord<lilah ▸ 🎀> https://pastebin.com/raw/cniR60eL
19:52:04FromDiscord<lilah ▸ 🎀> i'm trying to use asynchttpserver, but having problems passing around the request from my first handler to another due to my understanding of this
19:52:29FromDiscord<lilah ▸ 🎀> i get a gcsafe error with this for example
19:53:12FromDiscord<Elegant Beef> Request isnt a reference?
19:53:46FromDiscord<Rika> are you accessing globals with the handler
19:53:56FromDiscord<Rika> thatll gcsafe error you
19:54:06FromDiscord<Rika> i think...
19:54:52FromDiscord<Elegant Beef> Async happens all on the same thread doesnt it?
19:54:56FromDiscord<lilah ▸ 🎀> i don't know how to pass it by reference to another_handler (if that's what i'm supposed to do)
19:55:13FromDiscord<lilah ▸ 🎀> or if thats just an implicit thing
19:55:18FromDiscord<lilah ▸ 🎀> that should work
19:55:27FromDiscord<Elegant Beef> Well no i was merely asking cause i thought this was threaded, and if it was you were attempting to share heap across threads
19:55:31FromDiscord<Rika> you're not
19:55:46FromDiscord<Rika> are you using globals in either of the handlers
19:56:09FromDiscord<lilah ▸ 🎀> i will check
19:56:24FromDiscord<Rika> like for example that cfg object thingy
20:02:22FromDiscord<Rika> @lilah ▸ 🎀 tbh, you can just "risk it" and mark both handlers as gcsafe by adding that beside async
20:02:49FromDiscord<Rika> so `{.async, gcsafe.}` but i think its better to refactor to remove the warning
20:02:54FromDiscord<Rika> or error rather
20:04:09FromDiscord<lilah ▸ 🎀> yeh thanks i think you're right i must be messing up somewhere, adding that did fix it but i also want to find out what i did wrong 😅
20:10:24FromDiscord<lilah ▸ 🎀> ah it was happening from my global config object, which i'd unhelpfully trimmed from the pastebin 😢
20:11:22FromDiscord<Rika> guessed it though since you didnt remove it from the Port setting
20:11:30FromDiscord<Rika> did i?
20:11:36FromDiscord<Rika> > like for example that cfg object thingy↵yeah here
20:11:49FromDiscord<lilah ▸ 🎀> :P
20:17:34*kenran quit (Ping timeout: 260 seconds)
20:24:20shashlick@leorize - so you could reproduce the internal error?
20:29:02oddpIs the chief secretly working on the next big feature for nim to conquer all other langs? Haven't seen him in a while in here.
20:29:36FromDiscord<Rika> dunno, prolly bug squishing
20:29:54leorizehe always secretly work on something :P in this case gc:arc/orc
20:30:04leorizeshashlick: yea reproduced
20:30:10leorizenot sure which deps caused it
20:30:14shashlickokay cool
20:30:14FromDiscord<Elegant Beef> Imagine if we just redirected all language websites to nim-lang.org
20:30:17FromDiscord<Elegant Beef> We'd be the cool kids
20:30:55*krisppurg joined #nim
20:32:16*solitudesf quit (Ping timeout: 244 seconds)
20:32:17oddpNot enough pattern matching capabilities to be considered cool. ;)
20:32:27FromDiscord<Elegant Beef> Damn
20:32:39FromDiscord<Elegant Beef> Go add them so we can be
20:32:47Zoom[m]I've just started watching the Omni talk from NimConf and the mistake in explaining of how digital audio works happens too soon.
20:34:57Zoom[m]It's 2020, we should overcome that myth: higher samplerates do not provide higher sound representation accuracy! Samplerate determines the maximum encoded frequency, that's all.
20:37:00oddpYeah, needs more borito analogies. Especially since sampling rate in digital audio is just a monoid in the category of endofunctors.
20:37:11oddpburrito, oops.
20:38:11Zoom[m]Yeah, right, of course.
20:38:48FromDiscord<Technisha Circuit (LGBTQIAP+)> What's orc?
20:38:52FromDiscord<Technisha Circuit (LGBTQIAP+)> Is it just arc?
20:38:55FromDiscord<Rika> arc with a cycle detector
20:38:57FromDiscord<Rika> or something
20:38:59FromDiscord<Rika> cycle something
20:39:02FromDiscord<Rika> i dont really know
20:39:16oddpYeah, arc + cycle detection.
20:39:32FromDiscord<Technisha Circuit (LGBTQIAP+)> O
20:39:42FromDiscord<Technisha Circuit (LGBTQIAP+)> Is it better to use orc over arc then?
20:39:52FromDiscord<Rika> not really
20:39:59FromDiscord<Technisha Circuit (LGBTQIAP+)> Oh?
20:40:01FromDiscord<Rika> you dont always need the cycle detection afaik
20:40:02oddp4raq's recent nimconf talk is pretty cool.
20:40:07FromDiscord<Technisha Circuit (LGBTQIAP+)> Oh okay
20:40:10FromDiscord<Rika> also i think it has a runtime cost? no clue
20:40:11oddpHe talks about these collectors.
20:40:18FromDiscord<Technisha Circuit (LGBTQIAP+)> O
20:40:22*fredrik92 joined #nim
20:40:24FromDiscord<Rika> rc
20:40:25FromDiscord<Rika> 😛
20:43:14*couven92 quit (Ping timeout: 240 seconds)
20:43:54*fredrik92 quit (Read error: Connection reset by peer)
20:44:20*fredrik92 joined #nim
20:44:50*fredrik92 quit (Read error: Connection reset by peer)
20:45:15*fredrik92 joined #nim
20:46:46FromDiscord<Technisha Circuit (LGBTQIAP+)> :P
20:46:57FromDiscord<Technisha Circuit (LGBTQIAP+)> I need to actually get working on a project-
20:47:13FromDiscord<Technisha Circuit (LGBTQIAP+)> I need a project that I won't quit :/
20:47:16FromDiscord<Elegant Beef> And you moved through 10 seperate projects in the course of that sentence
20:47:25FromDiscord<Technisha Circuit (LGBTQIAP+)> :P
20:47:48FromDiscord<Technisha Circuit (LGBTQIAP+)> ~~Maybe a websocket chat program-~~
20:48:10FromDiscord<Elegant Beef> Just what we need slack 6.0
20:49:13FromDiscord<Technisha Circuit (LGBTQIAP+)> Lmao
20:49:24FromDiscord<Rika> discord 2
20:50:44FromDiscord<Elegant Beef> We already have riot.im, so aslong as you can make a good voice service for it we'll be fine
20:50:51FromDiscord<Elegant Beef> Wait they're rebranding with new features soon
20:51:11oddpBut it's so easy! 1) Think about idea. 2) Read and save user's clipboard each keypress 3) ... 4) Profit!
20:51:27FromDiscord<Elegant Beef> Damn what are you a IOS app dev?!
20:51:41oddpThink about all that ad profiling moneyz!!!
20:51:56FromDiscord<Elegant Beef> Think about all the passwords we can sell!
20:53:23FromDiscord<Elegant Beef> Well if you do make a websocket chat client make sure you use fidget for the UI 😄
20:53:45oddpCool. Will you join my startup? ;)
20:53:57FromDiscord<Elegant Beef> I assume it's revshare?
20:54:00*fanta1 quit (Quit: fanta1)
20:54:02FromDiscord<Elegant Beef> If so sign me up!
20:54:06FromDiscord<Elegant Beef> I love working for no pay
20:54:26FromDiscord<Rika> i already do that every day!
20:54:32FromDiscord<Elegant Beef> Same
21:02:04*lritter quit (Ping timeout: 256 seconds)
21:06:41*lritter joined #nim
21:12:38*marnix joined #nim
21:17:14*nkoz joined #nim
21:25:35*SenasOzys joined #nim
21:27:24*haxscramper quit (Remote host closed the connection)
21:27:28*SenasOzys quit (Client Quit)
21:27:50*SenasOzys joined #nim
21:29:03*SenasOzys quit (Remote host closed the connection)
21:29:20*SenasOzys joined #nim
21:30:10disrupteki haven't even finished the impl and skiplists are already breaking arc.
21:30:33*SenasOzys quit (Remote host closed the connection)
21:38:52*pietroppeter quit (Quit: Connection closed for inactivity)
21:45:56*laqq3 quit (Ping timeout: 256 seconds)
21:49:00*laqq3 joined #nim
21:55:34*laqq3 quit (Remote host closed the connection)
21:56:01*laqq3 joined #nim
21:57:55*vsantana quit (Read error: Connection reset by peer)
22:36:34FromGitter<mikebelanger> Hi guys. Really digging Jester so far. One thing though - I can't seem to serve a static file, if I add routes manually. Like so ```import jester, asyncdispatch, asyncnet ⏎ ⏎ const ⏎ home = "/" ⏎ index = "/index.html" ... [https://gitter.im/nim-lang/Nim?at=5f010471fa0c9221fc7c00b5]
22:46:54*vicfred quit (Quit: Leaving)
22:50:02PMunch@mikebelanger, did you delete your message on GitHub?
22:50:21PMunchI tried to see the full message but the link seems to not point to anything
22:54:13*thomasross quit (Ping timeout: 264 seconds)
23:28:16*marnix quit (Ping timeout: 256 seconds)
23:31:27*krux02_ joined #nim
23:33:56*krux02 quit (Ping timeout: 256 seconds)
23:41:05FromDiscord<Technisha Circuit (LGBTQIAP+)> Does arc work with asynchronous stuff yet?
23:41:58FromDiscord<Rika> thats why orc exists
23:44:17FromDiscord<Technisha Circuit (LGBTQIAP+)> Wait, orc works with asynchronous stuff?
23:45:03FromDiscord<Technisha Circuit (LGBTQIAP+)> Also how would i get a string from a .so file i compiled? :P
23:45:35FromDiscord<Rika> orc is supposed to work for async
23:45:44FromDiscord<Rika> but i dont think it works just yet?
23:46:41FromDiscord<Technisha Circuit (LGBTQIAP+)> Oh okay
23:49:34bung_can I have optinal generic type ?
23:51:56*casaca quit (Excess Flood)
23:52:12*casaca joined #nim
23:55:24*nikita` quit (Quit: leaving)
23:59:36FromDiscord<Rika> bung_ wdym?
23:59:51FromDiscord<Rika> there's an `Option` type in the `options` module