<< 29-07-2020 >>

00:01:28FromDiscord<ShalokShalom> https://dev.to/vtrpldn/vs-code-shortcuts-that-i-would-teach-myself-if-i-had-a-time-machine-with-limited-fuel-36md
00:04:34FromGitter<awr1> for a given enum is there an easy way to generate a set containing all possible enum values of the enum in question? I'm thinking `{EnumType.low .. EnumType.high}` but I wondered if there was anything else
00:04:47Yardanicofor enums with holes your way will work just fine
00:04:54disrupteknah.
00:05:01Yardanicoyou can also do EnumType.firstValue .. EnumType.lastValue
00:06:37*lbart quit (Read error: Connection reset by peer)
00:06:37Yardanicodisruptek: why? it works for enums without holes just fine
00:06:52*lbart joined #nim
00:07:27disrupteksure, but that's not what you said.
00:07:37Yardanicowell I meant *without holes]
00:07:38Yardanicolol
00:07:47Yardanicoi only woke up a few hours ago
00:07:54disrupteknot my problem.
00:08:05Yardanicoyou could've corrected me instead of just saying "no" :P
00:08:20Yardanico@awr1 - in short, for enums without holes it'll work fine
00:08:34Yardanicoeither Enum.low .. Enum.high or Enum.firstValue .. Enum.lastValue
00:08:37Yardanicoboth work
00:08:47*altarrel quit (Quit: Konversation terminated!)
00:12:00FromGitter<awr1> this is for an enum without holes
00:12:03Yardanicoyes
00:12:19FromGitter<awr1> sets don't really work well with holed enums in general
00:12:27*bunbunbunbunny joined #nim
00:18:48*endragor joined #nim
00:20:24disruptekclyybber: when will my prototypes work correctly?
00:20:38Yardanicodisruptek: when the PR is merged
00:20:46disruptekWHEN WHEN WHEN
00:20:58Yardanicodisruptek: https://github.com/nim-lang/Nim/pull/15098
00:21:03Yardanicosorry wrong one
00:21:11disbotFix #15097 Compiler crashes when referring to an undeclared gensymmed…
00:21:12Yardanicohttps://github.com/nim-lang/Nim/pull/15091
00:21:13disbotFix forward declaration issues in template/macro context
00:25:25*endragor quit (Ping timeout: 264 seconds)
00:33:18*bung joined #nim
00:45:36*pangey quit (Ping timeout: 244 seconds)
00:49:31*pbb quit (Ping timeout: 272 seconds)
00:49:40*pbb joined #nim
00:49:44*Ekho quit (Ping timeout: 256 seconds)
00:50:43*Trustable quit (Remote host closed the connection)
00:50:57*Ekho- joined #nim
00:52:09*Ekho- is now known as Ekho
00:55:04*pangey joined #nim
00:57:54*oneark quit (*.net *.split)
00:57:55*matti quit (*.net *.split)
00:57:55*sirn quit (*.net *.split)
00:57:55*LyndsySimon quit (*.net *.split)
00:57:55*Hotbees quit (*.net *.split)
00:57:55*r4vi quit (*.net *.split)
00:57:55*hpyc9 quit (*.net *.split)
00:57:55*crem quit (*.net *.split)
00:57:55*stefantalpalaru quit (*.net *.split)
01:01:51*oneark joined #nim
01:01:51*matti joined #nim
01:01:51*sirn joined #nim
01:01:51*LyndsySimon joined #nim
01:01:51*Hotbees joined #nim
01:01:51*r4vi joined #nim
01:01:51*hpyc9 joined #nim
01:01:51*crem joined #nim
01:01:51*stefantalpalaru joined #nim
01:03:28*Zambyte[m] quit (Remote host closed the connection)
01:03:28*watzon quit (Write error: Connection reset by peer)
01:03:30*dzamo[m] quit (Read error: Connection reset by peer)
01:03:30*ee7[m] quit (Read error: Connection reset by peer)
01:03:30*Zoom[m] quit (Read error: Connection reset by peer)
01:03:31*BitPuffin quit (Write error: Connection reset by peer)
01:03:31*codic quit (Remote host closed the connection)
01:03:31*stisa[m] quit (Remote host closed the connection)
01:03:32*rridley[m] quit (Read error: Connection reset by peer)
01:03:34*silvernode[m] quit (Write error: Connection reset by peer)
01:03:34*xicheng[m] quit (Write error: Connection reset by peer)
01:03:34*wontruefree[m] quit (Write error: Connection reset by peer)
01:03:36*sendell quit (Remote host closed the connection)
01:03:39*k0mpjut0r quit (Write error: Connection reset by peer)
01:03:41*oneark quit (Remote host closed the connection)
01:03:42*guelosk[m] quit (Read error: Connection reset by peer)
01:03:42*lnxw37d4 quit (Read error: Connection reset by peer)
01:03:43*leorize[m] quit (Remote host closed the connection)
01:03:43*planetis[m] quit (Remote host closed the connection)
01:03:44*reversem3 quit (Remote host closed the connection)
01:03:44*slackytude[m] quit (Read error: Connection reset by peer)
01:03:44*MTRNord[m] quit (Remote host closed the connection)
01:03:46*j4nvkvc quit (Remote host closed the connection)
01:03:47*skrylar[m] quit (Read error: Connection reset by peer)
01:03:47*unclechu quit (Read error: Connection reset by peer)
01:03:47*neceve quit (Read error: Connection reset by peer)
01:03:47*swamptest1[m] quit (Read error: Connection reset by peer)
01:04:54*matti quit (Ping timeout: 270 seconds)
01:07:23*matti joined #nim
01:10:47*wontruefree[m] joined #nim
01:15:11*endragor joined #nim
01:16:36*apahl quit (Ping timeout: 244 seconds)
01:18:32*apahl joined #nim
01:25:48*maier joined #nim
01:30:44*maier quit (Ping timeout: 244 seconds)
01:40:51*planetis[m] joined #nim
01:40:51*oneark joined #nim
01:40:51*codic joined #nim
01:40:51*guelosk[m] joined #nim
01:40:51*Zambyte[m] joined #nim
01:40:51*leorize[m] joined #nim
01:40:51*BitPuffin joined #nim
01:40:52*reversem3 joined #nim
01:40:52*k0mpjut0r joined #nim
01:40:52*dzamo[m] joined #nim
01:40:52*MTRNord[m] joined #nim
01:40:52*j4nvkvc joined #nim
01:40:52*unclechu joined #nim
01:40:52*watzon joined #nim
01:40:52*GitterIntegratio joined #nim
01:40:52*lnxw37d4 joined #nim
01:40:57*rridley[m] joined #nim
01:40:57*skrylar[m] joined #nim
01:40:57*neceve joined #nim
01:40:58*slackytude[m] joined #nim
01:40:58*ee7[m] joined #nim
01:40:58*sendell joined #nim
01:40:58*Zoom[m] joined #nim
01:40:58*stisa[m] joined #nim
01:40:59*xicheng[m] joined #nim
01:40:59*swamptest1[m] joined #nim
01:40:59*silvernode[m] joined #nim
01:57:53*endragor_ joined #nim
01:57:54*endragor quit (Read error: Connection reset by peer)
02:05:59*bunbunbunbunny quit (Quit: Lost terminal)
02:07:25*muffindrake quit (Ping timeout: 272 seconds)
02:09:21*muffindrake joined #nim
02:12:35*endragor_ quit (Remote host closed the connection)
02:12:45*endragor joined #nim
02:20:23*audiofile quit (Quit: Default Quit Message)
02:20:34*dzamo joined #nim
02:23:19*theelous3 quit (Read error: Connection reset by peer)
02:26:13*ftsf joined #nim
02:35:49*rockcavera quit (Remote host closed the connection)
02:40:04FromDiscord<treeform> Hey, is there a way to get `dumpHeapInstances()` style info from `--gc:arc`? It looks like `dumpHeapInstances()` does not work with `--gc:arc`.
02:42:32FromDiscord<treeform> I think my memory should be 700mb, but its 20GB instead. Not sure what is taking up the space. I would like to figure it out.
02:48:28*lritter quit (Ping timeout: 256 seconds)
02:49:06*lritter joined #nim
02:53:09FromDiscord<Yardanico> I think dumpHeapInstances relies on RTTI, arc doesn't have it. Did you try with orc first to see if it changes anything (on latest devel of course)?
02:53:37FromDiscord<Yardanico> You can -d:useMalloc --debugger:native with arc/orc and then see where the leaks originate
02:53:49FromDiscord<Yardanico> You can e.g. use massif for that
02:53:56FromDiscord<Yardanico> Or just valgrind itself
02:57:01shashlickyardanico - you ready to try out `nimble --gc:arc test`
02:59:21FromDiscord<Yardanico> Not right now, sorry :(
03:03:41shashlickno problem - see the changelog for the behavior changes - https://github.com/nim-lang/nimble/pull/829/files#diff-60bcbdc1b388b125a81c01bb5f659025
03:03:41disbotFix #757 - compile flags for test
03:08:05*thomasross quit (Ping timeout: 240 seconds)
03:10:33FromDiscord<Yardanico> Oh, neat
03:15:59*ftsf quit (Quit: Leaving)
03:16:27*enthus1ast quit (Ping timeout: 272 seconds)
03:17:44*apahl quit (Ping timeout: 246 seconds)
03:18:46*apahl joined #nim
03:19:10FromDiscord<treeform> @Yardanico I switched back --gc:refc and dumpHeapInstances() and I was able to quickly find my problem. I have not used massif or valgrind ... do they work with VC++ and Windows? I wich --gc:arc had quick way to see what is most of my memory.
03:19:25FromDiscord<Yardanico> Oh, Windows
03:19:46FromDiscord<impbox> ooh need to try this dumpHeapInstances thing, is it documented anywhere?
03:19:55FromDiscord<impbox> lack of valgrind on windows really sucks D:
03:20:09FromDiscord<Yardanico> I don't think there's something like dumpHeapInstances currently, mainly because there's no RTTI in ARC, maybe Araq can think of something :D
03:20:24FromDiscord<treeform> @impbox https://github.com/nim-lang/Nim/blob/da29222f86f7689227ffe12605842d18c9bf0fc1/lib/system/gc_common.nim#L40 just here I think
03:20:48FromDiscord<impbox> thx
03:20:50FromDiscord<Yardanico> @impbox it is documented
03:20:52FromDiscord<Yardanico> https://nim-lang.org/docs/gc.html
03:20:55FromDiscord<Yardanico> The last section
03:21:22FromDiscord<treeform> I wrote a little heapDiff, it tells me where the memory grew from last time I ran it. https://github.com/treeform/fidget/blob/master/src/fidget/opengl/perf.nim#L157
03:21:36FromDiscord<impbox> @Yardanico seems to be missing from there, just dumpNumberOfInstances
03:21:49FromDiscord<impbox> nice
03:21:57FromDiscord<Yardanico> Wdym missing?
03:22:14FromDiscord<impbox> @Yardanico no mention of `dumpHeapInstances` in your link
03:22:23FromDiscord<Yardanico> There is
03:22:25FromDiscord<Yardanico> Last section
03:22:40FromDiscord<Yardanico> Ah no dumpHeapInstances ok
03:23:11FromDiscord<Yardanico> dumpNumberOfInstances uses dumpHeapInstances internally anyway
03:23:51FromDiscord<Yardanico> It's just that with dumpNumberOfInstances you get a formatted string with info, but with dumpHeapInstances it's an iterator
03:25:37*krux02_ quit (Remote host closed the connection)
03:26:42*maier joined #nim
03:28:07*enthus1ast joined #nim
03:31:25*maier quit (Ping timeout: 240 seconds)
03:34:24FromDiscord<Yardanico> Not sure how hard it would be to bring RTTI (or something just for tracking memory usage by types) for ARC
03:34:44FromDiscord<Yardanico> But aren't there any tools like that for C to track memory usage of specific types?
03:56:24FromDiscord<Varriount> Valgrind?
03:56:31FromDiscord<treeform> well nim knows all of the types right? can you just walk each ref and see what it points to?
03:56:44FromDiscord<treeform> In theory a big macro could do it.
03:57:06FromDiscord<Yardanico> Well Nim doesn't really know the types at runtime currently :)
03:57:22FromDiscord<Yardanico> @Varriount I don't think there's a way for valgrind to actually track types
03:57:23FromDiscord<treeform> with -d:nimTypeNames it does?
03:57:26FromDiscord<Varriount> Treeform: without rtti information, you can't know what the underlying type of a reference might be. It could be an extended type
03:57:28FromDiscord<Yardanico> Like which structs and stuff
03:57:33FromDiscord<Yardanico> @treeform even for arc?
03:57:44FromDiscord<treeform> I don't know about arc
04:06:02*supakeen quit (Quit: WeeChat 2.8)
04:06:37*supakeen joined #nim
04:30:01Yardanicoshashlick: I guess I'll try #829 rn
04:31:44Yardanicoyeah seems to work for --gc:arc :P
04:37:22shashlickneat
04:37:34shashlickyou agree with the changes? slight behavioral differences
04:37:42YardanicoI don't use nimble a lot honestly :P
04:37:48Yardanicoit's better to ask people who do
04:41:05shashlickwell you better start, and if you don't want to yet, i want to know why 😉
04:42:01Yardanicowell, maybe I'll use it more with your changes, but anyway, the F6 in vscode is bound to "nim c -r file.nim" by default :P
04:42:02FromDiscord<impbox> I generally prefer using Makefiles to nimble, though I've been trying to force myself to use nimble instead... but most of the time makefiles do what I want better with less work
04:42:23FromDiscord<impbox> but if nimble could work as a nice cross-platform makefile that'd be rad
04:42:31Yardanicothat's nake :D
04:43:13FromDiscord<impbox> https://forum.nim-lang.org/t/3131#19708
04:43:18Yardanicoshashlick: so if I understood correctly, even if there's a custom "test" task defined, I can still pass --gc:arc with "nimble --gc:arc test" ?
04:43:45Yardanicoof course if that custom test tast is not too custom
04:43:46FromDiscord<impbox> according to dom nimble is supposed to obsolete nake
04:44:27FromDiscord<impbox> makes sense for nimble to not have to rely on external build tools
04:44:36Yardanicobecause since I did the pkgraph thing eariler, I might just go ahead and try "nimble test" with refc on each package in nimble
04:44:41Yardanicoand same for "nimble --gc:arc test"
04:44:44Yardanicoand see the difference :P
04:45:54Yardaniconeed to clone them again now though
04:47:22shashlickSo custom test task it won't work out of the box cause no idea how you will call Nim
04:47:35Yardanicoyeah that's what I meant
04:47:49shashlickYou can get the flags from commandLineParams and pass it manually
04:47:58YardanicoI guess I can check each .nimble file and see if it has a custom test task
04:48:00shashlickYep
04:48:03Yardanicoand only test packages without those
04:48:22shashlickOpen to feedback so let me know
04:48:32shashlickGotta bed, thanks for trying!
04:48:37Yardanicogood night
04:48:37FromDiscord<impbox> nini
04:50:47Yardanicogit go brr https://i.imgur.com/fqckqxZ.png
04:51:04bungam confusing , the httpclient.nim if Content-Length present it will call client.close ,shoudn't check Connection header before?
04:51:55FromDiscord<Varriount> Yardanico: what are you doing to your poor computer?
04:52:02Yardanico@Varriount well this is the third time
04:52:10Yardanicoit's the pkgraph thing I have to clone all packages from nimble
04:52:16Yardanicobut this time I'm doing it to test packages with arc
04:52:26Yardanicoit's already done btw
04:52:36Yardanico1339 folders of 2.9gb total size
04:52:43Yardanico(I pulled with --depth 1 of course)
04:52:46*maier joined #nim
04:52:49FromDiscord<Varriount> bung: What information is in the Connection header?
04:53:18bungclose or keep-alive
04:55:15bungalso recvFull calls client.close after no more data
04:55:26*narimiran joined #nim
04:57:03Yardanicoso I guess I should try to test packages only if they're with a .nimble file (not .babel) and don't contain "task test"
04:57:56*njoseph quit (Quit: http://quassel-irc.org - Chat comfortably. Anywhere.)
04:58:04*njoseph joined #nim
04:58:33Yardanicoseems like 248 packages have a "task test," in .nimble
04:58:36Yardanicothat's excluding treesitter
05:00:35FromDiscord<Varriount> If I recall, Keep-Alive is a suggestion, not something that has to be followed.
05:02:42FromGitter<bung87> that's more weird , if no content length present it will check connection header
05:04:05*Tongir quit (Ping timeout: 240 seconds)
05:05:33FromGitter<bung87> does content length related to connection? I dont think so
05:11:14Yardanicomwamhahaha
05:11:19Yardanicohttps://i.imgur.com/mDv3LlA.png
05:11:34*solitudesf joined #nim
05:11:59Yardanicohm why failed though
05:12:44Yardanicoah typo
05:13:26Yardanicodamn there are "trap" tests though :P
05:13:31Yardanicolike "nio" - has a test which runs forever
05:13:36Yardanicobasically serves a hello world page forever
05:15:41Yardanicohttps://i.imgur.com/d5kVhsK.png
05:17:27Yardanicoi don't really care if something fails, I would mostly care about refc vs arc difference
05:19:38Yardanicoimap package does the same (serves an imap client forever)
05:24:31*Tongir joined #nim
05:25:12Yardanicolol I got spooked
05:25:19Yardanico"openal" test played a small sound :P
05:26:11YardanicoI'm just running all of this with refc first, then I'll run it with arc and do a simple
05:26:17Yardanico"diff passed_refc passed_arc"
05:26:27Yardanicoalthough I don't yet handle nimble deps :P
05:27:54Zevvdisruptek: I have new insights again about stack frames en envs, but I'm not sure if you even want to know all that
05:36:58Yardanicolol
05:37:02Yardaniconow slappy is playing music for me
05:37:07Yardanicowhile testing it XD
05:37:26Yardanicosome nice melodies though
05:37:46Yardanico"ascension_short_by_ross_bugden.ogg"
06:10:56*sunwukong joined #nim
06:12:46*letto quit (Quit: Konversation terminated!)
06:14:45*letto joined #nim
06:16:45Zevvdisruptek: good work, we're only 6 times slower then closure iterators!
06:20:12ZevvI love your solution btw. when declaredInScope. It's pretty out-of-the-box
06:28:35*nature joined #nim
06:31:40Yardanicolol https://i.imgur.com/OgJdker.png
06:31:57Zevv?
06:31:57Yardaniconmi package
06:32:03Yardanicothat's the test output
06:32:11YardanicoI want to test quite a lot of nimble packages with arc and refc
06:32:14Yardanicoto find failing ones
06:32:34Yardanicohttps://github.com/jiro4989/nmi
06:32:35Zevvthe fun :
06:32:37narimiranYardanico: you know about the recent work from shashlick regarding `nimble test`?
06:32:40Yardanicoyes
06:32:44Yardanicothat's why I'm doing this
06:32:53narimiran:thumb_up:
06:33:06Yardanicoin the end I'll just run "diff passed_refc passed_arc"
06:33:11Yardanicoand manually re-check the difference
06:33:17Zevvgood work dude
06:33:24Yardanicoah shoot
06:33:27Yardanicoshould've chosen orc
06:33:33Yardanicobut it's too late :P
06:40:03ZevvI just filed a bug report on nmi
06:40:06Zevvit's broken
06:40:08Yardanicowdym
06:40:20ZevvI can interrupt with ^C
06:40:28Yardanicoyeah thats bad
07:00:30YardanicoI didn't finish the tests with arc, but already saw a few SIGSEGVs
07:00:56Yardanicoso
07:01:10Yardanicois "swap" with arc supposed to work for a case like "swap(result[i], result[j])" ?
07:01:17Yardanicowhere result is a string
07:03:07Yardanicohttps://github.com/jabbalaci/nimpykot/blob/master/src/pykot/strings.nim#L60
07:15:18Yardaniconbaser, sequtils2, combparser, protobuf, macroutils (know about this one),. parsetoml (deepCopy, know about this one), fftw3 (arraymancer), rbtree (know about this one), ptrace, bencode, markdown (know about this one, reported already), cassette, ad, negamax, pykot, edn, nimfm, shared, envconfig, kdb, nimly (know about this one), tim_sort (know about this one, already reported)
07:15:21Yardanicowill check them manually
07:15:42Yardanicowell there's probably more, I only tested the ones without a test task in .nimble
07:17:50Zevvwell, you could ask your tests to their nimble files, right? :)
07:17:58Yardanico?
07:18:06Yardanicowell yes, but that's manual work
07:18:14Yardanicobecause people structure their manual test tasks differently
07:19:54*Zectbumo joined #nim
07:20:21Yardanicooh the nbaser one is an interesting one
07:20:24Yardanicoit checks if an exception was raised
07:20:28*circ-user-e44p4 joined #nim
07:20:32Yardanicoand it is raised, but last char in the exceptioon message is stripped
07:20:37Zevvsure just trolling
07:20:40Yardanicoso the assertion fails
07:20:55ZevvI do the trolling when disruptek is at sleep
07:22:19*Zectbumo quit (Remote host closed the connection)
07:22:25*circ-user-e44p4 is now known as Zectbumo
07:28:02Yardanicofunny bug lol
07:31:05Yardanicooh not really funny
07:31:16Yardanicoit just relies on "repr" which is implementation-specific and behaves differently for arc :)
07:31:52Yardanicoit relies on the fact that there's address with @ before the repr'd seq itself
07:38:49*NimBot joined #nim
07:39:54Yardanicohttps://github.com/D-Nice/nbaser/issues/6
07:39:57disbotARC compatibility ; snippet at 12https://play.nim-lang.org/#ix=2szV
07:41:14Yardanicooh well, sequtils2 fails because there's no deepCopy for arc
07:42:08Yardanicoif I replace it with just "sCopy = s", everything works
07:42:22YardanicoI suppose the author made it that way so the "unique" proc (that's where that deepCopy is) returned new data?
07:42:40Yardaniconot sure why though
07:42:50Yardanicowe already have a deduplicate proc in stdlibn
07:52:04Yardanicoin combparser I get a SIGSEGV
07:52:07Yardaniconoice
07:53:48bungnim repos github ci pkg:1 pkg:2 what'S the differiences ?
07:53:53Yardanicobung: batching
07:54:03Yardanicofor faster CI full important package list is separated into two
07:54:12Yardanicowhich are tested in parallel so it's twice as fast :)
07:54:57bungthat's great idea!
07:55:04Yardanicobung: see https://github.com/nim-lang/Nim/blob/devel/testament/important_packages.nim
07:55:09Yardanicopkg1 and pkg2
08:11:46Yardanicothe combparser one seems like a closure arc bug
08:13:46Yardanico1.0.8 soon yay
08:14:20narimiranYardanico: spoiler alert!
08:14:26Yardanicowell I saw the commit :P
08:14:31narimiranssssh
08:14:37Yardanicohow2delet in irc
08:14:58narimiran:D
08:15:41Yardanicothis looks.. interesting https://i.imgur.com/ZT9LsMO.png
08:16:20Yardanicooh it actually fails earlier than here, maybe a cursorifier bug even
08:17:40*vicfred quit (Remote host closed the connection)
08:18:05*vicfred joined #nim
08:18:09Araqfixed the showstopper bug for 1.2.x already
08:18:25Yardanicowait which one?
08:18:33Araq#14616
08:18:35disbothttps://github.com/nim-lang/Nim/issues/14616 -- 3Constructing a uint64 range on a 32-bit machine leads to incorrect codegen ; snippet at 12https://play.nim-lang.org/#ix=2sA1
08:18:39Yardanicooh
08:24:57Yardanicowow, with -d:useMalloc I an interesting malloc error
08:24:58Yardanico"malloc(): unsorted double linked list corrupted"
08:25:07Yardanicoget*
08:25:49YardanicoI'll check if it's a cursor inference bug
08:26:52*synthmeat quit (Quit: WeeChat 2.9)
08:27:30Yardanicooh nice seems to be a cursorifier bug :)
08:27:43*synthmeat joined #nim
08:27:48*synthmeat quit (Client Quit)
08:28:08*synthmeat joined #nim
08:32:53Yardanicoand yeah, combparser seem to do some kind of traversal with assignments
08:35:46*Tlanger joined #nim
08:38:26*Tongir quit (Ping timeout: 265 seconds)
08:46:29*gangstacat quit (Quit: Ĝis!)
08:58:12*lritter quit (Quit: Leaving)
09:02:05FromGitter<bung87> Yardanico when your pkg graph things done , it will seperate pkgs from pkg1-n automatically ?
09:02:13Yardanicowdym?
09:02:27YardanicoIf you mean about testing with arc - I don't take packages from important packages, no
09:02:38YardanicoI parse packages.json from nimble and clone ALL repos
09:02:47YardanicoI did the same to make graphs of all nimble packages
09:02:51FromGitter<bung87> I mean important_packages.nim manually edit
09:03:02Yardanicowell for that I just edited it
09:03:06Yardanicoi didn't change pkg1 and pkg2
09:03:09Yardanicoand then manually ran it
09:03:17FromGitter<bung87> with graph can be automatically
09:03:25Yardanicowdym?
09:03:42Yardanicoit's ./koch tests c nimble-packages-1
09:03:46Yardanicoand ./koch tests c nimble-packages-2
09:03:55Yardanicothat's what I mean by "manual"
09:04:31FromGitter<bung87> analyze the dependencies seperate it to n packages test , that would be even faster I think
09:05:10Yardanicothat wouldn't help me
09:05:21Yardanicofor arc testing which I did today I tested all packages from nimble
09:05:24Yardanicowith my own small nim program
09:05:28Yardanicoand with nimble test
09:06:37YardanicoAraq: this time I managed to make a much much simpler repro for (not sure if the same) cursor inference bug from combparser lib
09:06:50Yardanicohttps://gist.github.com/Yardanico/0769304d711d106989276eccec54d750
09:06:56FromGitter<bung87> you take so much energy into arg things
09:07:45FromGitter<bung87> arc
09:07:57YardanicoI'm just spending my free time on something useful to other people :P
09:10:51FromGitter<bung87> that's cool
09:15:41alehander92https://blog.repl.it/langjam
09:15:55alehander92i am wondering if I should try
09:16:02Yardanicohttps://github.com/nim-lang/Nim/issues/15110
09:16:04disbot[ARC] SIGSEGV caused by cursor inference with a case object ; snippet at 12https://play.nim-lang.org/#ix=2sAc
09:16:40alehander92does someone else have an idea? repl.it supports nim (if i do it alone, i'd probably try haskell tho)
09:18:40Yardanicooh seems like rresult is getting destroyed inside the if
09:19:08Yardanicobut then a cursor to rresult.errors is being assigned into the error object
09:19:13Yardanicoboom
09:31:01FromDiscord<Clyybber> Araq: Currently evalTempl only takes the ConfigRef as an arg and not the whole PContext (its getting called in the VM too, where there is no PContext)
09:31:25FromDiscord<Clyybber> Should I maybe use the procInstCache for storing the counter?
09:31:30FromDiscord<Clyybber> Or the ConfigRef?
09:33:55FromDiscord<kodkuce> dumb question, so duno if i should use websockts or pure POST , i need to update data aprox evry 5 seconds
09:34:10Yardanicouse UPDATE :P
09:34:21Yardanicoah sorry that doesn't exist
09:34:27alehander92every 5 seconds doesn't seem so often
09:34:30alehander92there is PATCH
09:34:31alehander92iirc
09:34:32Yardanicooh
09:34:38Yardanicoyeah you're right
09:34:44Yardanico"The HTTP PATCH request method applies partial modifications to a resource."
09:34:54alehander92and PUT
09:34:58alehander92but PATCH sounds better
09:35:01Yardanicowell PUT is a bit different than PATCH
09:35:10Yardanicoif we're talking about updating :P
09:35:17Yardanico@kodkuce just use http(s)
09:35:18alehander92yeah!
09:35:27alehander92but best to check the REST guidelines
09:35:57alehander92i mean websockets won't hurt but i think rest might be fine
09:36:01alehander92for once in 5 seconds
09:36:29alehander92i honestly think of chats/games when i think sockets
09:36:36alehander92or maybe maps
09:37:34FromDiscord<kodkuce> i am making a dumb matchmaking server, so my GameInstances need to send to matchmaking serwer when they are free so can run new game
09:38:11FromDiscord<kodkuce> and serwer send them Hi GI, here this 2 player want to play 🙂
09:38:20*jklhyd[m] joined #nim
09:39:44FromDiscord<kodkuce> and then send to players this is IP/port to join your game, for players i am using websockts, tough now when i think i could use http too
09:41:08FromDiscord<kodkuce> only reason i end up using webscokets for MM to Players is to keep count of atm players, but now when i think it can just read it from atm GI
09:41:24*nikita` joined #nim
09:41:24*nikita` quit (Changing host)
09:41:24*nikita` joined #nim
09:41:28FromDiscord<kodkuce> now am thinking of removing all websockts for MM serwer
09:44:23Yardanicowhat are you using for the game itself?
09:44:26YardanicoI mean for networking
09:45:18FromDiscord<kodkuce> websockets cuz am making a dumb game to dip into multyplayer, next time will try webrtc
09:45:26Yardanicowhy not just use websockets for everything?
09:45:31Yardanicofor MM and for the game itself then
09:45:36Yardanicoreusing same connection :P
09:47:56FromDiscord<kodkuce> cuz i am tard ofc, i want to make it scalable for some unknow reason so i have 1 app(process) AuthRegSerwer(JWT), 1app MatchmakingServer, and then 10 GameInstanceServer, so i kinda cant reuse same connection 😛
09:48:04FromDiscord<kodkuce> (edit) '😛' => '😦'
09:48:42FromDiscord<kodkuce> in reality i could have put all that in just one executable
09:49:05FromDiscord<kodkuce> especialy cuz this game is tarded
09:50:37FromDiscord<Rika> isnt that even less scalable if you dont reuse resources
09:50:59Yardanicowell it's "scalable" as in
09:51:04Yardanicoyou can put these 3 to different servers
09:51:10ZevvI love your solution btw. when declaredInScope. It's pretty out-of-the-box
09:51:10Yardanicoto different locations, etc
09:51:54FromDiscord<dom96> I had to solve the same problem for Stardust
09:52:22FromDiscord<Rika> ah you mean microservice'd
09:52:42FromDiscord<dom96> The service that routes players to free servers simply polls each game server's /game/stats page, for example https://nyc1.stardust.dev/game/stats
09:54:44FromDiscord<Rika> sounds slow-ish but it probably isnt slow enough to be annoying
09:56:18*Zectbumo quit (Remote host closed the connection)
09:57:02FromDiscord<dom96> Maybe but what you really want to optimise if the routing
09:57:07FromDiscord<kodkuce> but this way when i have 50bilion players, i can just buy 10 servers , 1 hosting 1000auth executables, 1 hosting 1000MMs, and 8 hosting 10000GameInsances 🙂
09:57:09FromDiscord<dom96> (edit) 'if' => 'is'
09:57:53FromDiscord<dom96> How are you going to get more players than people in the world? lol
09:58:05FromDiscord<Rika> its a joke i assume
09:58:22FromDiscord<Rika> or probably the long million vs short million problem
09:58:47FromDiscord<kodkuce> i give evry player 50credits if he makes kid and gives him to play my game
09:58:56alehander92wow
09:59:08alehander92i'd like population increase
09:59:12Yardanicono
09:59:16alehander92but i never expected scaling games to help
09:59:31FromDiscord<kodkuce> after that i start brainwashing them all with inserted clips like from The Fight Club 🙂
09:59:42FromDiscord<kodkuce> easy world domination
10:00:17alehander92*feels uneasy and secures west border*
10:00:37FromDiscord<Clyybber> why would you want population increase?
10:00:54Yardanicoexactly
10:00:57Yardanicowe don't need that really :P
10:00:59FromDiscord<kodkuce> to create criticall mass so they can implode
10:01:03alehander92well, bulgaria is like very high in the shrinking population charts
10:01:33FromDiscord<kodkuce> we need new oil reserves to be created from some bodys
10:01:42alehander92and we're such cool people that it would be a shame for you to lose us
10:02:09FromDiscord<kodkuce> evrybody ho has score ower 10000 is alowed to survive
10:02:32alehander92kodkuce man, people would go to the army just to chill from playing the game
10:03:08alehander92btw i read about galaxija
10:03:15alehander92these days
10:03:26alehander92seems as a cool tech, is it known there
10:03:30FromDiscord<kodkuce> 10000score = natrual selection, i brinwash you all
10:03:48alehander92https://news.ycombinator.com/item?id=23971814
10:03:54alehander92(the article is actually ok)
10:04:35alehander92i like error handling
10:04:55alehander92Owing to this restriction, the system could only display three splendidly playful one-word error messages: users received a “WHAT?” if their BASIC code had a syntax error, a “HOW?” if their requested input was unrecognizable, and a “SORRY” if the machine exceeded its memory capacity.
10:04:58FromDiscord<kodkuce> nice i can use this to securly store all monerocoins i got mined by my brainwashed addicts
10:05:03alehander92(quote from the article)
10:05:17alehander92let's add such a mode for nim errors
10:06:42*gangstacat joined #nim
10:08:27*Vladar joined #nim
10:20:20FromDiscord<lqdev> is there a more efficient alternative to `card(b - a) > 0` for HashSets?
10:20:35Yardanicocheck if they have difference?
10:20:45FromDiscord<lqdev> no
10:20:56FromDiscord<lqdev> i need to check if set `a` contains all elements from `b`
10:21:00Yardanicoah
10:22:53*waleee-cl joined #nim
10:33:51*antranigv quit (Quit: ZNC 1.7.5 - https://znc.in)
10:34:03FromDiscord<exelotl> @alehander92 lol, reminds me of the 'PLEASE' keyword from intercal
10:34:16*antranigv joined #nim
10:35:11narimiran@lqdev `card(b -a)` won't check that
10:36:25*sunwukong quit (Ping timeout: 240 seconds)
10:38:07narimiran@lqdev see this example for the fail in the logic: https://play.nim-lang.org/#ix=2sAv
10:41:19FromDiscord<lqdev> hm
10:41:38FromGitter<bung87> Araq how can I know where the empty array reach , Traceback doesn't show sigmatch
10:41:51Yardanicobecause traceback is only the end
10:42:11Yardanicoit's only the direct traceback, not "what happened before"
10:42:18Yardanicoyou can try with some echoes and stuff :)
10:42:23FromDiscord<lqdev> well, the thing is I have a set of required components. eg. `Position, Size` and a set of specified components, eg. `Position, Size, PhysicsBody`, and I need to check whether the set of specified components contains all of the required components
10:42:38Yardanicoyou can try echoing stuff which gets passed to sigmatch.nim concreteType
10:42:58FromGitter<bung87> but echo in there too much outputs
10:43:07Yardanicosee https://nim-lang.org/docs/intern.html
10:43:14Yardanicoespecially https://nim-lang.org/docs/intern.html#debugging-the-compiler
10:43:21Yardanicoyou can check if a node comes from specific nim file
10:43:33FromDiscord<lqdev> cc narimiran
10:43:35FromDiscord<lqdev> and
10:43:46FromDiscord<lqdev> if all the components aren't present, raise an error
10:44:17FromDiscord<lqdev> and that's effectively what `card(b - a)` does, it gives you the number of components that aren't in `a` but are in `b`
10:44:36FromDiscord<lqdev> so if that number > 0, there are some unimplemented components so I raise an error
10:47:23narimiran@lqdev, there is `<` to compare if one set is a subset of the other: https://play.nim-lang.org/#ix=2sAA
10:47:57FromDiscord<lqdev> yeah I saw that, but there's a problem
10:48:02FromDiscord<lqdev> > A strict or proper subset s has all of its members in t but t has more elements than s.
10:48:17FromDiscord<lqdev> in my case `t` doesn't necessarily have to have more elements than `s`
10:48:49FromDiscord<lqdev> nothing prevents you from adding just one system which requires a single component, and only implementing that single component
10:49:28*audiofile joined #nim
10:50:40narimiranthere is `<=` also
10:51:08FromDiscord<lqdev> `>=` doesn't do the thing I need though
10:52:03narimiranwhat do you need? don't you want to check if all the elements of one set are in the other?
10:52:12FromDiscord<lqdev> yeah *all* of them
10:52:32narimiranand how come `<=` doesn't do that for you?
10:52:57FromDiscord<lqdev> maybe I'm just misunderstanding
10:53:21narimiranif you want to check if all elements of `x` are in `y`, you need to do `x <= y`
10:53:34FromDiscord<lqdev> but somehow it doesn't work for me
10:53:51FromDiscord<lqdev> so for example
10:53:52narimiranyou sure you use `<=` and not `>=`? (as you've written above)
10:53:58FromDiscord<lqdev> yes it's <=
10:54:25FromDiscord<lqdev> `x = {Position, PhysicsBody}` and `y = {Size, PhysicsBody, Gravity}`. `x <= y` returns true for some reason
10:54:44FromDiscord<lqdev> wait no
10:54:57narimiran:)
10:55:13FromDiscord<lqdev> ok i think i got it
10:55:19FromDiscord<lqdev> forgot a `not` there
10:55:27FromDiscord<lqdev> damn my brain is on airplane mode today
10:56:20bunghmm, give up
10:59:09alehander92we don't give up
11:01:12FromDiscord<Clyybber> Araq: ping
11:01:22Yardanicomarco polo
11:01:39FromGitter<bung87> it's slow for compile compiler then compile file that only echo variable or modify one line
11:02:07*abm joined #nim
11:02:07Yardanicowell depends on your hardware really
11:02:13Yardanicoyou use ./koch temp c right ?
11:02:24alehander92we need IC for that
11:02:32Yardanicoand btw, it's still miles better than for most of other languages :)
11:02:35alehander92we can't all buy gaming hardware
11:02:58FromGitter<bung87> no comoilrr/nim c comoiler/nim.nim
11:03:04Yardanicodon't do that
11:03:09Yardanicoor at least add -d:leanCompiler
11:03:14Yardanicobut really you should use ./koch temp
11:03:57FromGitter<bung87> koch temo some time use old code
11:04:04Yardanicoit never does that for me lol
11:04:09Yardanicomaybe you forgot ctrl+s?
11:04:18Yardanicoor try removing the "nimcache" dir
11:04:24Yardanicoin the base directory of the nim repo
11:05:20FromDiscord<Clyybber> bung87: Oh, you probably have your compiler built with koch boot right?
11:05:37FromDiscord<Clyybber> koch temp times will go down drastically after you did a ./koch boot -d:danger
11:05:55Yardanicowow, ref int :P
11:06:12FromGitter<bung87> yes, that i did old time
11:06:59FromGitter<bung87> ./compiler/nim c ./compiler/nim.nim is only constant right way for me
11:07:08Yardanicothat's very slow
11:07:17Yardanicobecause you're using the nim compiler built in FULL debug mode
11:07:32Yardanicoyou should at least do something like
11:07:52Yardanicowell, just really, why koch doesn't work for you?
11:08:22FromDiscord<Clyybber> bung87: If you want to force koch temp to recompile you can just pass -f along
11:08:24FromGitter<bung87> maybe like Clyybber said
11:08:26FromDiscord<Clyybber> so ./koch temp -f
11:08:44FromDiscord<Clyybber> bung87: Yeah, its much better after you ran ./koch boot -d:danger
11:09:07FromDiscord<Clyybber> Yardanico: Yeah ref int :p
11:09:13Yardanicohehe
11:09:26Yardanicoit's been never used in the compiler it seems :P
11:09:30Yardanicobefore
11:09:30FromDiscord<Clyybber> Nope
11:09:47YardanicoI mean I understand why you would want it in your case
11:09:55Yardanicoto not add another argument to a lot of procs I guess
11:10:33FromDiscord<Clyybber> yeah, and also because I need it to be shared accross the contexts
11:10:59FromGitter<bung87> ok , I'll try pick some lib's issues, that make me forgot compiler things
11:11:47alehander92ok
11:12:01Yardanicoyou can always improve nim's ecosystem :P
11:12:06Yardanicohttps://github.com/nim-lang/needed-libraries/issues\
11:12:08Yardanicohttps://github.com/nim-lang/needed-libraries/issues
11:13:05*endragor quit (Remote host closed the connection)
11:13:33*endragor joined #nim
11:13:51bungyeah, I read that multiple times
11:14:56bungI have 4 pendding PR in nim repo now
11:16:58*vicfred quit (Quit: Leaving)
11:19:04*endragor quit (Remote host closed the connection)
11:19:15*endragor joined #nim
11:21:03*endragor quit (Remote host closed the connection)
11:21:09*sunwukong joined #nim
11:21:31*endragor joined #nim
11:24:46FromDiscord<Varriount> I use `koch boot -d:release --stacktrace:on --linetrace:on`
11:25:40FromDiscord<Varriount> Bah, why must you open to message from 5 minutes ago Discord
11:26:07Yardanicoi use ./koch boot -d:danger :)
11:26:12Yardanicowhen I hit crashes I can always do koch temp
11:26:16Yardanicoand I want speed go brrr
11:26:46*endragor quit (Ping timeout: 246 seconds)
11:29:11*drdee joined #nim
11:32:00FromDiscord<lqdev> can somebody explain to me why does `typeDesc[T]` exist
11:32:08Yardanicoto represent types
11:32:09FromDiscord<lqdev> when you pass a type to a macro
11:32:21FromDiscord<lqdev> why not just get the symbol that refers to the type
11:32:23Yardanicoyou need to have a type to represent a type :)
11:32:31Yardanicobecause typedesc isn't exclusive to macros
11:33:13FromDiscord<lqdev> painful.
11:33:32FromDiscord<lqdev> typeDesc[T] makes dealing with types in macros 100x harder than it needs to be
11:33:34FromDiscord<lqdev> change my mind
11:33:39Yardanicodoes it?
11:33:52FromDiscord<lqdev> oh trust me, it does.
11:34:00FromDiscord<lqdev> every type you get—you have to strip the typedesc off of it.
11:34:19FromDiscord<lqdev> i already made an `obliterateTypedesc` proc to deal with it, but it's not ideal.
11:35:01FromDiscord<lqdev> just because `typedesc[T]` exists, using `sameType` to directly compare two types you get passed via arguments is not possible
11:35:26FromDiscord<lqdev> because as far as `sameType` is concerned, `typedesc is typedesc`.
11:35:34FromDiscord<Clyybber> Araq: Can we remove optNimV019 by now?
11:35:47Yardanicoehm how do you pass types to a macro @lqdev ?
11:35:55Yardanicoi'm confused because if I pass something untyped, it's just ident
11:35:58Yardanicoif typed, it's a sym
11:35:58FromDiscord<lqdev> Yardanico: via `typed`?
11:36:26FromDiscord<lqdev> it's a sym, but calling `sameType(a, b)` on two typed params `a` and `b` will always yield `true` :)
11:36:30Yardanicoeven when importing the type from another module
11:36:47FromDiscord<lqdev> you have to work around it: `sameType(a.getImpl[1], b.getImpl[1]`
11:36:48Araqclyybber: yes
11:37:40Araqlqdev: I have an unwritten RFC regarding typedesc and static T
11:37:59FromDiscord<lqdev> Araq: what is it about?
11:38:11Araqfixing them for good
11:38:34FromDiscord<lqdev> nice
11:41:41Araqso ... I heard you all want me to fix my cursor inference optimization
11:41:54Yardanicoit's only me for now :P
11:44:00FromGitter<sealmove> hey guys, how do I delete nim cache? I don't know exactly what I am talking about but I have a program that reads files from a folder and when I add a file it should crash, but it doesn't because it has the previous run cached and doesn't notice the added file.
11:44:17Yardanicoyou can force the compiler to do full recompile with "-f"
11:44:22FromGitter<sealmove> nice, thanks
11:44:23Yardanicoand cache on linux is by default in ~/.cache/nim
11:44:30Yardanicoon *nix
11:44:52*drdee quit (Quit: Leaving)
11:45:01FromDiscord<lqdev> and on windows it's in C:/Users/<user>/nimcache
11:45:07Yardanicooh really
11:45:09FromGitter<sealmove> -f works
11:51:28*vicfred joined #nim
11:53:37*narimiran quit (Ping timeout: 264 seconds)
11:55:03*endragor joined #nim
11:55:23*tane joined #nim
11:56:32Yardanico@Clyybber should swap work for chars in strings?
11:56:39YardanicoI've had one package fail because of that
11:56:40Yardanicowith arc
11:57:17Araqit should work
11:57:26Yardanicoah I know why it fails
11:57:29Yardanicobecause of static arc strings :P
11:57:46Yardanicoif you do "stdin.readLine()" it works with arc
11:58:37FromDiscord<Clyybber> ah, good catch
11:59:19*endragor quit (Ping timeout: 246 seconds)
11:59:29Yardanicojust made an issue so we get more closed issues :P https://github.com/nim-lang/Nim/issues/15112
11:59:31disbot[ARC] SIGSEGV when trying to swap in a literal/const string ; snippet at 12https://play.nim-lang.org/#ix=2sB5
12:00:28FromDiscord<Clyybber> Araq: #15091 is ready, I had to share the counter with the VM because getAst does template expansion.
12:00:29disbothttps://github.com/nim-lang/Nim/pull/15091 -- 3Fix forward declaration issues in template/macro context
12:05:39Yardanicowow I didn't know we had term-rewriting macros in system
12:06:02*supakeen quit (Quit: WeeChat 2.8)
12:06:13Yardanicoonly one seems like
12:06:45*supakeen joined #nim
12:09:44FromDiscord<Clyybber> huh, that is a pretty cool one
12:10:04Yardanicoyeah "swapRefsInArray"
12:10:07Yardaniconot sure if it's needed with arc though
12:11:23Yardanicoah it's not activated
12:11:44Yardanicohttps://github.com/nim-lang/Nim/commit/94a9688556ca3b26a28d41319eaa14ae55b9d9d7
12:15:50*rockcavera joined #nim
12:21:44*krux02 joined #nim
12:25:20FromDiscord<Yardanico> By the way, what's the tool used to generate closed issues list? I mean in blog posts about new Nim versions
13:01:54FromDiscord<lqdev> what's nnkLambda used for?
13:02:12FromDiscord<lqdev> internal stuff, i guess?
13:05:44*aosync joined #nim
13:11:28*aosync quit (Quit: leaving)
13:17:19*bacterio quit (Ping timeout: 265 seconds)
13:17:33*thomasross joined #nim
13:20:31*dulsi_ joined #nim
13:22:58*dulsi quit (Ping timeout: 246 seconds)
13:27:26FromDiscord<lqdev> where can i find nim artwork (official logos)?
13:27:29*bacterio joined #nim
13:27:51FromDiscord<dom96> nim-lang/assets on github
13:28:05FromDiscord<lqdev> ah
13:28:39FromDiscord<Clyybber> @lqdev lambdas obviously :p
13:29:04FromDiscord<lqdev> @Clyybber well, but the AST for `proc () =` uses nnkProcDef and not nnkLambda
13:29:15FromDiscord<lqdev> `a do ():` uses nnkDo
13:29:45FromDiscord<Clyybber> nnkLambda is used in the parser stage
13:30:12FromDiscord<lqdev> right. so macros basically don't get to see it?
13:30:25FromDiscord<Clyybber> yep
13:30:47FromDiscord<Clyybber> oh actually
13:31:11FromDiscord<Clyybber> hmm, I'm not sure, as there is logic in the compiler that checks for its presence in later stages
13:47:23*lbart quit (Ping timeout: 240 seconds)
13:55:23*thomasross quit (Ping timeout: 240 seconds)
14:10:24FromDiscord<Clyybber> Araq: ping https://github.com/nim-lang/Nim/pull/15091 :)
14:10:25disbotFix forward declaration issues in template/macro context
14:13:39ZevvClyybber: is that ours?
14:14:59AraqClyybber: do you read this ID from anywhere?
14:15:02Araqdon't see it
14:15:10FromDiscord<Clyybber> yeah, in evaltempl
14:15:20FromDiscord<Clyybber> Zevv: Yes
14:15:38FromDiscord<Clyybber> Araq: https://github.com/nim-lang/Nim/pull/15091/files#diff-3ce95e3c7c0e557b0078aa72313b6a7eL183
14:15:40disbotFix forward declaration issues in template/macro context
14:15:58FromDiscord<Clyybber> And use it there https://github.com/nim-lang/Nim/pull/15091/files#diff-3ce95e3c7c0e557b0078aa72313b6a7eL57
14:16:00disbotFix forward declaration issues in template/macro context
14:16:20FromDiscord<Clyybber> And after the evaluation is done I increment it here: https://github.com/nim-lang/Nim/pull/15091/files#diff-3ce95e3c7c0e557b0078aa72313b6a7eR209
14:16:22disbotFix forward declaration issues in template/macro context
14:16:47AraqI was looking for line 58 but ok
14:16:51Araqnow I got it
14:17:09Araqlooks clean enough and all tests are green, merging
14:17:48FromDiscord<Clyybber> nice
14:22:43ZevvClyybber \o/ Was it a though one?
14:23:29FromDiscord<Clyybber> the searching and the early fixes yeah
14:23:40FromDiscord<Clyybber> but then it mostly boiled down to two changes
14:23:59Zevvcool
14:24:00FromDiscord<Clyybber> one is making the compiler detect when the definitions own symbol is shared with the forward decl
14:24:24disruptekhmm we should fix that.
14:24:32FromDiscord<Clyybber> and the other is making the gensym hashes consistent for each template invocation
14:25:27Zevvright'o. Currently fixing something for work, but will check after dinner if I throw out my workaround
14:26:08FromDiscord<Clyybber> disruptek: Do we depend on devel?
14:26:30FromDiscord<Clyybber> As in, can I push the commit that removes the workaround
14:26:37ZevvI think we need 1.3.5 I saw somwehere
14:26:55FromDiscord<Clyybber> 1.4 is going to be released soon TM so I think its fair to depend on devel
14:27:00FromDiscord<Clyybber> for now
14:27:06Zevvcool.
14:27:21FromDiscord<Clyybber> oh this was just my opinion, disruptek has to decide
14:28:28FromDiscord<Clyybber> oh wait, 1.3 is devel
14:28:32FromDiscord<Clyybber> so yeah, lets go I guess
14:31:45FromDiscord<7815> sent a code paste, see https://play.nim-lang.org/#ix=2sBJ
14:31:52FromDiscord<7815> what do you guys think of this?
14:32:54*lbart joined #nim
14:32:54*lbart quit (Changing host)
14:32:54*lbart joined #nim
14:44:04FromDiscord<Clyybber> Zevv: Can you retest #3 ? I adapted your testcase to {.cps: Cont.} , but get undeclared identifier errors
14:46:14FromDiscord<Clyybber> @7815 dunno, seems to be very old. I think they *do* cause a lot of maintenance effort, as can be seen by the crazy amount of work that goes into maintaining a linux distro, but OTOH its O(n) vs O(1)
14:46:29FromDiscord<Clyybber> in terms of consumption of hard drive space
14:47:05FromDiscord<7815> @Clyybber why do i get ridiculed when i try to statically compile anything in nim q-q
14:47:24FromDiscord<Clyybber> who ridicules you?
14:47:51FromDiscord<Rika> statically compiling is great tho??
14:47:52FromDiscord<Clyybber> (edit) 'who ridicules you?' => 'why would you get ridiculed for that?'
14:47:54FromDiscord<Clyybber> yeah
14:51:41FromDiscord<Clyybber> @7815 what problems are you encountering?
14:52:36FromDiscord<7815> i don't remember anymore
14:52:37*icyphox_ joined #nim
14:52:43FromDiscord<7815> i tried nim about half a year ago
14:53:21FromDiscord<7815> i'll hang my footsies in again when the native compiler starts emerging @Clyybber
14:53:47Araqstatic linking for *everything* is foolish.
14:53:49FromDiscord<Clyybber> wdym native compiler?
14:54:35FromDiscord<Clyybber> @7815 wdym native compiler?
14:54:43Araqproof: you don't link the kernel statically into your program.
14:54:50*ryanhowe joined #nim
14:55:03FromDiscord<Clyybber> Araq: Heh, you are gonna love includeOS
14:55:18Araqyeah actually I do.
14:55:52Araqbut if you target an existing traditional OS dynamic linking is fine
14:57:23Araqclyybber: I think he means nlvm because "no C transpiler please"
14:57:55FromDiscord<Clyybber> ah I see
14:58:13FromDiscord<lqdev> *rika triggered*
14:58:15*icyphox quit (Quit: catch you on the flipside :^))
14:58:15*sacredfrog quit (Remote host closed the connection)
14:58:15*snowolf quit (Remote host closed the connection)
14:58:16*snowolf joined #nim
14:58:16*snowolf quit (Changing host)
14:58:16*snowolf joined #nim
15:00:30*icyphox_ is now known as icyphox
15:01:10FromDiscord<Rika> araq makes a good point
15:01:18FromDiscord<Rika> ah fuck, forgot how pinging worked in irc
15:05:11*xet7 quit (Quit: Leaving)
15:05:25FromDiscord<7815> araq, i have no idea what you mean by linking the kernel statically into your program.
15:05:50Araqsee includeOS
15:13:18Araqbut I can expand my point a bit: say you want to use libiconv in your program. Now that's pretty basic functionality, some people think it's part of the operating system. So you do want to link dynamically against it because whether libiconv is really in your kernel space or not is an irrelevant implementation detail. you want to target a *platform*, not a pure kernel. the kernel should be as slim as possible for security reasons
15:13:48Araqbut the platform should have "batteries included"
15:16:09*superbia2 quit (Quit: WeeChat 2.9)
15:36:40*maier quit (Ping timeout: 246 seconds)
15:45:19*endragor joined #nim
15:45:19*endragor quit (Remote host closed the connection)
15:45:26*endragor joined #nim
15:53:20*sagax quit (Read error: Connection reset by peer)
15:58:37*sm2n joined #nim
16:03:53federico3...not to mention the plethora of other tools and components that are needed on the host and are not part of your application
16:12:39*waleee-cl quit (Quit: Connection closed for inactivity)
16:17:11*nature quit (Quit: WeeChat 2.9)
16:22:00FromDiscord<Clyybber> Araq: Does this patch make sense:
16:22:13FromDiscord<Clyybber> sent a code paste, see https://play.nim-lang.org/#ix=2sCp
16:23:03FromDiscord<Clyybber> sent a long message, see http://ix.io/2sCr
16:23:16FromDiscord<Clyybber> sent a long message, see http://ix.io/2sCs
16:25:23FromDiscord<Recruit_main707> the second example doesnt need `block:` only `block`
16:28:59FromDiscord<Clyybber> @Recruit_main707 No. `block` always needs a colon
16:30:42FromDiscord<Recruit_main707> then whats wrong?
16:31:10FromDiscord<Clyybber> The first example doesn't work.
16:31:30FromDiscord<Clyybber> I have a patch that makes it work, but I don't know if its correct.
16:37:55*bung_ joined #nim
16:40:54*bung quit (Ping timeout: 256 seconds)
16:44:05*nimmer joined #nim
16:44:30nimmerHI fellow Nim programmers,
16:44:46nimmeris there a simple way to check if a sequence in empty?
16:45:19nimmere.g. aSeq.isEmpty instead of len(aSeq) == 0
16:45:47FromDiscord<Clyybber> simply define your own isEmpty proc or template
16:46:18FromDiscord<Clyybber> checking the len is idiomatic
16:47:34nimmerok, thank you for your response. I just wanted to make sure I'm doing it the idiomatic way by using Nims build in procs/operators
16:48:34*oriba joined #nim
16:49:55Zevv!last disruptek
16:49:55disbotdisruptek never seen.
16:50:01Zevvha
16:51:31FromDiscord<Idefau> lemme check
16:51:48FromDiscord<Idefau> sorry wrong chat
16:51:54FromDiscord<Rika> 👀
16:53:14FromDiscord<Clyybber> !last Araq
16:53:14disbotAraq spoke in 12#nim 99 minutes ago 12https://irclogs.nim-lang.org/29-07-2020.html#15:13:48
16:56:30FromDiscord<Rika> disbot: "who's disruptek? ive never met that man in my life"
16:57:29*nimmer quit (Quit: Connection closed)
16:58:35*vicfred quit (Quit: Leaving)
17:19:01rockcaveraWouldn't it be correct to print int? https://play.nim-lang.org/#ix=2sCL
17:20:21FromDiscord<Rika> i think its related to `-` being a proc
17:20:35FromGitter<deech> How do ast-dump the result of an evaluation? eg. `let x = @[1,2,3]; dumpTree(x)`, will print the ast of `x` not `@[1,2,3]`.
17:21:29FromDiscord<Rika> .repr?
17:21:38FromDiscord<Rika> uh
17:21:38FromDiscord<Rika> wait
17:21:51*Tlanger quit (Remote host closed the connection)
17:22:07Zevvdeech: wait :)
17:22:11*Tlanger joined #nim
17:22:19ZevvNothing has been evaluated
17:22:21Zevvthere is only AST
17:24:41FromDiscord<Rika> yeah, i dont really understand
17:24:56FromDiscord<lqdev> @deech https://play.nim-lang.org/#ix=2sCO
17:29:19FromGitter<deech> Ah hah, I was missing `getImpl`. :)
17:30:00FromDiscord<lqdev> keep in mind it only works on `typed` AST!
17:33:18*maier joined #nim
17:35:25*sunwukong quit (Ping timeout: 240 seconds)
17:35:54Zevv"I have no internet". Sound more like "I don't feel like listening to Zevvs talk all afternoon"
17:36:10ZevvI know you're reading this disruptek. I do know
17:38:17*maier quit (Ping timeout: 256 seconds)
17:41:43*NimBot joined #nim
17:45:29FromDiscord<Clyybber> disbot has internet so theres that
17:45:30FromDiscord<Clyybber> :p
17:46:29FromDiscord<Clyybber> Zevv: What prevents the cps macro from operating on typed AST?
17:47:22*narimiran joined #nim
17:48:30ZevvThat was exactly my question: https://github.com/disruptek/cps/issues/27#issuecomment-665801486
17:48:31disbotGetting rid of reallocs ; snippet at 12https://play.nim-lang.org/#ix=2svX
17:48:48FromDiscord<Clyybber> hah
17:48:57ZevvI'm not sure. I think I tried to get started typed in the Very Beginning, but then had to do untyped things
17:49:05Zevvand you can't do both, you have to choose
17:49:16Zevvdisruptek then picked off when I gave up
17:49:23Zevvso maybe he just took that part for granted
17:49:33Zevvbut I can't recall why I didn't get it to run fully typed
17:49:50Zevvbut going typed might solve a lot
17:50:19FromDiscord<Clyybber> yeah
17:51:41Araqjust write a compiler plugin
17:52:05FromDiscord<Clyybber> oi Araq
17:52:09FromDiscord<Clyybber> did you see my message?
17:52:24FromDiscord<Clyybber> https://irclogs.nim-lang.org/29-07-2020.html#16:22:00
17:55:53shashlickAraq: do you want an env var for --nimExe or just the command line is sufficient
17:56:22leorizeshouldn't that switch be called `--nim` instead? to match testament
17:57:43*vicfred joined #nim
17:57:46shashlickyep that's what i'm doing
17:57:52shashlickbut just to use his lingo
17:58:48Zevvdid araq just say "plugin"?
17:58:58leorizeyes
17:59:20leorizethe mysterious compiler plugin system that practically only araq knows how to use
17:59:54FromDiscord<Clyybber> We don't need a compiler plugin for CPS
18:00:00leorizenow only if we can write compiler plugins in user code and the compiler just pick it up at compile time :P
18:00:21Zevv"there are few ways of killing your productivity in programming. A plugin system is one of them
18:00:21FromDiscord<Clyybber> I don't think it will make the task much easier
18:00:24Zevvsomeone once said
18:00:58leorizecompiler plugins got a leg up in that it can access all the cool compiler internals
18:01:20FromDiscord<Clyybber> yeah, but thats not needed here
18:01:32FromDiscord<Clyybber> and cps as a macro is a good stress test of macros
18:01:35ZevvI feel that one day we really have to go that way, but as long as stuff can be proof-of-concepted in macros, I'm all for that
18:01:39FromDiscord<Clyybber> already uncovered a few bugs
18:01:44Zevv\o/
18:02:13FromGitter<iffy> To make sure an object meets a concept's requirements, I'm doing `assert newMyObject() is MyConcept` and it's failing, but I can't figure out why. Is there a way to make it tell me what's missing? `{.explain.}` on the type def doesn't seem to help.
18:02:43*abm quit (Quit: Leaving)
18:04:18*endragor quit (Remote host closed the connection)
18:04:56*endragor joined #nim
18:08:32*maier joined #nim
18:09:23*endragor quit (Ping timeout: 240 seconds)
18:10:23*apotheon joined #nim
18:10:42*dadada joined #nim
18:10:45dadadahey people
18:10:55dadadaI wish for there to be a Nim implementation of this
18:11:00dadadahttps://github.com/asciidoctor/asciidoctor
18:11:13dadadait looks to me like it is more useful than markdown
18:12:24dadadaunlike markdown it is fully standardized, endorsed by Linus Torvalds, and has more features, like footnotes, colors, fonts
18:12:42dadadaso the features are a superset of markdown (with different syntax)
18:13:15dadadabut that it is implemented in ruby is a problem, waiting to be solved
18:13:44PrestigeDo it dadada
18:13:49apotheonquick question: Does Nim allow non-ASCII characters in identifiers? It doesn't look like it does, from what I've read so far.
18:13:58*maier quit (Ping timeout: 260 seconds)
18:13:58Zevvapotheon: sure it does
18:13:59FromDiscord<KingDarBoja> Do it
18:14:22FromDiscord<Idefau> a friend even use braille alphabet for variables in nim lmao
18:14:24Zevvdadada: go for it!
18:14:24apotheonZevv: . . . so _foobar→ is an allowed function name or variable name?
18:14:28FromDiscord<Idefau> (edit) 'use' => 'used'
18:14:34apotheoncool, thanks
18:15:05FromDiscord<KingDarBoja> _insert Palpatine voiceline_
18:15:06Zevvapotheon: well, only the underscore is biting you here
18:15:15Zevvbut the arrow thingy is finy
18:15:20Zevvyou can go full APL with nim
18:16:26dadadaPrestige, Zevv, KingDarBoja, yes, I should, but I have issues that prevent me from getting much done, so if someone else goes ahead, they'll probably be done sooner than me
18:16:51Zevvdadada: story of my life
18:17:05PrestigeI don't think anyone else is working on it so you'll be first
18:17:31Zevvjust start off with nimdoc
18:17:52apotheonZevv: Oh, are underscores not allowed as leading identifier characters? I must've missed that.
18:17:59*oriba quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
18:18:23Zevvyeah, it's part of nims style-insensitivity
18:18:28apotheonI see: "begins with a letter".
18:18:28Zevvwhich you are free to hate, if you mush
18:18:29Zevvmust
18:18:35apotheonI totally overlooked that, somehow.
18:18:39dadadaI think asciidoc could be useful in so many different places of the Nim ecosystem, for docs, for website content, for rendering on the terminal, as intermediate language between other markdown and other output (markdown -> asciidoc -> terminal | markdown -> asciidoc -> HTML), for rich text applications, even for writing books its interesting... definitely more versatile than markdown
18:18:55*zacts joined #nim
18:19:01*arecacea1 quit (Remote host closed the connection)
18:19:07Zevvapotheon: although that's not right either
18:19:24*arecacea1 joined #nim
18:19:27FromGitter<bung87> what's asciidoc ?
18:19:41Zevvhttps://play.nim-lang.org/#ix=2sCY
18:19:52apotheonI do rather dislike the style-insensitivity, and have since it was just a suggestion that came up in this channel years ago, but I know someone who's looking for a language that does specific things and I thought that person might like Nim more than Raku, so . . . I figured I'd double-check that one allowable-characters feature before telling him this could be the language for him.
18:20:13Zevvright, fair enough
18:20:38dadadabung87: https://asciidoctor.org/
18:20:41apotheonI also disliked the offside rule introduction to the language back then.
18:20:48ZevvIt's a funny thing, and it keeps popping up. The interesting part is that I always hear people hate it, unless they really use nim
18:20:58ZevvAnd then they just stop caring about it and see the benefits
18:21:02Zevvit's just very alien I guess
18:21:05apotheonIt's a pretty cool language in a variety of ways, though, so I'm happy to recommend it to someone who's looking for something it fits.
18:21:34dadadaI also like the style insensitivity, it doesn't mean that you can't have a consistent style
18:21:43Zevvright. it's always ok to mention it to someone, and everyone should find out in the end if it is something the like or not
18:22:30apotheonI have technical reasons for disliking the offside rule for most languages. I could like it, but I haven't seen a language whose other grammatical characteristics don't introduce problems in combination with it -- except maybe Haskell, but I don't know the language well enough to be sure.
18:22:48FromGitter<bung87> hmm weird project name, asciiXXX
18:23:20dadadahttps://asciidoctor.org/docs/asciidoc-vs-markdown/
18:23:52Zevvapotheon: I kind of hate it myself, for practical reasons. But then again, it is pretty compact which has its pros
18:23:55apotheonThe problem I have with the style insensitivity is the need for special tooling or additionally habitual practices to ensure that reading and modifying others' code isn't going to be fraught with additional error.
18:24:19ZevvI have problems when editing my own code when falling down multiple indents. It's often hard to see where you end up
18:24:27dadadabung87: hopefully you can get past the name, it seems really cool to me
18:24:29apotheonIf I didn't prefer to use as-close-to-the-exact-same-tooling-as-possible across a range of very different languages, it probably wouldn't bother me as much.
18:24:40apotheondifferent strokes for different folks
18:24:40Zevvbut hey, I made a nim branch that fixed the parser and introduces curlies, so you can use that
18:25:27apotheonI actually liked the name Nimrod, too. Nim seems harder to search.
18:25:35apotheonI should stop complaining. Sorry.
18:25:38FromDiscord<Rika> i wouldnt mind braces if i never had to type them
18:25:55*nikita` quit (Read error: Connection reset by peer)
18:26:00apotheonRika: That's fair. Typing them doesn't bother me.
18:26:21FromDiscord<Rika> then moving a piece of code into a block
18:26:27FromDiscord<Rika> copy paste reindent
18:26:37FromDiscord<Rika> indentation based is just reindent
18:26:41apotheonAnyway, thanks for the info about variable names. I'll get back out of your communications.
18:27:58*apotheon left #nim (#nim)
18:28:05Zevvwell, all we do is complain anyway
18:28:11Zevvbasically why i'm here
18:28:12*nikita` joined #nim
18:35:28*FromDiscord quit (Remote host closed the connection)
18:35:42*FromDiscord joined #nim
18:36:23*Vladar quit (Quit: Leaving)
18:38:00*maier joined #nim
18:38:01FromDiscord<pan> trying to get a quick imgui test running with nimgl, to do that i need to compile using cpp backend, but when i do that it throws an error while running the program saying it cant find `libgcc_s_seh-1.dll` and `libstdc++-6.dll`, is there a way to just link these statically and fix the problem?
18:38:04*dzamo quit (Quit: dzamo)
18:40:18FromDiscord<Rika> you can use c w/ imgui, you need `cimgui.dll` though
18:42:02FromDiscord<pan> i plan on using the cpp backend for some other stuff too at some point, so id probably like to just fix this first, just unsure what to do exactly
18:42:52*maier quit (Ping timeout: 246 seconds)
18:44:17FromDiscord<Rika> ah okay
18:44:21*endragor joined #nim
18:45:42FromDiscord<pan> oh, seems i just need to do --passL:"-static", though im unsure if that would cause unwanted side effects
18:46:00FromDiscord<Rika> https://stackoverflow.com/questions/6404636/libstdc-6-dll-not-found so `-l "-static-libgcc" -l "-static-libstdc++"` i think?
18:47:07FromDiscord<pan> is there a way i could just add that to my .nimble file so i dont need to add it onto every build command?
18:47:56FromDiscord<Rika> you make a config.nims i think and add it there
18:48:02FromDiscord<Rika> or was it nim.cfg?
18:48:08FromDiscord<Rika> i dont know honestly
18:48:10FromDiscord<Rika> forgot already
18:48:25*endragor quit (Ping timeout: 240 seconds)
18:49:01*andrew[43] joined #nim
18:50:43FromDiscord<pan> using `nim.cfg` seems to work, thanks
18:52:34zactshello nim
18:52:35zacts#nim
18:53:11Zevvhello zacts
18:53:24zactsI'm interested in learning more about nim and what it might offer for my goals of a daily scripting language.
18:53:46Zevvthat depends on what requirements you have for a daily scripting language I guess
18:53:54Zevvwhat do you use now?
18:54:08*Zectbumo joined #nim
18:54:47zactswell, I like Perl. I've been looking at Raku as well for this.
18:54:58Zevvand what is your problem with perl
18:56:06*ofelas quit (Remote host closed the connection)
18:56:33zactswell, I have a few fuzzy ideas that I want to tinker with. One is naming things and redefining syntax with UTF-8 characters. The other is to be able to modify the syntax of the language and kind of customize it for my wants and needs.
18:56:42zactsI also like the idea of interop with C and JavaScript.
18:57:12zactsthis would be for scripting tasks on my computer.
18:57:21Zevvwell, you will not be able to modify the *syntax*, but within the syntax you can do basically everything you can think of
18:57:25zactsI'm also curious as to how many libraries Nim has.
18:57:41zactslike in comparison to CPAN or Ruby gems.
18:57:51Zevvoh compared to CPAN or Ruby, there's about next to nothing
18:57:57zactsah ok
18:58:00Zevvbecause cmon, CPAN is humongous
18:58:04zactswell, yeah.
18:58:07zacts:-)
18:58:15Zevvwe have "nimble", which currently has 1366 packages
18:58:20FromDiscord<Rika> we barely have over a thousand
18:58:35Araqyou can use completely custom syntax within triple string literals
18:58:46Araqbut it's usually not necessary nor convenient for others
18:58:52Zevvyeah you can do that in any language :)
18:59:08Araqwell you cannot parse the string at compiletime in other languages...
18:59:13zactscan I easily add a new operator to the language?
18:59:21Zevvtrivial
18:59:25zactscool
19:00:00Zevvalso, keep in mind that nim is not a scripting language
19:00:17Zevvit is not duck typed. Often it *feels* like a scripting language, low friction, high density
19:00:20Zevvbut it is not
19:00:30Zevvit does compile time execution and we have a subset of nim called nimscript
19:00:35Zevvbut that's not the power of nim
19:00:38zactsoh I see
19:01:00*Senketsu joined #nim
19:01:05Zevvaw, this is always hard to explain.
19:01:29ZevvIt is both a script language and a compiled language. Your program can do both, so part of it can run at compile time, part of it gets compiled and runs at run time
19:01:43zactsok
19:01:54dadadahas anyone ported ruby code to nim? experience?
19:01:57Zevvthe compile time part can be used to pre-calculate stuff, slurp binary objects into variables, or - and that's the power - modifiy the programs AST itself
19:03:35FromGitter<alehander92> yes
19:04:08FromGitter<alehander92> dadada https://www.youtube.com/watch?v=hlWCp210IIY
19:04:17FromGitter<alehander92> it's .. not a good example because it's about automatic stuff
19:04:32FromGitter<alehander92> but .. i guess one can say a bit
19:05:17dadadaalehander92: how many minutes can I skip there?
19:05:25FromGitter<alehander92> overally as most things, just try to make your nim code nim-ic and adapt the ruby thing
19:05:54Zevvclyybber ping
19:06:18FromGitter<alehander92> https://www.youtube.com/watch?v=hlWCp210IIY
19:06:22FromGitter<alehander92> sorry
19:06:23FromGitter<alehander92> https://metacraft-labs.github.io/fast-rubocop/ruby-kaigi-2019/#/
19:06:33FromGitter<alehander92> here are some slides just look at them if there is something
19:07:47FromGitter<alehander92> but just try to rewrite the more meta parts / see which libs are good matches for the ruby ones you used before and if there is code thats more obviously similar port it ltierally
19:07:51*Senketsu quit (Read error: Connection reset by peer)
19:13:36*Zectbumo_ joined #nim
19:14:14dadadahttps://github.com/opal/opal <- I'd like to see a version of opal that translates to Nim instead of JS ... for this we would require an implementation of the stdlib and corelib of Ruby in Nim... reason why I want this, so I don't have to write the asciidoc implementation in Nim... :D
19:15:07*Zectbumo quit (Ping timeout: 260 seconds)
19:15:28*ofelas joined #nim
19:16:24alehander92hehe
19:16:28alehander92it would be more fun to wrtie
19:16:34alehander92your own asciidoc i think
19:16:50alehander92i mean, on the other hand that's why we wanted to write languist
19:17:04alehander92it is fun , but it depends on people writing replacments of libs
19:17:16dadadadefinitely easier, I agree... but think about all the libraries becoming available to nim developers, or think about all the libraries that aren't, at the moment
19:17:18opalthere's my reminder that i share my name with some javascript project
19:17:43alehander92much better to invest in some normal nim libs i think
19:17:48alehander92opal haha
19:17:51alehander92ruby / javascript
19:19:24FromGitter<bung87> I think which ruby libs have other language also have, compare to ruby , python's lib more easy
19:20:36dadadaalehander92: it's not a small task to port asciidoc to nim, ... also it's a bit concerning that more and more libs are getting written in python/ruby/js, by which I mean non-compiled languages, and more specifically non-C-compatible languages, which means that writing wrappers isn't enough to satisfy the gap for a Nim project.... this is very bad for us as Nim developers. And those ruby/python/js projects
19:20:42dadadaaren't always short 1000 line projects, asciidoc seems to have multiple thousand lines, and no I won't be able to quickly transform that ... :-(
19:22:28FromGitter<bung87> python cpp are good targets for porting things
19:22:54dadadabung87: for cpp you can also write a wrapper, so I would do that rather than porting
19:23:24FromGitter<bung87> that need you compile your full project to cpp right ?
19:23:44dadadabung_: not sure, even if, what's the problem with that?
19:24:30FromGitter<bung87> you may have dependecies that is c wrapper , or cpp wrapper , how does they work together?
19:24:49dadadabung87: should be without any issues
19:25:13FromGitter<alehander92> dadada well .. one can't have everything
19:25:23FromGitter<alehander92> rust / go / swift etc
19:25:34FromGitter<alehander92> also have the same problem, we just have to build an ecosystem
19:25:56*Senketsu joined #nim
19:25:57FromGitter<bung87> for 1k lines project , it's not hard to porting it manually I think
19:27:14dadadaalehander92: that's why I think the collective Nim project should prioritize some libraries to port to Nim, for example find out what the top 20 libraries are that developers are missing from Nim now and that DON'T have wrappers or the possibility of wrappers (for example because they are ruby or go libs)
19:27:28*ofelas quit (Quit: shutdown -h now)
19:27:42dadadaand then make a competition with bounties from that list
19:27:46disruptek!last zevv
19:27:47disbotZevv spoke in 12#nim 21 minutes ago 12https://irclogs.nim-lang.org/29-07-2020.html#19:05:54
19:28:15dadadalike 500$ per ported library, or another amount that the project can afford
19:28:34dadadaNim's overall worth would increase a lot with all those ports coming in
19:28:38FromGitter<alehander92> maybe
19:28:46FromGitter<alehander92> but i wouldn't want direct ports..
19:28:54FromGitter<bung87> we just need more nimer, like how js ecosystem grows
19:28:55FromGitter<alehander92> for many, it's good to have a proper nim interface
19:29:03FromGitter<alehander92> not just copying foreign apis
19:29:22FromGitter<alehander92> but just making "a stuff lib" with capabilities of other
19:29:24FromGitter<alehander92> is good yeah
19:29:34dadadabung87: there's no even playing field with js ecosystem, js was part of the web ecosystem for decades, and this is maybe the biggest ecosystem now because the web is huge
19:29:49FromGitter<bung87> you search github with language:nim only show 476 users
19:29:51FromGitter<alehander92> but js is different
19:29:59FromGitter<alehander92> we dont need so much many of the visual libs etc
19:30:04dadadabung87: Nim has no advantage like that, so we can't just "hope" for more nimmers to magically appear and start writing libraries
19:30:39FromGitter<bung87> yeah we cant just hope that
19:31:02FromGitter<bung87> maybe some killer project will leading people here
19:31:04FromGitter<alehander92> i think libs help
19:31:09FromGitter<alehander92> like vim3d and nitter
19:31:14dadadathe competition idea is sure to work, even if it fails, and we don't get the 20 ports, we'd at least get a fraction of it, and that's still better than 0
19:31:15FromGitter<alehander92> are good posts to platforms
19:31:19FromGitter<alehander92> which make people think
19:31:25FromGitter<alehander92> ok i can write my project in nim
19:32:16FromGitter<bung87> or some project like vscode that's mostly about ts
19:33:02FromGitter<bung87> they get free good ide and try write extension, try ts
19:33:31FromGitter<alehander92> yeah
19:33:35FromGitter<alehander92> extensions are good too
19:35:15dadadaor can one advanced elite Nim developer maybe make a YouTube series where he/or/she/or/it/or/they ports say asciidoc to Nim?
19:35:37dadadathen less advanced nimmers can learn from that step by step commentary and port more libraries?
19:36:28FromGitter<bung87> on the other hand , should improve libs make existed nim users feel good
19:37:14dadadabung87: what do you mean?
19:39:43dadadasince I found out about Nim it is clear to me that the biggest drawback to it is the small ecosystem, and nothing has changed there
19:41:28dadadawithout any concerted effort by the project leaders to port the most sought after libraries from other languages, that are missing in Nim, there'll always be people who think Nim is cool, but then will use Ruby/Python/Go for their projects, because they'll not want to go through the trouble of porting libraries as Nim newbies, understandably
19:42:45dadadaso if the libraries with the most widespread use get ported to Nim, (and to alehander's point: yes this can be with adapted Nim-like APIs), this changes the whole dynamic
19:43:14dadadaand all of a sudden Nim isn't a cool toy anymore, people talk about but then never use, and it becomes something that gets actually adopted
19:43:47FromDiscord<Clyybber> Araq: ping
19:44:03FromGitter<bung87> that happens
19:44:50FromDiscord<Clyybber> @mratsim Hey, maybe https://github.com/nim-lang/Nim/pull/15116 fixes that issue you showed me yesterday
19:44:50disbotfix overloading case with generic alias
19:47:24*waleee-cl joined #nim
19:47:47*vicfred quit (Quit: Leaving)
19:48:43FromDiscord<Clyybber> Zevv: ping
19:54:56Zevvyeah I already wrote at the issue; I kind of hoped that your fix also had to do with the funny gensym, but that's not solved yet
19:55:22FromDiscord<Clyybber> can you give me a snippet I can compile
19:55:34FromDiscord<Clyybber> because I get undeclared identifier issues with the old one
19:55:36Zevvyeah bit it goes through cps
19:55:42Zevvbut
19:56:03Zevvand disruptek broke my test, so you have to send this snippet to an earlier cps version
19:56:06Zevvit's a bit of a pita
19:56:11FromDiscord<Clyybber> ah
19:56:14Zevvtake cps 0.0.11
19:56:20FromDiscord<Clyybber> k
19:56:21Zevvand I'll prepare you a snippet
19:57:03FromDiscord<Clyybber> is it a "environment misses X" bug?
19:57:28Zevvright
19:58:06Zevvbut it's not missing
19:58:19Zevvit seems that nim is messing up the different environments among each other
19:58:30Zevvaltohough they are uniquely gensymmed
19:58:52ZevvI made that workaround by appending a global incrementing counter to the gensym labels
19:58:57FromDiscord<Clyybber> huh
20:01:36*NimBot joined #nim
20:02:22FromDiscord<Kiloneie> How do you tell VS Code to use other Nim version ? Been using 1.0.0 till now and i need 1.2.X for Nico, i can't find the settings to change the compiler location.
20:02:42FromDiscord<Clyybber> dunno sorry
20:02:51*zacts quit (Quit: WeeChat 2.8)
20:02:55*vicfred joined #nim
20:05:11FromDiscord<Clyybber> Zevv: Huh, original snippet compiles and runs for me with cps 0.0.11
20:05:22FromDiscord<Clyybber> the one on ix.io that is
20:08:19Zevvyeah but 0.0.11 has the workaround
20:08:43Zevv37f0063262cdc173f13a6b4871e410343a4dc775
20:09:41Zevvlemme see if I can hack this up for you
20:09:56FromDiscord<Kiloneie> This is odd, i removed the old Nim version, then ran finish in the new one, it installed the compiler for mingw, added env variable, and path, then when i run my program with it it still referes to 1.0.0 folder... the hell...
20:10:36FromDiscord<Clyybber> Zevv: Hmm, I reverted that commit, can repro the invalid C code
20:16:06*Trustable joined #nim
20:18:57Zevvok got it
20:19:00Zevvtake this
20:19:01Zevvhttp://ix.io/2sDd
20:19:29Zevvand compile it with 0.0.11 with 1 little change
20:19:43Zevvremove the "& c" at line 341 of cps/environment.nim
20:19:46Zevvthat's the workaround
20:19:54ZevvI can also make you a branch if you like
20:19:54*andrew[43] quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
20:19:59FromDiscord<Clyybber> thats what I did
20:20:05FromDiscord<Clyybber> I get Cgen errors
20:20:07Zevvif you disable either of those blocks form the ix, it compiles
20:20:08Zevvright
20:20:09Zevvcgen errors
20:20:44Zevvif you look at the -d:cpsDEbug output, there are two environments defined
20:20:48Zevvone for the first part, one for the second
20:20:52Zevvthey have unique id's
20:20:57Zevvone has a member 'a', the other a member 'b'
20:21:19Zevvbut somehow the bottom part still uses the upper env with 'a', and can't find 'b' in it
20:21:32Zevvthere is no C struct generated for the second env
20:21:45Zevvdoes that make sense?
20:22:39ZevvI get only one struct envcolongObject in the C code
20:22:46Zevvwith NI a;
20:22:59FromDiscord<Clyybber> huh, wtf
20:23:02Zevvright
20:23:09Zevvthat was the whole point of issue #3 :)
20:23:16ZevvI probably didn't explain it that well
20:23:21Zevvcan you repro?
20:23:26FromDiscord<Clyybber> yep
20:23:30Zevvnoice
20:24:26FromDiscord<Clyybber> hmm, this is weird indeed
20:24:33Zevvit is
20:25:43FromDiscord<Clyybber> oh, maybe not so weird
20:25:51Zevvtell me
20:25:56FromDiscord<Clyybber> i'm gonna try a naive fix
20:26:19FromDiscord<Clyybber> opcGenSym just says getIdent
20:26:40FromDiscord<Clyybber> and somehow expects the generated ident to be unique
20:26:50Zevvuh
20:26:56FromDiscord<Clyybber> but I guess thats intended
20:28:48FromDiscord<Clyybber> but I don't think that holds necessarily true
20:37:24Zevvclearly not :)
20:38:42*maier joined #nim
20:39:01FromDiscord<Clyybber> looks like we already rely on it somewhere
20:39:20FromDiscord<Clyybber> adding a stupid add $rand(0..int.high) doesn't solve it
20:39:34*narimiran quit (Ping timeout: 265 seconds)
20:41:07FromDiscord<Clyybber> Well, it does, but now its failing in sequtils :D
20:41:22FromDiscord<Clyybber> I'm not sure what is the intended behaviour here
20:43:04FromDiscord<Clyybber> IMO genSym should give you a unique symbol, that acts like a symbol marked with {.gensym.} so it shouldn't be accessible outside of the template/macros scope
20:43:56*maier quit (Ping timeout: 256 seconds)
20:45:05Zevvmakes sense
20:45:14FromDiscord<Clyybber> thats not the current behaviour :D
20:45:35FromDiscord<Clyybber> which is very weird
20:47:45Zevvbut kind of interesting how this stayed hidden so long
20:47:49FromDiscord<Clyybber> yeah
20:47:51Zevvit feels like a pretty common thing to do
20:48:02FromDiscord<Clyybber> I mean, it seems to work in some cases
20:48:25FromDiscord<Clyybber> this for example works
20:48:25ZevvI actually just suspected CPSs AST to be borked
20:48:26FromDiscord<Clyybber> sent a code paste, see https://play.nim-lang.org/#ix=2sDn
20:48:36FromDiscord<Clyybber> that could be it too
20:48:54Zevvthe repr of it compiles fine of course
20:49:04Zevvso maybe we should just repr and eval it :)
20:49:05FromDiscord<Clyybber> yeah
20:49:20FromDiscord<Clyybber> maybe print out the symbols of the env
20:49:29FromDiscord<Clyybber> those *shouldn't* be the same
20:49:35FromDiscord<Clyybber> since they even have different idents
20:49:43Zevvthey arent in the repr anyway
20:50:01Zevvwhat makes a mangle?
20:50:06Zevvcould it be happening there?
20:50:09Zevvsomething clashing?
20:50:17FromDiscord<Clyybber> yeah
20:50:19FromDiscord<Clyybber> ah damn
20:50:23FromDiscord<Clyybber> you hit the nail on the head
20:50:57FromDiscord<Clyybber> someone probably removed the logic that attaches the sym id to the C typedef
20:51:04FromDiscord<Clyybber> if that logic ever existed
20:51:23Zevvwhat's a minimal reproduction for this, without going to cps
20:51:26FromDiscord<Clyybber> since it got kinda redundant with the new gensym handling that simply appended `gensymXXX to the ident
20:51:38FromDiscord<Clyybber> Zevv: Probably generating two types with genSym
20:51:47FromDiscord<Clyybber> with different fields
20:52:15FromDiscord<Clyybber> and then creating an instance of the first type
20:52:22FromDiscord<Clyybber> and trying to access the field
20:52:52FromDiscord<Clyybber> .s/first/second
20:54:11FromDiscord<Clyybber> and if genSym is fixed it should still be possible to do with manual symNode creation
20:54:26FromDiscord<Clyybber> assuming we were right with our analysis
20:54:31FromDiscord<Clyybber> I'll get something to eat
20:57:23*andrew joined #nim
20:58:32*xet7 joined #nim
21:02:15Zevvcan't get it to reproduce with a plain macro
21:02:36*dulsi__ joined #nim
21:02:56*dulsi__ is now known as dulsi
21:04:10FromDiscord<Clyybber> maybe it needs to be two type sections
21:04:20FromDiscord<Clyybber> with a use of the first type in between
21:04:59*dulsi_ quit (Ping timeout: 240 seconds)
21:05:37Zevvhttp://ix.io/2sDs
21:06:40Zevvthat is just fine
21:08:52*thomasross joined #nim
21:12:32Zevvthink I have it clyybber
21:12:35Zevvit needs to be a ref obj
21:12:57Zevvthis is my repro
21:12:58Zevvhttp://ix.io/2sDu
21:15:18ZevvI have no to clue what to put in the subject for the issue
21:16:16Zevv"genSym fails to make unique identifier for ref object types"?
21:17:13*Senketsu quit (Read error: Connection reset by peer)
21:17:38disruptekput something in there about bad ast. araq loves that shit.
21:17:47Zevvwill do
21:18:01Zevvlet be honest dude. You are messing about seriously with nimnodes there
21:18:21Zevvnot sure how your brain works, but I can't do that shit
21:18:25ZevvI just quote do my way around
21:18:36Zevvbut fair enough
21:18:44Zevvyou were wrong and I was right
21:18:45Zevvooh no
21:18:48Zevvthe other way around
21:18:52ZevvI was right and you were wrong
21:18:54Zevvdaang no
21:19:01ZevvYou were right and I was wrong
21:19:05Zevv(that hurt)
21:19:13disruptekwhat happened?
21:19:30Zevvwell, your AST is probably fine, I reproduced it with a small snippet, see above the last ix
21:20:13disrupteki don't trust `quote do`.
21:20:27ZevvI recently threw all the 'do's' out
21:20:29Zevvand it still works
21:20:31ZevvI was lied to
21:20:50Zevvanyway, http://ix.io/2sDu shows the problem, but I can't file a nim issue for it
21:23:49*Kaivo quit (Ping timeout: 256 seconds)
21:24:29*nikita` quit (Quit: leaving)
21:26:41Zevvso disruptek, before I get my nap
21:26:51Zevvwhy again are we doing all of this untyped in the first place?
21:31:08*Senketsu joined #nim
21:31:42FromDiscord<Clyybber> Why cant you file an issue for it?
21:32:45Zevvno clue what to put in the subject. total blocker of course
21:33:13FromDiscord<Clyybber> lol
21:35:06Zevvhttps://github.com/nim-lang/Nim/issues/15118
21:35:08disbotCgen error: genSym fails to make unique identifier for ref object types ; snippet at 12https://play.nim-lang.org/#ix=2sDB
21:35:43*Kaivo joined #nim
21:51:06*solitudesf quit (Ping timeout: 265 seconds)
21:58:38*tane quit (Quit: Leaving)
22:00:16*andrew is now known as andrew[43]
22:00:43*andrew[43] quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
22:02:41*andrew joined #nim
22:02:46*endragor joined #nim
22:07:43*endragor quit (Remote host closed the connection)
22:24:15*Senketsu quit (Read error: Connection reset by peer)
22:28:22*Trustable quit (Remote host closed the connection)
22:39:35*maier joined #nim
22:44:38*maier quit (Ping timeout: 256 seconds)
22:50:30*krux02 quit (Remote host closed the connection)
22:50:59*krux02 joined #nim
22:58:25*krux02 quit (Read error: Connection reset by peer)
23:00:34*krux02 joined #nim
23:03:22*krux02_ joined #nim
23:06:59*krux02 quit (Ping timeout: 265 seconds)
23:16:06*lritter joined #nim
23:18:06*dadada quit (Read error: Connection reset by peer)
23:22:03*dadada joined #nim
23:22:27*dadada is now known as Guest7037
23:25:16*endragor joined #nim
23:25:35*endragor quit (Remote host closed the connection)
23:28:25*andrew quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
23:38:23*D_ quit (Ping timeout: 244 seconds)
23:40:30*dulsi_ joined #nim
23:40:42*D_ joined #nim
23:43:25*dulsi quit (Ping timeout: 264 seconds)
23:52:51*Guest7037 quit (Ping timeout: 256 seconds)
23:52:54*zacts joined #nim
23:59:37*OMGOMG quit (Remote host closed the connection)