<< 28-10-2019 >>

00:00:55*stefantalpalaru joined #nim
00:20:23*gangstacat quit (Quit: ฤœis!)
00:26:57*luis_ quit (Quit: luis_)
00:29:20FromGitter<Varriount> disruptek: I saw some flash replacement the other day
00:29:32disruptekoh yeah?
00:29:33*luis_ joined #nim
00:31:11FromGitter<Varriount> https://www.openfl.org/
00:31:55FromGitter<Varriount> Discovered from https://watabou.itch.io/one-page-dungeon
00:32:55disruptekbut why?
00:34:49FromGitter<Varriount> What do you mean?
00:35:36disrupteki mean why make such a thing and then have separate sections for different oses?
00:36:09*ng0 quit (Quit: Alexa, when is the end of world?)
00:36:42FromGitter<Varriount> I still don't follow
00:37:21disruptekis it or is it not x-platform?
00:37:25disruptekhttps://www.openfl.org/showcase/
00:39:21*Hideki_ quit (Remote host closed the connection)
00:41:31*Hideki_ joined #nim
00:41:32*Hideki_ quit (Remote host closed the connection)
00:42:11*Hideki_ joined #nim
00:44:58FromGitter<deech_twitter> The Nim 1.0.2 pre-built release is an 8MB download that expands to 820MB! 768MB of that in `c_code`. Why is it so big?
00:46:03disruptekmy gf says it's not my diet.
00:46:17*Hideki_ quit (Ping timeout: 246 seconds)
00:47:13disruptekmore of a `grow'er` than a `show'er`, i guess.
00:50:15*krux02_ joined #nim
00:52:34*krux02_ quit (Remote host closed the connection)
00:54:13*Hideki_ joined #nim
00:54:24*krux02 quit (Ping timeout: 265 seconds)
00:54:43FromGitter<deech_twitter> Oh I see, `c_code` contains C sources that can be built locally for each of the platforms supported by Nim. Guessing if the binary in the `bin` folder works it can be deleted.
00:55:51FromGitter<deech_twitter> Guess there's an immense amount of code duplication so `tar` is able to compress 770MB of code to 8MB.
01:04:02*gangstacat joined #nim
01:04:39*GordonBGood joined #nim
01:08:26*stefantalpalaru quit (Changing host)
01:08:26*stefantalpalaru joined #nim
01:09:08*nif quit (Quit: ...)
01:09:17*nif joined #nim
01:25:14*Hideki_ quit (Remote host closed the connection)
01:27:05*luis_ quit (Quit: luis_)
01:28:01FromGitter<gogolxdong> @treeform,yes,I think fidget would benefit from virtual DOM for Javascript backend.
01:35:32FromDiscord<treeform> gogolxdong, what is virtual DOM? Its a react concept, not event a stand alone lib, I don't want to import react code.
01:46:14FromGitter<gogolxdong> Karax uses virtual DOM.
01:47:52FromDiscord<treeform> I pool DOM nodes and cache attribute changes. I think that's enough?
01:50:56FromGitter<gogolxdong> donno, will check further. Getting rid of CSS and Javascript is great though.
01:51:07FromDiscord<treeform> Looking at how Karax does vdom, I think I do some thing very similar.
01:51:37FromDiscord<treeform> I did "virtual dom" for my other JS framework, I feel like I have evolved beyond it.
01:57:24FromDiscord<treeform> hashbjorn, do you have pictures of pure tanks?
02:05:07livcdhow would you get rie of css? oO
02:13:31FromDiscord<Chiqqum_Ngbata> I still question the utility of virtual DOM. Maybe updates to the page are a tad faster but DOM updates were already so fast.
02:19:53FromDiscord<treeform> livcd, I have my own style and layout thingy, that mimics how figma does it (for easy export). So people using fidget don't need to know how CSS works, I translate fidget style stuff into CSS. I do everything with element's style attribute.
02:20:38FromDiscord<treeform> I only have like 10 style attributes vs CSS's 100s of attributes.
02:22:04*nif quit (Quit: ...)
02:22:14*nif joined #nim
02:23:53FromDiscord<treeform> I don't have any of the crazy float, box-sizing or flexbox rules... which is what people hate about CSS most.
02:24:35FromDiscord<treeform> I only have the constraints from figma: https://medium.com/@csmnng/constraints-in-figma-ae0032f04dc3
02:26:41FromDiscord<treeform> My goal is to have the most minimal number of UI primitives available. Everything else will be built from that.
02:26:56FromDiscord<treeform> I kind of want to get down to the "Axioms" of UI.
02:46:59FromGitter<gogolxdong> I conceived something like this, which is only possible in Nim. I think it has great potential.
02:47:39disruptekTHERE ARE CHEESES WE HAVEN'T INVENTED YET
02:48:27FromGitter<gogolxdong> livcd ,where are you now?
03:11:51*GordonBGood quit (Ping timeout: 260 seconds)
03:52:57*dddddd quit (Ping timeout: 240 seconds)
04:01:45*rockcavera quit (Remote host closed the connection)
04:17:20*chemist69 quit (Ping timeout: 246 seconds)
04:19:16*chemist69 joined #nim
04:19:56yumaikashttps://www.junglecoder.com/blog/nim-early-report Wrote about learning Nim, if anyone is interested
04:22:58disruptekthank you.
04:24:29yumaikasdisruptek: to me?
04:24:38disrupteksure.
04:25:21*yumaikas is now curious about the cheeses
04:25:37disrupteki can't talk about them.
04:26:13yumaikasdisruptek: what can you talk about?
04:26:29disruptekname your topic.
04:26:47yumaikasChicken cannons
04:27:19disruptekmy first was pvc and we called it the pipe bomb because when it blue the hoses off, i was sure i lost a finger.
04:27:27disrupteki admit, i squealed like a little girl.
04:27:39disruptekblew, too.
04:28:08yumaikasLol, nice
04:28:21disruptekwe had another bomb, too, but that was made from steel. i mostly used it as a pressure tank and if it had exploded, i'd have been killed.
04:28:45disruptekended up painting it bright white with a red logo. didn't come out perfect. a learning experience.
04:28:55disruptekchrist, POR-15 can be difficult to work with.
04:29:00yumaikasDid you actually make cannons for launching chickens?
04:29:15disrupteklaunching? no, i thought you said lynching.
04:29:31disruptekthe chicken launchers were really more like slingshots.
04:29:43disruptekthe chickens loved them. especially the hens.
04:29:53disruptekroosters can be kinda ornery, if you know what i mean.
04:30:16disruptekyou really don't want to spent too much time in close proximity, which is why the first approach was just a sling.
04:30:26disruptekthey have these wicked claws, you see. nasty bastards.
04:30:36yumaikasPerhaps I know what you mean, I haven't messed with chickens much
04:30:38*GordonBGood joined #nim
04:31:10disruptekwe started out with just coathangers and a rope but after we got the roosters onto the roof, we were able to take our time with developing the launchers for the hens.
04:31:21rayman22201Great review yumaikas! Thanks for writing it ๐Ÿ˜
04:31:53yumaikasrayman22201: You spot anything that should be clarified or corrected?
04:32:10yumaikas(also, you're welcome)
04:32:24*mipri left #nim (#nim)
04:33:26rayman22201Nothing terribly offensive. I was a big Go fan for a while, so I agree with your assessment.
04:34:41rayman22201I'm also happy when people write about Nim. We always need more marketing.
04:35:17yumaikasLol, I hope I'm not too offensive. Yeah, I was a big go fan for a while, but realized I didn't really use the runtime, and the verbosity gets old
04:36:41yumaikasrayman22201: yeah, that's why I'm asking for feedback as well, since I plan on posting this to lobsters and hn tomorrow evening. Wanted to give it a chance to get looked over for typos and such first
04:38:14rayman22201I'll give it one more read with my editor hat on
04:43:54rayman22201First paragraph, "I think I can offer decently informed opinion." Should be "I can offer *a* decently"
04:46:16yumaikasFixed
04:46:41*nsf joined #nim
04:47:48rayman22201 4th paragraph, "I got around Goโ€™s verbosity by using PISC, and then Lua as scripting" you don't need the comma there.
04:48:07rayman22201The one after PISC
04:48:43yumaikasOk, fixed that.
04:49:52rayman22201I should have warned you in advance, my wife is a librarian. Grammar is taken seriously in my household ๐Ÿ˜‚
04:51:27yumaikasGood, I want this to be at least half-polished. Work that I do in my spare time doesn't always get my most energized hours, lol
04:53:37rayman22201 "just due to how nice a search/tag driven CMS has been to have." Change to "driven CMS is"
04:54:56yumaikasFixed
05:00:02*theelous3_ quit (Ping timeout: 240 seconds)
05:04:50rayman22201"The only grumble I had from this project that I had some difficulties" should be " The only grumble I had from this project *is* that I had some difficulties"
05:06:33*theelous3 joined #nim
05:12:36FromDiscord<Rika> Hey yumaikas, https://idea.junglecoder.com/view/idea/277 doesn't unescape the quotes, is that correct?
05:22:53disruptekZevv: can't seem to get the `1` atom to match correctly in npeg. been driving me bonkers trying to figure this out.
05:29:56*theelous3 quit (Ping timeout: 240 seconds)
05:50:13*narimiran joined #nim
05:59:44Zevvoh?
05:59:52Zevvshow me
06:00:40Zevvas atoms go, the dont come any matchier then '1'1
06:00:44Zevvas atoms go, the dont come any matchier then '1'
06:08:51*thomasross quit (Read error: Connection reset by peer)
06:09:36*thomasross joined #nim
06:24:29FromGitter<gogolxdong> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5db6899de469ef43587a51a5]
06:24:45FromGitter<gogolxdong> @treeform got this when compile.
06:26:52FromDiscord<Rika> gogolxdong maybe `Color` has no hash proc
06:29:26FromGitter<gogolxdong> Color is an object.
06:30:52FromGitter<gogolxdong> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5db68b1ce1c5e91508ea673b]
06:32:11FromDiscord<Rika> Is it custom? AFAIK you have to implement it yourself anyway
06:32:23FromDiscord<Rika> See the hashes module
06:34:25*NimBot joined #nim
06:36:49FromGitter<gogolxdong> I don't know how does treeform want to define how to hash Color. Only he can fix.
06:38:01FromDiscord<Rika> Maybe mixing the hashes of all fields, that already sounds sufficient
06:42:52*solitudesf joined #nim
06:43:01FromGitter<gogolxdong> That's assumption.I think it was missed.
07:00:00*gmpreussner_ quit (Quit: kthxbye)
07:05:00*gmpreussner joined #nim
07:16:34*LargeEpsilon joined #nim
07:23:31GordonBGoodHi Araq, et al, following up on my questions about compiler switches from about 11:35 GMT...
07:25:00GordonBGoodSorry, 21:14 GMT
07:25:44AraqI think --seqsv2 is good enough for a name as 'strings' are very much like seqs
07:26:04Araqand secondly, it's becoming the new default so not many people need to know about it
07:26:34Araq --gc:destructors is in version 1.0 but it's undocumented, it's our playground
07:26:46GordonBGoodYes, I see that strings are just a specialized form or seqs, so goo enough for use programmers, especially devs, but might be confusing for newbies?
07:27:02Araqas I said, newbies are not supposed to touch it
07:27:58GordonBGoodYeah, I guess you see that the switch to --seqsv2 will soon become default and that therefore no one will have to use it habitually, okay...
07:28:04Araqit's "Nim devel", it is allowed to tinker with things as long as it doesn't break stuff
07:29:09GordonBGoodYes, as I noted: --gc:destructors is pretty much useless until there are plug-ins available, of which there are none as yet
07:30:08Araqin the meantime I had a couple of new ideas...
07:30:13GordonBGoodAgain, I wonder if it should default the hooks of allocShared0 and discard when no other plug-in is supplied just so it doesn't crash?
07:30:33Araqwho cares just let it crash ;-)
07:30:43Araqthanks to the crashes we know nobody uses it :P
07:31:25GordonBGoodOkay on the crashes, let's hear the new ideas, but first a couple more questions on seqsv2...
07:31:59GordonBGoodI take it that it is our intention that seqsv2 work across all GC's?
07:32:37GordonBGoodIt looks like it is just a matter of making "PGenericSeq" unify across all, that doesn't look to be that hard...
07:33:18GordonBGoodas the structures that they are cast to are the same except for the missing "reserved" field in the new one.
07:33:25GordonBGoodright, so far?
07:33:54Araqright
07:34:15GordonBGoodSo it looks like only a day or two's work to get that working...
07:34:45GordonBGoodNow, in ripping seqsv2 our of destructors, what is left doesn't have much left about destructors...
07:35:18Araqwe can rename --gc:destructors to --gc:hooks
07:35:37GordonBGoodIt would likely be possible for oldseqsv1 to work within destructors, Is that worthwhile doing, or just try to get everyone using the newv2 ones ASAP?
07:36:18GordonBGoodI like --gc:hooks a lot, but then making it work with seqsv1 might make even more sense?
07:36:52Araqseqsv1 are a deadend
07:36:58Araqfor the following reason:
07:37:07GordonBGoodAlthough, now that we have gotten rid of a lot of the cruft, it might be a challenge to make seqsv1 work again
07:37:27GordonBGoodI agree, but reason?
07:38:17Araqold seqs do not call custom destructors, tables build upon seqs so do not call custom destructors so effectively destructors are not supported and are holding back improvements to the IO libary for instance, cannot put 'close' inside a '=destroy'
07:38:57GordonBGoodAs you know, I've never liked seqsv1, so am happy to see them go
07:39:35Araqlikewise the allocators API should be killed with fire
07:39:42GordonBGoodAnd for most users and libraries, they should never notice the difference as the API is the same other than "shallow" and "shllowCopy" become noops
07:40:04GordonBGoodHow about a stake through the heart?
07:40:13Araqwhat?
07:40:22GordonBGoodLike killing vampires
07:41:06GordonBGoodAllocators API, that's not the one in allocators.nim is it?
07:41:48GordonBGoodI'm looking at that one now because Allocators are used in seqsv2...
07:41:57Araqit's allocators.nim
07:42:52Araqit's duplicated effort, if custom seqs are possible and about 100 lines of code there is no need to make seqs use dynamic binding for allocation
07:43:14*flywind joined #nim
07:43:18*LargeEpsilon quit (Ping timeout: 265 seconds)
07:43:26Araqplus the eteneral threadlocal vs global split is what brought us into today's mess in the first place
07:43:31*PMunch joined #nim
07:44:05GordonBGoodAh, so the allocators field in NimSeqV2 payload would be replaced by what?
07:44:34*flywind quit (Remote host closed the connection)
07:44:48Araqnothing
07:44:58*filcuc joined #nim
07:45:28Araqbtw a SmallSeq that uses int32s for 'len' and capacity would be benefitial for the compiler itself
07:45:29GordonBGoodAh, field would just disappear and we would allocate just by calling allocShared directly?
07:45:40Araqyeah
07:45:48GordonBGoodI like it!
07:46:31GordonBGoodBut we need to keep allocators around just to support the current implementations of GC, don't we?
07:46:54Araqthe GC doesn't use allocators.nim
07:47:18Araqthey call alloc() directly
07:48:20GordonBGoodAh, if no GC uses allocators, then what does use allocators?
07:48:31Araqthe new seqs.
07:48:59GordonBGoodSo if you hate allocators, why did you use them in the new seqs?
07:49:19Araqbecause they looked like a good idea when I wrote the code
07:49:36GordonBGoodOho ;D
07:50:03GordonBGoodDo should we write them out as part of this project since nobody is using it yet anyway?
07:50:34FromGitter<alehander42> but how would we be able to use custom allocators
07:51:13AraqGordonBGood, I think so.
07:52:02Araqalehander42: you use or write a library that does the allocations in the way you consider good
07:53:05*GordonBGood2 joined #nim
07:54:13GordonBGood2sorry, my IRC client dropped...
07:54:28GordonBGood2Had to check the logs to catch up...
07:55:10GordonBGood2Okay, I'll look at simplifying NimSeqV2 while I'm at the seqv2 project
07:55:29Araqok, more ideas that I had: 'lent T's implementation is slightly off, it doesn't have to be implemented as a pointer
07:55:51GordonBGood2Ah?
07:55:57Araq'lent T' is exactly our idea of a "partially constructed object"
07:56:03*GordonBGood quit (Ping timeout: 260 seconds)
07:56:21Araqyou can copyMem the guts around as long as you don't call the destructor on it
07:56:48GordonBGood2Okay
07:56:52Araqthis always bothered me, currently 'lent T' means the first argument needs to be passed as a pointer
07:57:10Araqbut that's not required if 'lent T' follows Nim's parameter passing logic
07:57:35GordonBGood2that's applicable when B/D is turned on with optOwnedRef?
07:57:51GordonBGood2What happens when optOwnedRef is not on?
07:57:51Araqit's completely orthogonal to everything else
07:58:48GordonBGood2so when optOwnedRefs is off, owned is a no meaning and lent is a var return?
07:59:05Araqno no no, 'lent T' is always 'lent T'
07:59:28Araqthere is no switch about it, it's design is stable (though its implementation is not)
07:59:45AraqoptOwnedRefs deals with 'owned T'
07:59:57Araqand if turned off 'owned T' means 'T'
08:00:15GordonBGood2so we a lend out a return even if what it being lent isn't really owned, so we can lend out a T?
08:01:16Araqthe answer to this is that you seem to be confused about ownership.
08:01:48Araq'owned' is a specific notion of ownership but Nim had an idea about it before 'owned' became a thing
08:02:02Araqfor example:
08:02:17GordonBGood2When, I thought I understood ownership as I have experimented some, but I've never really used `lent`
08:02:42GordonBGood2example?
08:03:06Araqproc foo(x: var string): lent string = x # valid
08:03:11Araqproc foo(x: string): lent string = x # valid
08:03:30*gmpreussner_ joined #nim
08:03:31Araqproc foo(x: string): lent string = var y = ""; result = y # invalid
08:03:52GordonBGood2Ah, so `lent` or at least the concept existed before the actual keyword `owned` did
08:04:09FromDiscord<kodkuce> making progress?
08:04:25Araqsure
08:04:34*gmpreussner quit (Ping timeout: 265 seconds)
08:05:13GordonBGood2Ok, I think I get it; have to play with lent a little to reenforce it
08:06:00GordonBGood2Ah, I got it
08:07:40Araqanother idea that I had is that this 'trial deletion' thing to resolve cycles, while slow, could be exposed to the Nim programmer
08:07:49GordonBGood2So with a lent T, that has been copyMem'ed, how do you ensure that destroy isn't called on it, compiler magic?
08:08:10GordonBGood2Yes, I had the same idea (kind of)
08:08:11*krux02 joined #nim
08:08:15Araqwell it's not a T so it has a destructor that doesn't do anything, conceptually
08:08:49GordonBGood2Okay, not a T = a noop destructor
08:09:03GordonBGood2compiler takes care of that?
08:09:07*sentreen_ joined #nim
08:09:10Araqsure
08:09:39GordonBGood2Okay, you'll have to help with the compiler part, not up to speed there yet
08:10:48GordonBGood2On the cycle detector/ trial deletion, etc. ideas., I got thinking that just because we use destructor based ref counting doesn't preclude cycle detection as before
08:11:26GordonBGood2Now you are extending that we the possibility of a "hook"?
08:12:04*sentreen quit (Ping timeout: 264 seconds)
08:12:15GordonBGood2I was thinking along those lines, too
08:12:51PMunchHmm, so nimterop has an issue when a header file contains the name of a type and later a definition..
08:14:15PMunchSo for example I have a header file with "struct somename;" at the beginning of the file and then the full definition at the bottom of the file.
08:14:34PMunchBut nimterop generates this as "type somename = object" without any fields..
08:14:50*GordonBGood joined #nim
08:16:55GordonBGoodI also had somewhat of a "programmer accessible" idea about --gc:hooks, too..
08:17:31*GordonBGood2 quit (Ping timeout: 260 seconds)
08:18:07GordonBGoodWould it be possible to make all the current GC's just as plug-ins to it, so that we could be rid of all the cruft forever?
08:20:45GordonBGoodif the hooks including the full current GC API, and we also added destructor hooks, it would unify the whole works?
08:22:42GordonBGoodrequires seqsv2 of course
08:25:07*rokups joined #nim
08:28:48*clyybber joined #nim
08:28:58krux02complex(123'f32)
08:29:09krux02Complex[float64]
08:31:48*floppydh joined #nim
08:32:44*Vladar joined #nim
08:36:37*solitudesf quit (Ping timeout: 240 seconds)
08:41:09GordonBGoodAraq: thoughts on above "unification" idea, and a final question about the ref count destructors project...
08:41:53GordonBGoodAbout your starting to like "just ref count" more than owned because it would break less things in the code base...
08:42:49GordonBGoodWe still thinking along the same lines? If so, I will turn optOwnedRefs off for the project, but...
08:43:12*solitudesf joined #nim
08:43:15GordonBGoodif you still want to look at combining it with B/D, I'll try to test it both ways...
08:43:45GordonBGoodwith the ref counting of ownership as a kind of Biased ref count as per that article
08:47:23FromGitter<alehander42> Araq
08:47:52FromGitter<alehander42> is semAfterMacroCall always called after template, even for nested
08:49:05FromGitter<alehander42> nevermind sorry it does
09:02:38*thomasross_ joined #nim
09:02:38*thomasross is now known as Guest7224
09:02:38*Guest7224 quit (Killed (karatkievich.freenode.net (Nickname regained by services)))
09:02:38*thomasross_ is now known as thomasross
09:14:20*thomasross quit (Remote host closed the connection)
09:14:43*thomasross joined #nim
09:17:27*tklohna_ joined #nim
09:21:27*clyybber quit (Quit: WeeChat 2.6)
09:25:19*clyybber joined #nim
09:29:38*clyybber quit (Read error: Connection reset by peer)
09:31:59*jjido joined #nim
09:34:44*clyybber joined #nim
09:34:46*jjido quit (Client Quit)
09:39:08AraqGordonBGood, the hooks are a bit of a deadend
09:39:29Araqfirstly, you don't want them everywhere because they slow down the code (runtime dispatch)
09:40:00Araqfurthermore, there are still too few hooks, for example, getTotalMem/getOccupiedMem do not work with araqsgc
09:40:04GordonBGoodOkay, we don't want slow...
09:40:54Araqand thirdly, the hooks all tend to get the API wrong, for example the current hooks do not allow for a copying GC mechanism
09:41:11GordonBGoodYes, that's what I said about a "full" GC API, with hooks that aren't used or don't do anything just noop'ed
09:42:18Araqand futhermore, the =hooks use the same ideas but are statically dispatched
09:42:22FromDiscord<mratsim> is the API "zero-cost" abstraction? (sorry too tempting ๐Ÿ˜‰ )
09:42:31Araqso there is a significant overlap here
09:43:01Araqhowever, here is what probably end up with: split up =destroy into =rawDestroy and =trace
09:43:31Araqas =trace is required for any kind of tracing (trial deletion anyone?)
09:44:04clyybberWhats the advantage over a single typebound op?
09:44:07Araqcurrently we are in the conformtable position that we got the ref/ptr distinction right and so we can trace if we want to
09:44:28GordonBGood=rawDestroy is what we have now in =destroy, =trace is the new one the might get called for a tracing cycle detection?
09:44:36clyybberI htink so
09:44:40Araqcurrently they are combined:
09:45:05Araqproc `=destroy`*[T](x: var myseq[T]) =
09:45:05Araq if x.data != nil:
09:45:05Araq for i in 0..<x.len: `=destroy`(x[i])
09:45:05Araq dealloc(x.data)
09:45:05Araq x.data = nil
09:45:15clyybberWhat gets better when we seperate them though?
09:45:18Araq^ it combines both steps
09:45:37*FromGitter quit (Read error: Connection reset by peer)
09:45:40Araqclyybber, it is a key enabler for future things we might want to do
09:45:55*FromGitter joined #nim
09:45:58clyybberCan you give an example? I'm not opposed to the idea :)
09:46:10Araqexample: refcounting + cycle collection
09:46:43Araqcurrently you have no chance of implementing a cycle collector with the existing =hooks
09:47:14GordonBGoodI wasn't thinking that far: I was thinking of just doing a trace/sweep when a threshold is hit much as done now (if the cycle detection is expensive as it usually is...
09:48:06clyybberWHat would the signature of =trace be?
09:48:17GordonBGoodmy idea was just using existing hooks, and would trigger on the next allocation when the threshold was exceeded...
09:49:21Araqclyybber:
09:49:22Araqproc `=trace`*[T](x: var myseq[T]) =
09:49:22Araq if x.data != nil:
09:49:22Araq for i in 0..<x.len: `=trace`(x[i])
09:49:53Araqit describes how to traverse the data structure, not sure if we need the 'var' for the parameter but it cannot hurt
09:49:54*FromGitter quit (Read error: Connection reset by peer)
09:50:13*FromGitter joined #nim
09:50:22Araqit's pretty simple and completes the design IMO.
09:50:48clyybberBut it has to *do* something, right?
09:51:12FromDiscord<kodkuce> do=bloatware xD
09:51:19clyybberWe need it to return a seq of things to destroy, or pass destroy to it.
09:51:23FromDiscord<kodkuce> just troling dont mind me
09:51:50Araqclyybber, maybe rawDestroy is the wrong idea and we should have the existing =destroy as well as =trace
09:52:06Araqbut of course we do notice the overlap in their implementations
09:53:10GordonBGoodWhen would the =trace be triggered?
09:54:03GordonBGoodIt's defined when =destroy is triggered at the end of proc's, but how about =trace?
09:57:41Araq=trace is triggered when you call cycleDetect(x) explicitly
09:57:58Araqfor a start
09:58:04Araqa GC could also make use of it
09:59:30GordonBGoodOkay, I can kind of see that, =trace can be called by utility functions such as cycleDetect()...
10:00:22GordonBGoodit's utility is that it allows customization of the "drill-down" without requiring a magical deepDestroy
10:05:42GordonBGoodAnd because it is separated, it doesn't have to be run on every call to =destroy
10:10:05GordonBGoodWhat does it do when it hits another nested thing that can be =traced, recurse?
10:15:11GordonBGoodBut I guess any such recursion would be the same as for deepDestroy/deepDispose and shouldn't be stuck-busting levels deep
10:15:33*lritter joined #nim
10:18:38GordonBGoodstack-busting
10:29:44*ng0 joined #nim
10:37:06*chemist69_ joined #nim
10:37:52*chemist69 quit (Ping timeout: 264 seconds)
10:39:31*LargeEpsilon joined #nim
10:44:00*LargeEpsilon quit (Ping timeout: 268 seconds)
10:45:53*LargeEpsilon joined #nim
10:50:58AraqGordonBGood, the recursiveness of the setup is a problem I have no good solution for
10:53:02Araqit seems to be an intrinsic problem caused by the open-ness of the design, these are custom hooks that can do everything
10:53:08*chemist69_ quit (Ping timeout: 276 seconds)
10:54:13GordonBGoodYes, guess we can't see how much of a problem it might be unless we try
10:55:59*chemist69 joined #nim
10:57:40Araqthere are other problems like "=trace doesn't even work", tracing is only one step, you also need to be able to access a ref object's header
10:59:21Araqor to put it differently: you need to be able to pass some state around, you might need multiple passes
11:00:37Araqso the signature should be =trace(x: var T; arg: int) or =trace(x: var T; arg: pointer)
11:01:37GordonBGoodI think that was what clyybber was saying in "but what does it do?"
11:05:20*LargeEpsilon quit (Ping timeout: 265 seconds)
11:05:55Araqah ok
11:06:08*Vladar quit (Quit: Leaving)
11:06:31Araqhowever, passing parameters automatically around to =trace might not be exposed
11:06:54Araqso the =trace is a declarative way to teach some algorithm how to traverse
11:07:21Araqand we "automatically" pass on additional parameters
11:07:40Araqseems hard to implement though.
11:10:28*abm joined #nim
11:13:29GordonBGoodYes - hard to implement
11:16:48Araqarg: pointer is it then :P
11:18:31GordonBGoodThat way the arg: pointer can be anything as required by the implementation
11:19:04Araqyeah, it can even be a .nimcall proc
11:19:24GordonBGoodseems the most flexible option
11:19:39clyybberarg: No cycle detection it is then :p
11:19:48Araqhuh?
11:19:49clyybberjust use "weak refs"
11:19:51clyybberaka pointers
11:19:53clyybberlol
11:19:58clyybberim jk (mostly)
11:20:54GordonBGoodclyybber: I think we might be able to get cycle detection tied in with this arg: pointer, but will have to think about how...
11:22:36GordonBGoodIt seems to me that once a =trace chain is triggered (somehow), then we can do anything, include triggering a sweep pass
11:23:52Araqnope, it's fundamentally different
11:24:18Araqcycle trial deletion starts from inside a subgraph, ordinary tracing starts from the stack/global roots
11:24:44clyybberI though =trace would start from inside a graph?
11:24:52Araqglobal tracing requires something like pushLocalRef/popLocalRef
11:25:20Araqwhich is why these things are hard to design, every algorithm requires its own API :P
11:25:56clyybberhmm.
11:26:53GordonBGoodNot that I like it, but the second pointer arg could point to a table of global roots and even this objects place it it?
11:27:06GordonBGoodin it
11:27:51clyybberAm I right that if we disallow cyclic refs we don't need =trace?
11:28:12GordonBGoodsince we are talking about completely customisable hooks
11:28:47Araqclyybber, maybe yes, maybe it's also useful for incremental destruction
11:29:04Araqwhere you leave stuff "to be freed" on a queue for later processing
11:29:16GordonBGoodclyyber: if we could figure out which refs are never going to be changed to cycle, then obviously cycle detection is never needed ;-)
11:29:52GordonBGoodSorry, clyybber
11:30:11clyybberfor what?
11:31:21FromDiscord<demotomohiro> Please review this PR: https://github.com/nim-lang/Nim/pull/11748
11:31:34GordonBGoodclyybber, how would you disallow cyclic ref's programaticallly when he can modify them to become cyclic at any time?
11:32:02clyybberAraq: I see. Though that can be done with =destroy already
11:32:26clyybberGordonBGood: Oh, just do it the rust way: Say they will leak
11:32:35Araqdemotomohiro: it that really a good idea though?
11:33:08Araqoh sorry
11:33:13Araqnever mind, merging it
11:33:55Araqcould have added a changelog entry though :P
11:34:03FromDiscord<demotomohiro> OK
11:34:48*noonien joined #nim
11:35:36FromDiscord<demotomohiro> Can I add changelog entry after PR merged?
11:36:18FromDiscord<demotomohiro> Or should I send new PR just add a changelog entry?
11:37:22Araqalready merged it, new PR for the changelog entry please
11:37:45FromDiscord<demotomohiro> ok
11:37:52GordonBGoodclyybber: rust reference counted can leak, can the usual "controlled" fields cause leaks too?
11:39:33clyybberI don't think so
11:39:41clyybberBut yeah I was referring to rusts Rc
11:41:10*nif quit (Quit: ...)
11:41:20*nif joined #nim
11:50:26*rockcavera joined #nim
12:06:18FromGitter<geotre> How does the compiler handle objects too large to fit on the stack? And does that also affect the JS backend?
12:10:13*nsf quit (Quit: WeeChat 2.6)
12:10:13clyybberAraq: How exactly would one implement cycle detection with =trace though?
12:13:31AraqI don't know yet
12:21:53FromDiscord<demotomohiro> azure-pipelines ignores [ci skip].
12:21:53FromDiscord<demotomohiro> https://github.com/nim-lang/Nim/pull/12541
12:23:14Araqthat's good, usually [ci skip] is misused
12:23:31Araqdocumentation is run through tools too and it can fail
12:23:39*salewski joined #nim
12:24:53clyybberazure is fast enough anyways
12:26:16salewskidjazz, for your gstreamer request from https://irclogs.nim-lang.org/14-10-2019.html#07:22:22
12:26:47salewskiI have just shipped it to github, hope it works for you. Bye.
12:27:05*salewski quit (Client Quit)
12:28:43narimiranmaybe it ignores it because there was no space before `[`?
12:28:46FromDiscord<demotomohiro> CI should run even if a PR only change `changelog.md`?
12:29:03narimirani'm merging this immediately
12:29:45narimiranha, see, i added a space and it doesn't run now on devel branch
12:34:29FromDiscord<demotomohiro> narimiran, thx!
12:36:24stefantalpalaru@demotomohiro: use [skip ci] instead of [ci skip]
12:36:31shashlick@PMunch no clean solution for that yet, Nim doesn't have forward declarations
12:40:20FromDiscord<demotomohiro> @stefantalpalaru, doc/contributing.rst says `add [ci skip]`.
12:41:52stefantalpalaruLooks like both are supported: https://docs.microsoft.com/en-us/azure/devops/pipelines/build/triggers?view=azure-devops&tabs=yaml#skipping-ci-for-individual-commits
12:42:08stefantalpalaruJust make sure you add it on the first line of the message.
12:43:36clyybbernarimiran: Can the old CI's be disabled by now?
12:44:04narimiranclyybber: they are disabled for PRs, they are only enabled for devel, which is enough to make things much faster
12:44:11PMunchshashlick, I hacked something that works by creating a "somename = somenameImpl" definition and then later adding "somenameImpl = <actual fields>" when the symbol had already been seen.
12:45:15narimiran...and this way we have a double-checks when things get merged into devel. win-win, IMO.
12:46:13shashlick@PMunch right now, nimterop moves all types into one type call at the top before procs
12:46:13FromDiscord<demotomohiro> @stefantalpalaru I added [ci skip] in first line but azure-pipelines ran.
12:46:14FromDiscord<demotomohiro> https://github.com/nim-lang/Nim/pull/12541
12:46:46shashlickSo that handles all cases where types might be declared after procs
12:47:21PMunchYeah, but it doesn't handle a forward declaration of a struct
12:47:27shashlickBut I think it might be as easy as moving the full declaration where the forward declaration was defined
12:47:36narimiran@demotomohiro, stefantalpalaru it was because there was no space before `[`, so you had `#11748[ci` as a "word". `[ci skip]` works as intended on pipelines
12:47:36PMunchCreated an issue for this here: https://github.com/nimterop/nimterop/issues/148
12:47:44stefantalpalaruYeah, could be that missing space before the opening bracket that stumbled Azure's parser.
12:48:01PMunchWell yeah, if you just ignore empty struct definitions that would solve it in this case
12:48:09shashlickCause Nim can do forward declarations in the same type call
12:48:12narimiranstefantalpalaru: it is not "it could be", it is exactly that.
12:48:16PMunchBut not sure if those are valid and used for something elsewhere..
12:48:27shashlickThat doesn't work cause sometimes people make opaque types
12:48:33shashlickNo way to tell without tracking
12:49:13PMunchI guess it should do tracking then..
12:49:50shashlickCan you check if moving the declaration to the top works when cOverride
12:50:06shashlickMight want to update to latest nimterop
12:50:13PMunchI am on latest
12:50:18shashlickCool
12:50:23PMunchI was hacking around with it as well, but I think I've reverted back now
12:50:48shashlickWhat are you wrapping
12:50:59PMunchunbound
12:50:59clyybbernarimiran: Ah, cool
12:51:06PMunchIt's a DNS server
12:51:07shashlickOk cool
12:51:13shashlickI'll look into this
12:51:24PMunchI have a PR in to make it able to load dynamic libraries, and I wanted to try and write one in Nim
12:51:58PMunchEssentially this is what I'm trying to replicate: https://github.com/PMunch/unbound/blob/master/dynlibmod/examples/helloworld.c
12:52:19PMunchBut those two includes just won't work with nimterop :P
12:52:41shashlickYa you mentioned that before
12:52:52shashlickI need to see it in detail
12:54:08lqdev[m]shashlick: does cImport import #defines?
12:54:30*dddddd joined #nim
12:55:32lqdev[m]or are they skipped because the preprocessor is ran on the source files before toast has a chance to see them?
12:58:50*LargeEpsilon joined #nim
13:05:23shashlickNo I retain #defines with -dD
13:05:35shashlickAnd can import numeric defines
13:05:46shashlickInt float and hex
13:05:57shashlickThose get wrapped as const
13:07:01lqdev[m]yeah, what about unsigned integers like 0x100u?
13:07:18shashlickI don't think the u is covered today
13:07:43lqdev[m]that's pretty bad, SDL uses it for bit sets
13:08:08shashlickhttps://github.com/nimterop/nimterop/blob/master/nimterop/getters.nim#L198
13:08:11shashlickEasy fix
13:08:22lqdev[m]I can contribute when I get home
13:09:01shashlickI need to push my performance pr
13:09:16shashlickMade some reductions in regex use
13:09:33lqdev[m]how much faster?
13:12:13shashlickThe sdl toast wrapping went from 1.4 to 0.8 sec but hard to tell if it's real
13:12:35shashlickPlus no impact yet on cimport stuff which happens as CT
13:12:43lqdev[m]wow, that's an amazing improvement
13:13:03shashlickWill push in a little bit
13:15:54lqdev[m]will test later
13:17:51shashlick@PMunch, can you share what you have for unbound so far including your helloworld translation
13:18:38PMunchWhat do you mean?
13:19:14PMunchI haven't gotten to implementing the helloworld example because I'm still trying to get the files importent properly..
13:20:29shashlickOk please share what you have and I'll try on my side
13:20:42shashlickPresume Linux?
13:20:48PMunchYeah
13:21:00PMunchI've tried a couple different things
13:21:44PMunchWhat I'm trying right now is to first concatenate together all the files, pass them through the pre-processor, and then sed out the forward declarations and includes before passing it to nimterop
13:21:54PMunchBut it turns out I missed some files..
13:22:07PMunchEverything includes everything else in this project it appears..
13:22:33FromGitter<alehander42> which lib is that
13:22:43PMunchUnbound
13:23:18PMunchIt's not acutally the library version though
13:23:31PMunchI'm trying to wrap all the development headers so I can create a DLL for it.
13:23:38shashlickI can add a feature to cimport to concatenate for you if you think that will be helpful
13:23:55PMunchThat would help with the circular dependencies
13:23:58shashlickWhy not link to static lib
13:24:23PMunchUnbound the program can load a dynamic library on runtime, I want to create such a library in Nim.
13:24:59shashlickOk yes, going the other way
13:26:05PMunchThis example shows the six procedures I need to implement: https://github.com/PMunch/unbound/blob/master/dynlibmod/examples/helloworld.c
13:27:57PMunchThose structures are the problem, the module_env structure spans 202 lines..
13:28:56PMunchmodule_qstate is 68 lines
13:29:10PMunchAnd of course they point to further structures..
13:31:20PMunchThis file might include some hints as to what I actually need, it's for the loadable Python modules: https://github.com/PMunch/unbound/blob/master/pythonmod/interface.i
13:44:04*LargeEpsilon quit (Ping timeout: 268 seconds)
13:44:50*nsf joined #nim
13:57:01clyybberAraq: Whats the reason for BeforeRet_ instead of a simple return?
13:58:44Araqclyybber, to run finally blocks before the return
13:59:17clyybberAh
14:04:02*Vladar joined #nim
14:20:17clyybberAraq: So am I right that a `return a` is basically `result = a; return` ?
14:20:27Araqsure
14:20:54clyybberShould I move that transformation from backend to transform, while I'm at it?
14:22:16Araqis that possible?
14:22:22clyybberI think so.
14:22:24Araqthe ast lacks 'goto'
14:22:46clyybberWe will just do a nkReturnStmt
14:23:05Araqwait a sec
14:23:22Araqthe frontend already does it, it produces the rather weird 'return result = value'
14:23:45Araqthat you then have to work around in 'typed' macros (so terrible...)
14:25:06FromDiscord<treeform> gogolxdong, Color does have hash proc, https://github.com/treeform/chroma/blob/master/src/chroma.nim#L21 could you have old version or some thing?
14:25:14clyybberAh, yeah thats ugly. It should be `return value` instead for the frontend I suppose
14:25:48FromDiscord<Rika> @treeform you misspelled hashes in that doc comment ๐Ÿ˜‰
14:26:07clyybberAraq: So I'd get rid of the frontend transformation and the codegen stuff and do it in transf.nim, WDYT?
14:26:17FromDiscord<treeform> @Rika yes I did.
14:26:47FromDiscord<Rika> grayscale support when :V
14:28:31federico3https://news.ycombinator.com/item?id=21356203 Best language to share code between an Android and iOS app?
14:29:42narimiran"It transpiles to C" triggered
14:30:23clyybberUgh, the first comment chain
14:30:31clyybberJust write the app twice, problem solvd
14:30:32narimiranAraq: how about we modify the nim license so if you publicly mention 'nim' and 'transpile' in the same sentence, you are now obliged to pay $1000 per month for license fee
14:30:40clyybberuse SaaS noone will ever notice.
14:30:42clyybberhaha
14:31:20Araqnarimiran, sounds like an idea
14:31:27FromDiscord<Rika> why so triggered, im confused about how nim compilation works
14:31:41clyybbergcc is a transpiler
14:31:46clyybberit transpiles to asm
14:31:48narimiranthere, Rika, you used correct word, congrats.
14:32:04narimiranthat's all there is. it is compiled language.
14:32:25clyybberHmm
14:32:47clyybberI guess correct would be to use compiler for something that transforms something with global knowledge
14:33:03FromDiscord<treeform> @Rika, you gray scale any color with `.desaturate(1)`.
14:33:05FromDiscord<Rika> "Compiling is the general term for taking source code written in one language and transforming into another
14:33:05FromDiscord<Rika> Transpiling is a specific term for taking source code written in one language and transforming into another language that has a similar level of abstraction"
14:33:14narimiranyay, bikeshedding time again
14:33:24clyybberRika: Oof. Dumb definition though
14:33:33FromDiscord<Rika> thats what i saw on the webz
14:33:35Araq"similar level of abstraction" is meaningless
14:33:41clyybberExactly
14:34:10FromDiscord<Rika> got a good definition?
14:34:15clyybberCompiler includes compile so I guess it collects everything and puts it together in a global context
14:34:21FromDiscord<treeform> Is coffeescript a transpiler?
14:34:24FromDiscord<Rika> cuz i cant find anything not mentioning abstraction
14:34:25clyybberThink so
14:34:27Araqhint: "C is close to the machine" and yet producing native code takes LLVM millions of lines of code.
14:34:28FromDiscord<Rika> yes i think it is
14:34:37FromDiscord<treeform> is typescript a transpiler?
14:34:40FromDiscord<Rika> yes
14:34:48clyybberAraq: So wdyt on my above message?
14:35:11FromDiscord<treeform> but typescript does whole program typechecking?
14:35:39FromDiscord<Rika> i dont know anymore man there isnt a good definition for transpilation
14:36:02Araqclyybber, improving this would be nice but beware it's a breaking change
14:36:20Araqeven though the 'typed' AST lacks a spec people can rely on it
14:36:21clyybberYeah, I know.
14:36:30FromDiscord<Rika> i think nim compiles though, since theres a lot of things in nim not in c, but that is merely my interpretation of transpilation
14:37:17FromGitter<alehander42> i kinda agree with that on intuitive level
14:37:30FromGitter<alehander42> as typescript itself is also pretty complicated, but more people call it a transpiler
14:37:40FromGitter<alehander42> just because it mostly reuses the syntax
14:37:50FromGitter<alehander42> supersets* ?
14:38:00AraqC++ used to be seen as "preprocessor" back then when it compiled to C.
14:38:36FromGitter<alehander42> yeah, its basically , if it becomes complicated enough, people start calling it a compiler
14:38:55FromGitter<alehander42> which reminds me
14:38:56Araq"transpiler" will take the route of "preprocessor", it'll be a dead word soon
14:39:05Araqbecause it's useless.
14:39:07FromGitter<alehander42> are there any c preprocessor parser/evaluator libs
14:39:20FromGitter<alehander42> like, letting you evaluate and process the directives themselve
14:39:23FromDiscord<Rika> i agree transpiler is hard to define
14:39:38FromDiscord<Rika> its too difficult to define an abstraction level between languages
14:39:47FromGitter<alehander42> it seems like it should be something not too hard that people need, but i cant seem to find a great resource for it, maybe libclang
14:40:24FromGitter<alehander42> i feel a bit like that for interpreter and vm
14:40:47FromGitter<alehander42> what is an interpreter? something that directly evaluates string/ast ? so if i just generate elementary "opcodes", it becomes a vm?
14:41:07FromGitter<alehander42> but in a sense, you can say that the ast is a type of ir anyway
14:42:18FromDiscord<treeform> Is Java a compiler bc it compiles to byte code?
14:42:26FromGitter<alehander42> and "vm is more like something working like a cpu" , well dunno abou tthat
14:42:27FromDiscord<Rika> yeah afaik
14:42:33Araqbut here is the thing: Nowbody corrects "Python is interpreted" to "no, dude, Python is vm'ed"
14:42:41FromDiscord<treeform> Is python a compiler bc it compiles to byte code?
14:42:54FromGitter<alehander42> but it python a vm or an interpreter
14:43:00FromGitter<alehander42> the cpython vm *
14:43:14FromGitter<alehander42> well, ive seen
14:43:15FromDiscord<treeform> Python is a preprocessor
14:43:22FromGitter<alehander42> people dissing stuff as "this is just an interpreter"
14:43:29AraqPython includes a compiler to its own VM
14:43:52FromGitter<alehander42> and i feel people often see python/ruby as "interpreters" vs c#/java complicated vm-s
14:44:13FromDiscord<treeform> It's probably just marketing
14:44:35Araqwell the terminology makes more sense as C#/java are JITs and a JIT really is a bit different from a bytecode VM
14:44:41FromGitter<alehander42> i think its the same as transpiler/compiler: if the vm does "complicated" stuff like jitting etc
14:44:46FromGitter<alehander42> it becomes a "vm"
14:45:04Araqand the name "LuaJIT" gives it away too.
14:45:14FromGitter<alehander42> yeah, but you see: this doesnt mean the other one is not a vm, in the same way, a compiler which doesnt do type checking can still be a compiler
14:45:55Araqan assembler takes your assembler code and compiles it to machine code.
14:46:53Araqperfectly fine, "compiling" is not limited to "blah complex transformations required because of abstraction"
14:47:22*GordonBGood quit (Remote host closed the connection)
14:47:35FromGitter<alehander42> yes
14:47:56FromGitter<alehander42> and thats my point a "vm" is not limited to "specific kind of interpreter that JIT-s code"
14:48:07PMunchHmm, I have `proc log_info(formatstr: cstring) {.importc: "log_info", varargs.}` but I get an error about conflicting types..
14:48:31PMunchBecause it creates a N_NIMCALL definition for it in the C code..
14:48:31AraqPMunch, .importc, header: "..."
14:49:11FromGitter<alehander42> and preprocessing is a form of compilation as well
14:49:16Araqhttps://docs.python.org/2/library/compiler.html#compiler.compileFile
14:49:30FromGitter<alehander42> similarly to html template evaluation and many similar things
14:51:57Araqa Pentium is a VM, it translates x86 instructions into ยตops
14:52:22Araqbtw, "Deprecated since version 2.6: The compiler package has been removed in Python 3."
14:52:40Araqso what should we use in Python 3 instead?
14:52:50PMunchThat gives me about a trillion error messages..
14:53:31PMunchI have an emit at the beginning of my file with two imports I need, one of them also includes log.h, but adding it as header means that tries to import first, which doesn't work.
14:53:57AraqPMunch, use .nodecl then
14:54:12Araqbut usually .header is better than .nodecl
14:54:16FromGitter<alehander42> i think only `ast` ?
14:54:28FromGitter<alehander42> ah, `compiler` does the pyc thing
14:54:52PMunchWoo, that worked
14:55:03FromGitter<alehander42> https://docs.python.org/3/library/py_compile.html
14:56:52clyybberAraq: Regarding result, what do you prefer: Inserting a `var result` into every proc body in transf.nim (tried that just now, seems to work just fine), or doing it in the backend?
14:58:36FromGitter<alehander42> dont forget we have many backends
14:58:51clyybberWe do it this way rn
14:58:58clyybberIn the backends
14:59:05FromGitter<alehander42> so does it break the javascript backend somehow
14:59:19FromGitter<alehander42> ah, isnt it too much repetition currently
14:59:41clyybberalehander42: Its about 1-3 lines actually
15:00:16clyybberI mean generating NIMRETURNTYPE result; specifically
15:00:29clyybberThe whole result variable mechanism is deeply integrated into nim
15:01:28Araqclyybber, it needs to be done in the backend, the backend does some variant of NRVO for us
15:02:11FromDiscord<++x;> Spam
15:02:14clyybberOk, I agree with you. Seems hard to replicate that logic in transf.nim
15:02:24clyybber++x; No u
15:03:13FromDiscord<kodkuce> Justice for nim
15:03:41FromDiscord<++x;> Someone said compiling means to transform a language into another. That is incorrect
15:03:51clyybberUgh
15:03:55clyybberNo its not
15:04:59FromDiscord<++x;> So you are saying python compiles it's code?
15:05:40Araqyeah and the Python devs do say this too, see https://docs.python.org/2/library/compiler.html#compiler.comp
15:05:42clyybberYeah, to python vm code
15:06:08FromDiscord<++x;> But compiling doesn't mean ti transform a language into another. That just messes up the whole compiler theory
15:06:27FromDiscord<++x;> That's not even what makes a compiler and compiler
15:06:32PMunchHmm, Araq when I'm creating a DLL/so that will be loaded by another program. I compile with --app:lib, but is there anything else I need to do in the first procedure that's going to be called to get the GC up and running?
15:08:43Araqyes, but check the docs
15:08:45FromDiscord<++x;> What makes a compiler and compiler is its stage of processing a language to byte data to an executable then to assembly. Simply tranforming one language to another isn't what makes a compiler a compiler. That's like the worse logic i have ever seen
15:08:55PMunchWhich ones?
15:09:04PMunchI'm trying to find them, but failing..
15:09:11clyybber++x; Um, assembly is a language duh
15:09:24clyybber++x; So is an ISA
15:10:26FromDiscord<++x;> Assembly is a language. But you guys have abstracted views, transforming one language to another doesn't define a compiler. It's about what happens to it's core
15:10:33clyybberWhere you draw the line between compiler and transpiler is up to you, but I'd say something like a regex to replace some keywords is a transpiler, a regex with global knowledge type inference and stuff is a compiler
15:10:50clyybber++x; Yeah, nobody said its the definition
15:11:28AraqI've read several books about compilers, nowhere was "must produce native code" in the definition of what a compiler is
15:11:44zedeusthe simplest definition I've seen is that a transpiler typically translates one language to another of a similar level, while a compiler translates to a language of a lower level
15:11:55clyybber++x; But it's one important aspect of it, and perhaps the one that stays true all the time
15:12:08Araqok, I'm out, have work to do
15:12:09clyybberDepending on wether you consider a circuit a language too
15:12:20clyybberAraq: bb, are u working on bugs?
15:12:26FromDiscord<++x;> If you were to write a program that tranformed java into C, with a plain core functionality of no actual compiler. Then your program wouldn't be a compiler although it transformed one language into another
15:13:17FromDiscord<++x;> It would just be a program that changed one language to another. And not a compiler
15:13:52FromDiscord<kodkuce> why are you all even having discussion about if its copiler or not who gives a crap
15:14:00FromDiscord<++x;> Lol.
15:14:16FromGitter<zetashift> Seems like a discussion for #offtopic or #nim-lang/twitch
15:14:21stefantalpalaruKeep in mind that C is a high-level language, so defining "transpiler" as a subset of compilers targetting high-level languages has practical uses. That way you don't put C and Python3 in the same category an account of both being "compiled".
15:14:22FromGitter<alehander42> ++x; but thats just not true
15:14:35stefantalpalaru*on account
15:14:37FromGitter<alehander42> people call the parts of c# / java which generate bytecode
15:14:40FromGitter<alehander42> compilers as well
15:15:18zedeusstefantalpalaru: while that's true, I think it's fair to say that is lower than Nim while still being "high-level" according to the classical "everything above machine code and assembly is high-level"
15:15:31clyybber++x; Yeah than its a transpiler
15:15:55clyybberOr a compiler, depending on where YOU draw the line
15:16:11*PMunch quit (Quit: Leaving)
15:16:29clyybberYou can of course define where you draw the line and put it in a textbook, but if no one reads it oh well
15:16:54FromDiscord<++x;> Alehander it is true. Your program wouldn't be a compiler it would be a program that changed a language to another. Like it had no core functionality of a compiler. It didn't follow no compiler theories. If you made a program that you manually added like a c syntax so when a user enter a certain java code, then it outputs the C code that you pretty much manually put into the program then would that be a compiler? No but did it transform one la
15:17:07FromDiscord<Rika> hey ++x;, do you have a source for that definition
15:17:10FromDiscord<Rika> im interested in seeing it
15:17:14FromDiscord<++x;> So my point is that because something changes a language into another language doesn't always mean it's a compiler
15:17:15FromGitter<alehander42> i am talking about your statement that
15:17:24FromDiscord<Rika> been looking for a definition for a while
15:17:27FromGitter<alehander42> a compiler has to generate assembly or executale
15:17:32FromGitter<alehander42> which is not true
15:17:52FromDiscord<++x;> @Rika there is no definition to this. It's simply compiler theory
15:17:59FromDiscord<Rika> the fuck is compiler theory
15:18:09FromGitter<alehander42> ++x; we all know what compiler theory is mate
15:18:16FromDiscord<++x;> Rika doesn't
15:18:17FromGitter<alehander42> the point is, where does one put the line
15:18:19FromDiscord<++x;> Apparently
15:18:24stefantalpalaruTrue or not, that distinction is very useful when looking for a rule of thumb for evaluating the runtime performance of resulting programs.
15:18:31FromDiscord<Rika> totally, am not a CS major
15:18:38FromDiscord<++x;> ok
15:18:56FromGitter<alehander42> e.g. if you input java and output c and write your own lexer/parser: you apply compiler theory
15:19:05FromGitter<alehander42> the problem with yoour def is
15:19:16FromGitter<alehander42> that it is basically "its a compiler if its complicated enough"
15:19:18clyybberyou don't need to follow compiler theory to have a compiler
15:19:42FromDiscord<++x;> But your program isn't a compiler
15:19:47FromGitter<alehander42> thats also true, you can directly analyze raw string input and generate x64 assembly
15:19:58clyybberthats like saying its not a computer if it doesn't follow neumann architecture
15:20:00FromGitter<alehander42> without ast and without much of type checking
15:20:20FromDiscord<++x;> That's not what I'm saying
15:20:32FromGitter<alehander42> but why isnt a java->c not a compiler
15:20:55clyybber++x; No, even a translator can be considered a compiler, you put in korean imperatives and it outputs them in english for your workers to execute
15:21:08FromGitter<alehander42> it uses lexer => parser => type checker to check if the java code is right => code generator
15:21:11FromDiscord<++x;> If i gave you a box would you call it a computer?
15:21:16clyybber++x; Yes
15:21:21FromGitter<alehander42> its an absolutely great example of a compiler
15:21:29FromDiscord<++x;> So you would call a cardboard box a computer?
15:21:33clyybberSure
15:21:37FromDiscord<++x;> Lmao
15:21:40FromDiscord<Chiqqum_Ngbata> lol
15:21:42clyybberIf theres a turk inside that plays chess :p
15:22:00FromDiscord<Rika> what the hell is happening
15:22:16FromDiscord<++x;> Rika would you call a cardboard box a computer?
15:22:54FromDiscord<Rika> uh depends on the definition of computer
15:22:55FromGitter<alehander42> ++x; you mean that there are computers which are not from cardboard ?
15:22:58clyybber++x; Put a thermostat in the middle of the box, boom. Now it computes the average of the temperature of its 6 walls
15:23:13FromDiscord<Rika> generally no i wouldnt
15:23:18FromGitter<alehander42> i knew the west has some new tech
15:24:19clyybber++x; Though you could of course say that it needs to be turing complete to be a computer. But then again nothing is ever turing complete in practice.
15:24:35clyybberNow lets say we just put thousands of these boxes together
15:24:36narimiranlook at all the potential money we could have had if only we had the license i proposed a bit earlier....
15:24:56clyybberI'm sure we can somehow construct a turing complete system out of these cardboxes.
15:25:16clyybberbbl
15:25:29FromDiscord<++x;> Okay so generally you wouldn't call it a computer. So in other words alehander what you said to me about that computer metaphor would be pretty much true. It's not a computer without certain things
15:26:00FromDiscord<++x;> Like it's just not a computer without certain things. No one would realistically call a plain box as a computer
15:26:12narimiranhow about y'all just cut it out now, huh?
15:26:33FromDiscord<++x;> Lol
15:26:55FromDiscord<++x;> This debate is actually quite funny. It just keeps going from realism to fantasy
15:27:25FromGitter<alehander42> but i didnt say
15:27:28FromGitter<alehander42> anything about a computer
15:27:34narimiranit is a never-ending story and in the end nobody changes their opinion. no point in discussing it in #nim, but feel free to continue in #bikeshedding or some other channel
15:27:59FromDiscord<++x;> You did say something about a computer actually. Scroll up and look at your metaphor again
15:28:42FromGitter<alehander42> but the only thing i said is
15:28:45FromGitter<alehander42> "++x; you mean that there are computers which are not from cardboard ?"
15:28:59FromDiscord<++x;> No you said something before that too
15:29:00FromDiscord<Chiqqum_Ngbata> In common parlance "computer" refers to digital transistor-based computer unless qualified otherwise e.g. quantum-computer. Anyway, I agree about the offtopic comment thing. We all like computers (even of the cardboard box composition)
15:29:03FromGitter<alehander42> but i didnt
15:29:06FromGitter<alehander42> scroll up yourself
15:29:08stefantalpalaruSo it's settled then, we're changing the homepage to say Nim is a garbage-collected transpiler with slightly different transpile-time and runtime semantics?
15:29:09FromGitter<alehander42> hehe
15:29:40FromDiscord<Rika> jesus narimiran already said to take it to another channel
15:29:48FromDiscord<++x;> Lol
15:30:34FromGitter<alehander42> at least i couldnt find another quote sorry
15:30:38FromGitter<alehander42> ok guys lets talk about
15:30:52FromDiscord<++x;> Let's talk about uhhhhh
15:30:54FromGitter<alehander42> templates/macros: do you find it hard to debug your template expansions
15:31:32FromDiscord<Rika> no since my templates are usually simple
15:33:14FromDiscord<++x;> Anyone that would use a language that relies heavily on templates *cough* C++ *cough* are automatically a noob programmer.
15:33:40stefantalpalaruLet's talk about replacing the VM with a compilation step so we avoid maintaining two parallel implementations: https://github.com/nim-lang/Nim/labels/VM
15:34:20clyybberstefantalpalaru: But its actually pretty cool to have a VM
15:34:28stefantalpalaruThanks. I hate it.
15:34:56FromGitter<alehander42> i actually think its a easy way to get a repl
15:35:03FromGitter<alehander42> with timothee's vm ffi enabled
15:35:11clyybberOne idea was to make it ouput c snippets that are run with tinyc
15:35:14FromGitter<alehander42> and reusing the `inim` frontend
15:35:15stefantalpalaruI don't need a REPL.
15:35:18clyybberBut I actually like the VM nowadays
15:35:20FromGitter<alehander42> i do
15:35:35clyybberstefantalpalaru: But you are a subset of the nim users
15:35:44FromGitter<alehander42> ++x; nim's templates are different
15:36:01FromDiscord<Rika> not everyone has the same opinion stefan lmao
15:36:02FromDiscord<++x;> It's been a while since i have written anything in nim soooo
15:36:20stefantalpalaruHaskell manages to fake a REPL without a VM.
15:36:20clyybberstefantalpalaru: YOu can even embed the VM at runtime and use it as a scripting language in a game or something
15:36:30*seni joined #nim
15:36:33FromDiscord<++x;> Actually i have messaged in this server for like a long time
15:36:44clyybberstefantalpalaru: Nim manages too, but see my message above
15:36:58FromDiscord<++x;> But i can just tell you guys that something big will release soon
15:37:00shashlickwhat a waste of time
15:37:06FromDiscord<++x;> And it will be amazing
15:37:11FromDiscord<Rika> what use case?
15:37:44FromGitter<alehander42> but stefantalpalaru
15:37:45FromDiscord<++x;> I wouldn't be surprised if you guys wouldn't like it because it's kinda out of your leagues
15:37:49clyybber++x; Ooh, care to tell what?
15:37:50FromGitter<alehander42> ghci is an interpreter imo
15:37:52FromGitter<alehander42> isnt it
15:38:09stefantalpalaruIt does on-the-fly compiling, IIRC.
15:38:28FromDiscord<Rika> whats wrong with a VM?
15:38:31shashlickthere's only compilers and interpreters
15:38:32FromDiscord<Rika> extra maintenance?
15:38:32FromGitter<alehander42> thats the hcr-based idea, so maybe its a better way to do a repl
15:38:38clyybberRika: Yeah
15:38:39FromGitter<alehander42> but anyway, this is not the main argument
15:38:44FromDiscord<Rika> i see
15:38:46FromDiscord<++x;> VM is garbage
15:38:50clyybberNope
15:38:54FromDiscord<++x;> yes
15:39:19clyybbergood point
15:39:22FromDiscord<++x;> I just feel like debating for no reason just to laugh
15:39:26clyybberlol
15:39:36FromDiscord<Rika> this sounds less debate more petty fight
15:39:36FromGitter<alehander42> there are many nimscript usages
15:39:52clyybberRika: Noones serious
15:40:13FromDiscord<Rika> if you havent noticed i am pretty awful at understanding nuances like such
15:40:18FromDiscord<++x;> @Rika why so serious
15:40:27FromDiscord<Rika> see above message
15:40:51FromDiscord<Rika> its hard for me to not know seriousness without tone :/
15:41:00FromDiscord<++x;> Oh *puts on joker mask* why so serious rika, do you want me to blow your top off?
15:41:05FromDiscord<++x;> Okay I'll stop now lol
15:41:26FromDiscord<++x;> By top I'm referring to your head so nothing sexual
15:41:33FromGitter<alehander42> stefantalpalaru so also i doubt recompiling each static expression and somehow loading the value back to the running nim compiler would be very fast
15:41:38shashlickmind you are taking away the opportunity for people to ask legitimate questions with this debate
15:41:42FromGitter<alehander42> i mean, it seems people have some idea how to o it
15:41:49FromDiscord<Rika> oh how lewd
15:42:04clyybberRika: It is kinda hard to get those on IRC
15:42:09clyybberThats what emojis are for
15:42:18clyybberBut I don't have a font that supports them :D
15:42:24FromGitter<alehander42> but maybe i just cant imagine how
15:42:30FromDiscord<Rika> have an emoji you wont see then ๐Ÿค”
15:42:41FromDiscord<++x;> Lol
15:42:45clyybber++x; What if I'm a dickhead??
15:42:54FromGitter<alehander42> you can have 150 simple const proc invocations adding to the same compile time state
15:43:12stefantalpalaru@alehander42, I'd rather have a slow but correct implementation than the current VM.
15:43:15FromGitter<alehander42> do you compiler/invoke a c program for each of those
15:43:19clyybberRika: I can still see them as a waay to big box. can't trick me :p
15:43:21FromDiscord<++x;> If you are a dickhead then i will be a bigger dickhead and together we will cum.
15:43:27FromDiscord<++x;> Wow that was too much
15:43:29FromDiscord<++x;> Off topic
15:43:42clyybber#nim-notopic
15:43:54FromGitter<alehander42> stefantalpalaru we all want more correct featurs
15:43:56FromGitter<alehander42> but if a feature becomes *too* slow, people stop using it
15:44:24clyybberstefantalpalaru: Just point at a specific bug and ping @krux02 until its fixed
15:44:25FromDiscord<Rika> clyybber have many "computers" :V ๐Ÿ˜„ ๐Ÿ˜„ ๐Ÿ˜„ ๐Ÿ˜„ ๐Ÿ˜„
15:44:29FromDiscord<Rika> ahahaha
15:44:30jkenlmariscal, you around?
15:45:08stefantalpalaruYou wouldn't do 150 separate compilations. You would combine them and label the various outputs in the resulting serialisation.
15:45:21FromGitter<alehander42> i tried to think of an alternative way to do it when i dreamed of a simple small greenfield nim implementation to test the spec
15:45:37FromGitter<alehander42> but i remember const evaluation seemed hard
15:45:44FromDiscord<++x;> On a scale from 1-10 how popular did nim become
15:45:53FromDiscord<kodkuce> 4
15:45:55clyybberstefantalpalaru: Ok so combine `echo static: 1 + 1; echo static: 2 + 2` please
15:45:56FromDiscord<Rika> echo scale.high
15:46:14FromDiscord<++x;> I remember when nim was at 1. I'm an OG user
15:46:26FromDiscord<Rika> someone in discord VC ๐Ÿ‘€
15:46:32FromGitter<alehander42> stefan, hm, they interact strongly with each other and with the rest of sem checking .. not sure you can combine them at all
15:46:33clyybberlol
15:46:36FromDiscord<kodkuce> spy
15:46:49FromDiscord<++x;> You guys are about to join the vc?
15:46:55FromDiscord<Rika> no i just see someone in the VC
15:47:09*neceve joined #nim
15:47:13FromDiscord<++x;> Go join it. And troll them
15:47:17stefantalpalaruinput1: "1 + 1", output1: "2", input2: "2 + 2", output2: "4"
15:47:20FromDiscord<Rika> theyre deafened
15:47:31clyybberstefantalpalaru: So you didn't join them
15:47:32FromDiscord<kodkuce> i would 200% just my mic unpluged
15:47:33FromDiscord<Rika> also cant you see them
15:47:42clyybberYou just compiled and ran two sessions
15:47:43FromDiscord<++x;> Yes
15:47:48FromDiscord<++x;> I can see them
15:47:50clyybbers/sessions/snippets
15:48:01FromDiscord<++x;> But I'm scared of voice chats
15:48:08stefantalpalaruOf course you join them with wrappers that do the labelling.
15:48:11FromDiscord<Rika> are you one of those "i have no voice" people
15:48:15clyybber++x; We track you by the sound of your fan
15:48:15FromDiscord<++x;> No
15:48:25FromDiscord<++x;> I am one of those
15:48:32FromDiscord<n-ks> Pressed by mistake, don't be alarmed that much.
15:48:32FromDiscord<++x;> "I don't want to talk to you" people
15:48:50FromGitter<alehander42> but stefan, you can have a macro which expands to a template which then expands to something else that invokes const evaluation
15:48:52FromDiscord<kodkuce> duno what to do with my life, meybe make Generals Zero Hour clone in Godot + Blender, or Fonline AoP or duno suicide meyeb
15:49:02FromGitter<alehander42> those things depend on each other's output
15:49:05FromDiscord<++x;> Track me by my fan. Wow
15:49:10FromDiscord<++x;> That is supernatural
15:49:11FromGitter<alehander42> not always you have a clean pure input
15:49:21FromGitter<alehander42> which is known after-parse-time
15:49:24FromDiscord<Rika> we can track you by the background static of your mic
15:49:25clyybber++x; Hook up some espeak and write to vc then
15:49:36FromDiscord<Rika> \/tts
15:49:44FromDiscord<Rika> tts exists in discord afaik
15:49:45stefantalpalaruSo you repeat the compile-time setp as many times as you need, combining as many bits of AST as you can per step.
15:49:57clyybberRika: Yeah, but you have to have the permission
15:50:10clyybberAnd people can only hear it when they are currently viewing the channel
15:50:12FromGitter<alehander42> but at this point this process becomes similarly bug prone and complicated in its own ways imo
15:50:26clyybberI agree with alehander42
15:50:31stefantalpalaruNo, because you're now using a single implementation, not two.
15:50:46FromGitter<alehander42> but now you created whole new fields of problems
15:51:03FromGitter<alehander42> like "assembling complicated puzzles of ast and collecting their outputs from a c program"
15:51:03stefantalpalaruFewer than the ones created by the VM.
15:51:10clyybberstefantalpalaru: Look at it like this: multiple implementations mean that we could have a reference implementation
15:51:34FromGitter<alehander42> yes, having two or more implementations is actually a thing most languages want
15:51:42stefantalpalaruThat's only a good thing if you're not forced to use both at the same time.
15:51:43FromGitter<alehander42> having one implementation sucks
15:52:09clyybberstefantalpalaru: Bugs can be fixed. And will be eventually.
15:52:16clyybberIt's not big problem
15:52:20FromGitter<alehander42> so if there are differences between nim vm and nim c behavior, this should be easy to reproduce
15:52:28FromGitter<alehander42> and just a bug
15:52:31clyybberYeah
15:53:29krux02There are currently many bugs in the VM and I am sorry that I didn't fix all of them.
15:54:52clyybberNo worries, the VM is great and you are making it better, thats all that counts.
15:55:12stefantalpalaruI guess it's a matter of how much you care about software quality in a toll as important as a compiler. Imagine having to hack on GCC code to get your C project compiled...
15:55:17stefantalpalaru*tool
15:55:26clyybber?
15:56:43jkenCan I allocate a string at a certain size? Like, if I have a type with a string attribute, can I specify that we should allocate the string to hold N chars immediately?
15:56:53FromGitter<alehander42> but fixing those vm bugs is so much less work
15:57:17FromGitter<alehander42> than writing this imaginary compile-based tool
15:57:58clyybberjken: You mean like an array for chars?
15:58:16clyybberjken: For a simple string just do it at creation time, newStringWithLen or something like that
15:58:30clyybberAh, I know. Either you do newStringWithCap
15:58:34clyybberOr you do setLen
15:58:53jkensetLen might be what I want, thanks clyybber
15:58:58clyybbernp
15:59:36FromGitter<alehander42> stefantalpalaru you can always write a rfc describing in better detail how would something like this really work
15:59:45*nif quit (Quit: ...)
15:59:46FromGitter<alehander42> it sounds cool theoretically
16:00:48clyybberI used to have the same view as stefan
16:01:11clyybberbut once I realised I could embed the VM for use at runtime I changed my opinion
16:03:30FromGitter<alehander42> stefan another option is to
16:03:52*nif joined #nim
16:04:10FromGitter<alehander42> generate javascript with the javascript backend and use a long running `node` instance with the compiler
16:04:16FromGitter<alehander42> but i guess you all people would hate it
16:04:31stefantalpalaruYou lost me at "node".
16:04:35FromGitter<alehander42> but it reminds me of the fact some people had a project to run rust macros in wasm
16:04:49FromGitter<alehander42> https://github.com/dtolnay/watt
16:04:58FromGitter<alehander42> not directly applicable, but fun idea
16:19:12krux02jken, you can't say that a type will be initialized with some allocation. Currently Nim has an important property that default values will never have side effects. Allocation counts as side effect.
16:19:51clyybberkrux02: Ah, yeah regarding that
16:20:20*nif quit (Quit: ...)
16:20:31*nif joined #nim
16:20:50clyybberNot so sure if we should really disallow that for object fields
16:20:55clyybberJust to keep a hack working
16:21:26clyybberI think we should just introduce a pragma like {.noAllocate.} that one can attach to objects
16:21:30clyybberand also to blocks
16:22:37*neceve quit (Ping timeout: 240 seconds)
16:22:44clyybberAh.
16:22:50clyybberNevermind
16:22:58krux02"no default value allocates" is an important property, that you don't just discard because of convenience.
16:23:09clyybberkrux02: AFAict my PR should already disallow that
16:23:22clyybberBecause only const values are allowed
16:23:25*nif quit (Client Quit)
16:23:30krux02seq can be const
16:23:35*nif joined #nim
16:23:41krux02but may not be a default value
16:23:48clyybberHmm. Ok
16:23:55clyybberRight
16:25:10krux02The only implementation that I would agree on for default seq/string values would be copy on write for seq/string, because then initialization would be allocation free.
16:25:47krux02In Nim everything has a default value, and default values are non allocating/throwing/crashing
16:26:26*neceve joined #nim
16:27:21krux02I this this is a big problem in C++.
16:27:22FromGitter<alehander42> krux02 : you can add noAllocDefault
16:27:29FromGitter<alehander42> instead of `default`
16:27:47FromGitter<alehander42> otherwise it seems to me having default fields becomes much less useful
16:27:53krux02In C++ default values can allocate, and they can throw, and they can be non-existent (no default constructor).
16:28:18krux02This makes writing exception safe code really problematic.
16:28:44krux02I think we live in a much better world if we enforce a default value on everytghing
16:28:58krux02and also enforce for default values to not be able to throw.
16:29:00FromGitter<alehander42> is there any other possible exception than OOM for allocation
16:29:08clyybberYeah
16:29:11clyybberSigsegv
16:29:21FromGitter<alehander42> huh
16:29:24clyybberWell
16:29:35clyybberI'm retarded
16:29:38clyybberdont mind me
16:29:49clyybbernevermind that
16:29:58FromGitter<alehander42> no that seems to happen indeed
16:30:05krux02the problem in c++ is, when allocation fails, it should throw an exception, an exception needs an allocation
16:30:27clyybberrecursion here we go
16:30:33clyybberyeah I understand
16:31:06*neceve quit (Client Quit)
16:31:26*neceve joined #nim
16:32:29clyybbergotta fix the bootstrapping problem
16:32:42FromGitter<alehander42> well, ok , maybe what i imagine is more like enforced constructor
16:35:50krux02alehander42: the only enforced constructor will be the default values
16:36:36krux02If we wouldn't already have these strage types where the zero mem state is an illegal state, I would even vote against default values.
16:37:16clyybberBut we do.
16:37:25clyybberAnd it is good that we do
16:37:29krux02I like a clear distinction between constructor functions (with logic that like any other function call), and just initializing some data.
16:37:44clyybberBecause if we just remove every nim feature except for the syntax we really have a transpiler
16:38:03krux02I like that there is clear visual difference. Something that works nice in C and in Go. But C++ blurrs that line. I don't like to blur that line.
16:38:16FromDiscord<++x;> A human body cell is class equivalent
16:38:39krux02++x; that is just trolling
16:38:49clyybberkrux02: Makes sense, I understand your point. But I also very much like having stuff "only" for convinience
16:39:19krux02I really am worried that because of "convenience" the language gets broken.
16:39:36krux02There is already too much stuff in there that I wish wasn't
16:39:43FromDiscord<++x;> Lol it's not trolling. A cell of a human actually has different characteristic
16:39:48krux02I am fighting hard against bad ideas.
16:40:03FromDiscord<++x;> That's metaphorically like a class in C++ with it's own characteristic
16:40:06*LargeEpsilon joined #nim
16:40:55clyybberkrux02: A {.noAllocation.} pragma/effect whatever would be nice tho
16:41:11clyybberFor procs
16:41:20clyybberIn general
16:41:23FromDiscord<kodkuce> make nim magic again
16:41:42FromDiscord<++x;> A human body would metaphorically have more side effects though
16:41:46krux02clyybber: I really don't like it.
16:41:58FromDiscord<++x;> Aka bacteria, aka environment genetic changing
16:42:00FromDiscord<++x;> Aka dieases
16:42:04clyybberkrux02: Why?
16:42:39krux02right now I don't need to ever write those magics, because their are universal truths. Now you want me to put that visual noise to every type I ever wrote and will ever write in the future. I am sorry. I really dislike that idea.
16:43:14krux02I don't want new magics that I now need to attatch to everything.
16:43:21clyybberUnderstandable
16:43:38krux02I have to go now
16:43:44clyybberbb
16:44:21FromDiscord<++x;> Lol
16:44:38*LargeEpsilon quit (Ping timeout: 265 seconds)
16:47:53FromDiscord<++x;> Come back alive chat
16:48:31FromDiscord<++x;> I won't let you die on me
16:48:38lqdev[m]yes
16:48:39FromDiscord<++x;> AHHHH
16:48:47FromDiscord<++x;> Oh you came back alive
16:48:58clyybberdont dead open inside
16:48:59FromDiscord<++x;> Seems like my cpr course really payed off
16:49:08clyybberwhats cpr?
16:49:14narimiranclyybber: ...but i know _this_ reference ;)
16:49:16lqdev[m]give me a sec, I'll open hexchat because matrix.org is laggy as always.
16:49:28FromGitter<alehander42> krux02: i think its a different idea
16:49:30narimiranclyybber: today i'll be sleeping better :D
16:49:32clyybbernarimiran: Nice :D
16:49:32*lqdev joined #nim
16:49:33FromGitter<alehander42> the point is that we want to have a
16:49:44FromGitter<alehander42> `{.noAlloc.}` to a custom user procedure
16:50:00FromGitter<alehander42> so i can prove that my custom procedure doesnt invoke anything which allocates
16:50:03clyybberYeah or have alloc as an effect
16:50:05lqdevthere we go. sweet 0.1s of ping
16:50:11FromDiscord<++x;> clyyber by cpr I'm referring to the medical technique.
16:50:15FromGitter<alehander42> this just makes sense: if there is a "allocates" truth in the language
16:50:24lqdevnow that's what I call real-time chat
16:50:44clyybber++x; nice
16:50:54FromGitter<alehander42> the problem is that it seems similar to the `{.blocking.}` thing to me
16:51:07FromGitter<alehander42> seemingly impossible to do with effects
16:51:17clyybberHow comes?
16:51:24clyybberHave allocates be an effect
16:51:35clyybberI don't know about {.blocking.}
16:51:35FromDiscord<++x;> Hexchat = bad
16:51:46FromGitter<alehander42> well it should work in the same way
16:51:55lqdev@++x; find me a better IRC client, then.
16:51:55clyybberBut I would love if nim embraces effects.
16:51:55FromGitter<alehander42> so if you think of how would `{.allocates.}` work
16:51:59FromGitter<alehander42> i'd love it
16:52:10FromGitter<alehander42> but the problem i think is in inferrence
16:52:20clyybberalehander42: My idea for the future is to have a =default typebounds op
16:52:34FromGitter<alehander42> interesting
16:52:34clyybberAnd default object fields would just be a subset of that.
16:52:39FromDiscord<++x;> lqdev maybe you should stop using IRC clients as a whole. But the point is hexchat is bad.
16:52:52FromGitter<alehander42> but whats the difference? that `=default` would be able to take args?
16:53:10lqdev@++x; yeah, and have 10 seconds of lag before my message is delivered to other people. no thanks
16:54:08clyybberalehander42: No, it would just be the default value of the object
16:54:16clyybberof the type
16:54:48clyybberIt's the same as default(T)
16:54:51clyybberIdeally
16:55:23stefantalpalaruHexChat is great, after figuring out how to set up ZNC on a VPS (hint: the HexChat password field needs to be "username/network:password").
16:56:07FromDiscord<++x;> Iqdev hexchat has a buffer overflow bug that interacts remotely to a permanent address that existed in hexchat code, they probably patched it but you would be able to remotely cause someone hexchat to leak data
16:56:11FromDiscord<++x;> Bad bad
16:56:58FromDiscord<++x;> I suggest you use a different IRC client though
16:57:12lqdevany client you can recommend?
16:57:34lqdevjust saying that CLI is not my thing.
16:57:46lqdevin terms of communication, at least.
16:58:06FromDiscord<Chiqqum_Ngbata> irssi
16:58:20lqdev> just saying that CLI is not my thing.
16:59:16FromDiscord<++x;> I see. Fortunately i hate IRC clients. irssi and hexchat were the only ones i used in the past but not anymore.
16:59:41FromDiscord<++x;> IRC clients are always "so secure" and blah blah. They like to deceive you typical devs
17:00:09clyybberhuh?
17:00:15clyybberIRC is not "secure"
17:00:18clyybberits plaintext
17:00:30clyybberAlso weechat is great
17:00:33FromDiscord<++x;> I was being sarcastic obviously
17:00:45FromDiscord<++x;> And also weechat isn't so great either apparently
17:00:51clyybberI think it is
17:01:04clyybberwdyt isnt great about it?
17:01:08blackbeard420i <3 weechat. and its codebase is nice to work with
17:01:09lqdevidc about security that much, really. it's very unlikely that someone will try to steal a Linux user's info anyways
17:01:16lqdevthe biggest target is windows.
17:01:29lqdevfor obvious reasons.
17:01:34FromDiscord<++x;> I found a vulnerability on weechat too that regarded data leakage as well. But in their case it had to do with server connections
17:01:45FromDiscord<++x;> I could show you though
17:01:54clyybbershow me
17:02:29lqdevI don't care if it can leak data, I care about what data it can leac.
17:02:33lqdevs/leac/leak/
17:02:40FromDiscord<++x;> I'm going to setup an IRC server and i want you to try connecting to it from weechat
17:02:54clyybberOk
17:03:24lqdevdon't panic just because a piece of software is insecure. use common sense and you'll be fine.
17:04:19stefantalpalaruhttps://old.reddit.com/r/pcgaming/comments/95r6oa/you_should_know_discord_is_spyware_and_logs_and/
17:04:29stefantalpalaruhttps://old.reddit.com/r/discordapp/comments/d4nmy5/my_discord_data_of_over_2_years_my_telemetry/
17:04:36lqdevoh, and also this โ†‘
17:06:14stefantalpalaruIRC is the future ;-) https://ircv3.net/
17:07:36*Trustable joined #nim
17:09:51*floppydh quit (Quit: WeeChat 2.6)
17:11:55lqdevshashlick: oh shit, nimterop is so fast now
17:12:04lqdevwhat did you do
17:13:23lqdevcompared to what it was before, performance is better, but still not as good as pure Nim
17:14:04clyybberlqdev: You mean at ct right?
17:14:13clyybberOr does nimterop have rt impact?
17:14:29FromDiscord<mratsim> It might be just Nim. I've noticed that my Arraymancer test suite compiles 2x to 5x faster depending on the test module
17:14:51*rokups quit (Quit: Connection closed for inactivity)
17:20:43*nsf quit (Quit: WeeChat 2.6)
17:23:08lqdevclyybber: yeah, compile time
17:23:15lqdevis slow when parsing large headers
17:24:13*theelous3_ joined #nim
17:26:38clyybberah
17:34:08FromDiscord<++x;>
17:34:08FromDiscord<++x;> https://cdn.discordapp.com/attachments/371759389889003532/638430309087707137/Capture_2019-10-28-12-33-48.png
17:35:56shashlicktwo parts to nimterop - a compile time portion which runs in the VM and toast binary which gets called by compile time portion
17:36:16shashlickthe latter is what i improved a bit
17:37:01shashlick@lqdev - nothing is like pure nim, too many steps
17:37:17shashlickright now, slowest step in toast is getting gcc output over pipe
17:37:36Zevvhow so?
17:39:13shashlickjust from basic profiling, that's where most time is spent
17:39:27shashlick@lqdev - didn't you want the miniaudio wrapper?
17:45:57*Asbrn[m] joined #nim
17:46:55lqdevshashlick: I don't need it anymore
17:56:08rayman22201@Zevv you around for a bit?
17:57:38Zevva bit, sup?
17:57:48Zevvracing again, are we?
17:58:49rayman22201vroom vroom
17:58:53ZevvIOSelector_unregister_fix?
17:59:15rayman22201no, VirtualAsyncEvents2
17:59:30rayman22201I'm in a meeting, but I should be finished soon. I would like to get your opinion on it
17:59:47rayman22201not the meeting, the race condition lol
18:01:18rayman22201Take a look at the following test: https://github.com/rayman22201/Nim/blob/VirtualAsyncEvents2/tests/threads/testAsyncThreadCoordination.nim
18:01:31rayman22201and the Virtual Async Even Equivalent: https://github.com/rayman22201/Nim/blob/VirtualAsyncEvents2/tests/threads/testVirtualAsyncThreadCoordination.nim
18:02:43ZevvError: unhandled exception: VirtualAsyncEvent is not registered with a dispatcher.
18:02:45Zevvthat one?
18:03:28rayman22201yup
18:03:35rayman22201AsyncEvent does not have this problem
18:04:11Zevvwell, just use asyncevent then!
18:04:16rayman22201lol
18:04:29ZevvI'll take a peek - no promises because I've hade Quite A Day Already
18:05:01rayman22201No worries. I appreciate what ever you can give.
18:09:21Zevvthese traces are intimidating
18:09:42*neceve quit (Read error: Connection reset by peer)
18:12:29rayman22201This is what I think is happening https://www.irccloud.com/pastebin/yg9171Kl/
18:13:20*nif quit (Quit: ...)
18:13:30*nif_ joined #nim
18:13:37rayman22201but The same exact thing causes no problems for regular Async Event?
18:15:21ZevvI'm totally lost for now
18:15:27Zevvgive me some time
18:15:35ZevvI forgot all of this it seems
18:15:36rayman22201๐Ÿ‘
18:18:05rayman22201interesting note: regular Async Event does not error, **but**, the order can get messed up. So I think there is some kernel locking / magic going on...
18:18:50Zevvbut I'm not running with threads on
18:19:23rayman22201oh yeah. of course. it will always fail without threads on.
18:19:37rayman22201it's in the "thread" folder of the test suite for a reason :-P
18:19:48Zevvyeah :)
18:20:00Zevvobservation: it consistently fails at iteration 7 or 32
18:20:11rayman22201for me it's iteration 2 or 44
18:20:18Zevvgreat stuff
18:20:21rayman22201it depends on your machine lol
18:24:35rayman22201more elaborate error trace: https://www.irccloud.com/pastebin/7lEAWyKG/
18:25:30Zevvyeah I'm that far as well
18:25:35Zevvthe "why" eludes me sill tho
18:26:03rayman22201And this is where I feel the need to dig into the weeds of epoll and selectEvent.
18:26:36rayman22201It seems like trigger does not unregister the event from epoll?
18:31:46Zevvsorry dude my brain is porridge
18:33:10rayman22201lol. no worries. get some rest
18:33:17Zevvas I already complained to disruptek this afternoon: running java apps in android which is virualized in a LXC container, in which we stubbed the h264 video decoder and the OpenGL implementation, which' outputs are sent to an embedded box where the generated streams are remoted. An every single day *something* is not working, and I just sit and stare at my screen for ten minutes, then I have a coffe and
18:33:23Zevvsilently cry for another 10
18:33:35Zevvthat kind of sums it up :)
18:33:47ZevvIt does look pretty cool on my CV though
18:37:27rayman22201http://giphygifs.s3.amazonaws.com/media/mYqaRkXyoGbcY/giphy.gif
18:37:34rayman22201Rube Goldberg would be proud :-P
18:37:46ZevvOoooh I will share that straight away
18:42:24rayman22201:-P
18:44:20*nsf joined #nim
18:45:17*oculux quit (Ping timeout: 240 seconds)
18:45:52*oculux joined #nim
18:53:15*clyybber quit (Quit: WeeChat 2.6)
18:55:05FromGitter<dawkot> What does it mean if `getValue` from `db_postgres` works as intended, but outputs "row number 0 is out of range 0..-1" to terminal even in release mode (there are is no exception raised)
18:56:30Araqdb_postgres doesn't produce output
18:57:33FromGitter<dawkot> Well, the output is definitely caused by this proc
18:57:53FromGitter<dawkot> I can tell by commenting/uncommenting
18:58:19Araqwell it can raise an exception
18:58:29Araqcausing this output in your exception handler
18:58:38*lqdev quit (Remote host closed the connection)
19:06:21FromGitter<dawkot> this code alone (compiled in release mode): โŽ โŽ ```code paste, see link``` โŽ โŽ gives this output: ... [https://gitter.im/nim-lang/Nim?at=5db73c2de886fb5aa210a661]
19:06:54FromGitter<dawkot> the value doesn't exist, so this should be an exception
19:06:56FromGitter<dawkot> but isn't
19:08:47FromGitter<dawkot> Maybe there is logging left in the C code?
19:08:55Araqmy db_postgres.nim neither has 'echo' nor 'write' inside so it's hard to see how it can produce output
19:11:59FromGitter<dawkot> Oh, look 5
19:12:02FromGitter<dawkot> whoops
19:12:09FromGitter<dawkot> https://gist.github.com/optik-aper/58c132a82e8be575d4bda318fcdf1032
19:12:31FromGitter<dawkot> this is not me btw
19:15:39FromGitter<dawkot> > The above error happens if a program calls PQgetvalue(), PQgetlength(), โŽ > or PQgetisnull() with a row number of -1 and if there were no rows โŽ > in the result.
19:15:41FromGitter<dawkot> https://www.postgresql.org/message-id/014c01c57be2$60b97780$3202a8c0@pi
19:15:52*theelous3 joined #nim
19:18:44Araqso ... not our bug?
19:29:35FromGitter<dawkot> It would probably be a good idea to silence the output and throw an exception instead anyway
19:29:48*thomasross is now known as Guest32215
19:29:49*thomasross_ joined #nim
19:29:53*Guest32215 quit (Killed (cherryh.freenode.net (Nickname regained by services)))
19:29:53*thomasross_ is now known as thomasross
19:30:57*theelous3 quit (Ping timeout: 240 seconds)
19:33:01*sagax joined #nim
19:43:29*filcuc quit (Ping timeout: 264 seconds)
19:54:37*lqdev joined #nim
19:58:44disrupteki don't suppose there's any way to seed the genSym rng?
20:01:05*nsf quit (Quit: WeeChat 2.6)
20:05:35*Vladar quit (Quit: Leaving)
20:20:57*GordonBGood joined #nim
20:22:31GordonBGoodAraq: working on the projects you have given me and after our discussion here, have a couple of questions that I can't get out of me mind...
20:22:56GordonBGoodquestion one is related to me "unification" using --gc:hooks idea
20:24:05GordonBGoodOf course --gc: hooks can't currently support our current GC's such as our default one, but could it by using the discussed =trace hooks
20:24:41GordonBGoodIt would seem that the rest of the API required for GC;'d doesn't need to be so performant?
20:25:54Araqbut why waste time and effort on the old GCs, they served us for Nim version 1, it's time to move on
20:27:04Araqthe test matrix is already large enough, c++ vs c codegen, different cpu archs, different operating systems, nlvm trying to keep up
20:28:16GordonBGoodOh, you know I'm not really a proponent of the "old" GC's, just I'm trying to make the transition to "destructors" smoother once seqsv2 is the default
20:29:43GordonBGoodWhich I hope can be sooner rather than later, and would seem to be possible almost immediately one we release seqsv2
20:30:04GordonBGoodAs far as I can tell, the API for seq's and string's wouldn't change
20:30:55Araqlet's release seqsv2 then
20:31:32ZevvWhat could " vmgen.nim(354, 20) `false` leaking temporary 10 slotTempInt [AssertionError]
20:31:35Zevvmean ?
20:31:43ZevvI have funnynesses
20:31:51AraqZevv: it's a new assertion check
20:32:04GordonBGoodI'm thinking that the current GC's are going to be used for quite some time as "araqsgc" isn't ready and our work on the RC/destructor based stuff is still in flux
20:32:42ZevvAraq: and what did I do to hit that?
20:32:50GordonBGoodYes, I'm reprioritizing seq2v2 to higher than the other investigations
20:34:02Araqyou compiled Nim in debug mode, Zevv ?
20:34:21ZevvI did now
20:34:26AraqGordonBGood: yeah, but that doesn't need API changes
20:35:07disruptekdouble the seqs sounds good to me.
20:35:30GordonBGoodAraq: so working on seq2v2 brings up my second question/concern regarding not-breaking on in not-compiling but in not doing what it used to...
20:36:03GordonBGoodI see your latest PR on `shallow` now making it noop just like `shallowCopy`...
20:36:50GordonBGoodHowever, that will make anyone that depended on the ability to get a shallow copy think we made breaking changes...
20:37:38GordonBGoodThat isn't much different than if we changed to "refference instead of value" behavior and did shallow copies instead of deep ones, just the other way?
20:38:10GordonBGoodI mean if we did shallow copies by default on the last...
20:39:01GordonBGoodnewbies coming to Nim from other languages would like prefer shallow copy by default as that would be generally what they are used to
20:39:17GordonBGood^ would likely prefer...
20:40:05GordonBGoodIt is the libraries written by the people here than might hate shallow copy by default if their libraries depend on deep copy by default
20:40:59Araqlisten to me
20:41:10GordonBGoodYes, listening, that's why I'm here...
20:41:40Araq1. I don't agree that "shallow copy" is what "most" programmers want, it's hard to reason about.
20:42:17Araq2. the new model fundamentally doesn't support it as there is no tracing to prevent premature frees.
20:43:16Araqvar a = b # shallow copy of b?
20:43:20Araq=destroy(a)
20:43:30Araq=destroy(b) # humm
20:44:27Araqthere is a reason why C++ uses copies, shallow'ness requires RC or GC
20:44:42*narimiran quit (Ping timeout: 246 seconds)
20:44:56GordonBGoodI may was well intersperse my comments while waiting...
20:45:10Araqit would also be inconsistent with all the other types (ints, floats, tuples of ints and floats...) which do a proper copy
20:46:20GordonBGoodI don't know what most programmers expect. My other favorite languages all have tracing GC, so have reference arrays, and I had to remember seqs/strings were different
20:46:43*clyybber joined #nim
20:46:48Araqbut they are not, arrays also are copied
20:47:32*nif_ quit (Quit: ...)
20:47:41*nif joined #nim
20:48:58GordonBGoodBut for point one, I can live with it either way and I suppose newbies from tracing GC languages just have to learn not to expect let a: seq[int] = b to be a new copy when b is used later so it can't be moved
20:49:39*GordonBGood quit (Remote host closed the connection)
20:51:18*GordonBGood joined #nim
20:53:23Araqas I said, even if I agreed with you and stuff should be shallow copied around, the model doesn't allow it unless we add refcounts to strings and seqs and then it's still not a copyMem
20:53:35Araqbut it needs to incref the counts and stuff
20:53:46yumaikasRika: The quoting issues should be fixed
20:53:50GordonBGoodBut your point 2 kills it - "shallow'ness requires RC or GC"
20:54:46FromGitter<alehander42> hehe i am vesela
20:54:48GordonBGoodSwift can shallow copy because of "automatic RC", which we don't know what we might end up with yet
20:55:52*tyler569 quit (Ping timeout: 264 seconds)
20:56:06GordonBGoodrust can shallow copy because of the controlled "ownership"? Which then switches to RC when multiple owners are required
20:56:27yumaikasWell, you have to switch it to RC on your own
20:56:33yumaikasIIRC
20:56:55Araqrust doesn't shallow copy anything, it moves stuff around and when it can't it asks you to write '.clone()'
20:57:16GordonBGoodyamaikas: yes, you get to choose just RC or atomic RC depending whether you need to own across different threads or not
20:57:50GordonBGoodAraq: you are right, of course, it is just doing moves
20:58:09GordonBGoodWhich our new model also uses
20:58:54GordonBGoodAraq: OK, so deep copy by default it is then
20:58:58clyybberCan I give my opinion: I like that seqs and strings are copied and moved where possible
20:59:43clyybberOr is the discussion deep vs shallow copy (and not by ref vs by value)?
21:01:21GordonBGoodclyybber: I think we're past the deep vs. shallow, it needs to be deep by default; do you have ideas on by ref vs by val?
21:02:58*tyler569 joined #nim
21:03:31clyybberby val of course. Under the hood we can move (by ref) if possible
21:03:39GordonBGoodAnd asking our world at large, will the new seqsv2 (and strings) no longer having a built-in shallow/shallowCopy with these there (so old code will compile) but just noop'ing into a deep copy on assignment be a problem for current libraries?
21:04:24clyybberGordonBGood: Then if someone really wants to have byref seqs he can just do `ref seq`
21:04:32clyybberor `ref string`
21:05:08GordonBGoodclyybber: so you like the way we currently do it, then; I'm fine with that, and yes, once we do deep copy by default it doesn't really matter much
21:05:13rayman22201By Val is always easier to reason about. I 100% agree with clyybber
21:06:04GordonBGoodOkay, that's easy for me as it needs less things to think about, too
21:06:50clyybbercool :)
21:07:06clyybberGordonBGood: What are you working on?
21:07:28GordonBGoodSo rayman22201 and clyybber and anyone else that cares to chip in, does having `shallow` that no longer does anything and `shallowCopy` that actually does a deep copy affect any of you?
21:08:20GordonBGoodclyybber, Araq has kindly given me two projects as my first here:
21:09:22GordonBGood1. working through a new destructor based seqsv2 that has been extracted from --gc:destructors and is (must) be used with newruntime, which is this part of the discussion
21:09:30AraqGordonBGood: I know it affects my code and Status's code but we can adapt
21:09:47Araqdon't worry about shallow
21:10:13rayman22201Definitely should have some guided depreciation path if possible
21:10:15GordonBGood2. Investigating new ways of implementing some hybrid of RC to the newruntime
21:10:41FromDiscord<++x;>
21:10:41FromDiscord<++x;> https://cdn.discordapp.com/attachments/371759389889003532/638484806212124673/Screenshot_20191028-160017.png
21:11:19ZevvCan anyone verify for me what this does on devel?
21:11:21Zevvhttp://ix.io/205C
21:12:07clyybberGordonBGood: Whats wrong with the current seqsv2 that are used rn with --newruntime?
21:13:40GordonBGoodclyybber: There's nothing wrong with it and that's the one that I'm adapting; what's wrong is that when the switch is turned on with current GC's, it doesn't compile because they have been hardcoded to expect the old seqs
21:14:18GordonBGoodAraq would like to make it the default for all scenarios
21:14:50clyybberAh
21:14:55clyybbercool
21:15:05GordonBGoodWhich is why it can now be enabled with its own compiler switch
21:15:36GordonBGoodExcept that doesn't work with other GC's until I'm finished in a day or two
21:17:23*sentreen joined #nim
21:17:37GordonBGoodAnd when it becomes default and enabled without any switch, any of the libraries that use shallow and expect shallow copies to work will either need to change your libraries or we will have to provide a compiler switch to provide legacy seq's (which we don't llike/hate)
21:18:44yumaikasWhat's wrong with legacy seq's?
21:19:05*sentreen_ quit (Ping timeout: 276 seconds)
21:20:40clyybberGordonBGood: Ah, just kill shallow
21:22:00GordonBGoodyumaikas: https://irclogs.nim-lang.org/28-10-2019.html#07:38:17
21:23:50*Trustable quit (Remote host closed the connection)
21:24:04GordonBGoodAraq: what clyybber says has some merit: we are providing code in `shallow` and `shallowCopy` that doesn't do what it says in the docs; might it be better if these just didn't exist with seqsv2 so code wouldn't compile when seqv2 is turned on?
21:25:20GordonBGoodcode that used these would then provide their own emulation if they wanted to go that route?
21:25:39clyybberGordonBGood: Oh I meant, just fake it till we make it
21:25:47clyybberwhere make it is remove it
21:25:59clyybberand fake it is do a deepcopy
21:26:42GordonBGoodclyybber: faking it is what we do; but it might cause some weird bugs in libraries that expect shallow copy?
21:27:44clyybberMaybe print a warning
21:27:58clyybberBut other than that, don't worry :)
21:28:22GordonBGoodAnd if authors haven't visited their library recently, might cause some grief, where as not compiling because shallow and shallowCopy aren't defined would be pretty obvious where work has to be dane
21:29:26GordonBGoodYes, compiler warning would work, plus updated documentation saying it is depreciated and not really working for new seqs
21:29:55GordonBGoodOkay, you are the guys with libraries to support not me (as yet anyway)
21:30:08GordonBGoodNo worries
21:30:35clyybberbrb
21:30:38*clyybber quit (Quit: WeeChat 2.6)
21:31:41Araqmy own code relies on 'cast[pointer]' on seqs working
21:31:59Araqand with the new seqs it takes 2 words, not one
21:32:36Araqdoesn't matter, I can change it
21:32:59FromDiscord<Urothis> is there any way to get more log data out of this?
21:32:59FromDiscord<Urothis>
21:32:59FromDiscord<Urothis> ```nim
21:32:59FromDiscord<Urothis> try:
21:32:59FromDiscord<Urothis> display("Creating", "package file at " & file)
21:32:59FromDiscord<Urothis> createDir(dir)
21:33:00FromDiscord<Urothis> writeFile(file, genPackageText(opts))
21:33:01FromDiscord<Urothis> success("created package file")
21:33:03FromDiscord<Urothis> except:
21:33:05FromDiscord<Urothis> fatal("Could not create package file at " & file)```
21:33:21dom96Urothis: please use a pastebin/gist next time
21:33:34dom96Our IRC bridge spams the channel :/
21:34:04FromDiscord<Urothis> apologies about that. https://pastebin.com/Y3SY7j4G
21:35:25FromDiscord<Urothis> https://github.com/squattingmonk/nasher.nim/blob/master/src/nasher/init.nim#L40
21:35:25FromDiscord<Urothis>
21:35:25FromDiscord<Urothis> tldr, trying to port this tool to docker and running into some issues when it creates a config file.
21:36:10dom96You can include the exception stack trace/message in your `fatal` output I guess
21:36:50*abm quit (Quit: Leaving)
21:37:12*tyler569 quit (Ping timeout: 246 seconds)
21:40:42*kungtotte quit (Ping timeout: 246 seconds)
21:41:14*lqdev quit (Quit: Leaving)
21:42:00yumaikaso/ dom96
21:42:49dom96hey yumaikas :)
21:43:10yumaikasI don't think we've met properly, lol
21:43:27*clyybber joined #nim
21:45:01dom96yumaikas, have we met improperly? :) I don't recall this nickname
21:45:36yumaikasNot to my knowledge. I've been doing a lot of work with Jester in my spare time, so I've seen your nick all over the place.
21:46:02dom96Ahh. Awesome. Hope you're enjoying using Jester.
21:46:23yumaikasSo far, so good. I plan on trying to attack getting it better docs over time
21:46:54yumaikas(Since I'm coming in new, and can see some of the gaps in what's documented more easily)
21:47:59dom96Nice, that would be really helpful. I consider the docs almost non-existent tbh
21:48:13*yumaikas has had to dig in source a fair bit
21:48:15GordonBGoodAraq: that was to me about the seqs pointers
21:48:44dom96What Jester really needs is a promotional website with some nice docs alongside it
21:48:44GordonBGoodDo you refer to the "reserved" field?
21:48:47yumaikasdom96: Wrote about some of the things I've found so far, (and well, about Nim in general): https://www.junglecoder.com/blog/nim-early-report
21:49:28yumaikasdom96: I'd be willing to try to build that out some. It'll take a while
21:49:57AraqGordonBGood: no, my point is: even with 'shallow' we will break somebody's code anyway
21:50:34dom96yumaikas, please do. You have my full support
21:50:52GordonBGoodAraq: yes, anyone depending on shallow will be broken
21:51:26GordonBGoodor do you mean shallow breaks code?
21:51:27Araqbut so does anyone depending on 'cast'!
21:52:10yumaikasdom96: You know of anyone else willing to help fill out docs? I am willing to try to stand up a wiki in the next few months, and I know of one person that I could ask to help
21:52:24yumaikasAlso, do you have any preferences on how the site looks, or do you just want one to exist?
21:52:52GordonBGoodYes, although casting into the internals of a library structure should be recognized by most as an (extremely) unsafe thing to do for code robustness
21:53:12dom96yumaikas, something like this would cool: https://rocket.rs/
21:54:48GordonBGoodAraq: anyway, hopefully and library authors whose code is broken by the new non-functioning shallow will put up with in in exchange for better seqs/strings
21:54:55FromGitter<Willyboar> rocket website is cool
21:55:14yumaikasdom96: Ok. I'll bear that in mind. Right now, it'd be easiest for me starting from https://feed.junglecoder.com as the layout/theme, but I'll try for something with more icons and a fancier layout, like you pointed out
21:55:19GordonBGoodclyybber seems to think no one will mind too much
21:56:07FromGitter<Willyboar> @dom96 i could try too.
21:56:22FromGitter<Willyboar> if there isn't a problem
21:56:35dom96sure, maybe you two could collaborate? :)
21:56:53dom96or maybe one of you is more interested in the design rather than the docs
21:56:57FromGitter<Willyboar> but i haven't used jester yet
21:56:58yumaikasWillyboar: How much time do you to put into getting a docs/promo website up? For me, it's 5 hours a week max right now.
21:57:12dom96(and vice versa)
21:57:26*yumaikas has put up 3 copies of one website written in Jester so far
21:57:33yumaikasBut it's a small website
21:57:38FromGitter<Willyboar> i am more interested in the design rather the docs
21:57:53GordonBGoodAraq: I am thinking of making the code depend on the first field of seqs to be the int len field rather than faking PGenericSeq
21:57:53*kungtotte joined #nim
21:57:59*jjido joined #nim
21:58:19yumaikasWillyboar: I'm a lot more interested in docs, and how the website is organized and the like.
21:59:06yumaikasWillyboar: Maybe you start on something using htmlgen? I'll get a repo up for the website tonight or tomorrow night.
21:59:22GordonBGoodback in a few hours, need some zz's
21:59:58dom96Sounds like the perfect collaboration :D
22:00:24dom96Willyboar: feel free to make a mockup with just raw html/css/scss/whatever
22:00:36FromGitter<Willyboar> @dom do you have a logo and a color palette you prefer?
22:00:55dom96yumaikas: Ideal docs in my mind would be written in markdown, we can then generated them into a nice page later
22:01:01yumaikas(And in making something that other people can contribute too, probably via Github PRs)
22:01:04yumaikasYeah
22:01:11yumaikasI like markdown as well
22:01:37yumaikasI *might* add a couple of post-processing extensions, if we need them. Not at first, however
22:02:02FromGitter<Willyboar> well i just created a static site gen but i think is not that mature to something like that.
22:02:44*yumaikas wants the promo website to be in Jester... Probably with markdown docs in a github repo
22:03:21yumaikasI'd use a Sqlite database, but that means that the hosting server would have to own auth, and that gets complicated
22:04:12yumaikasThough, a local-runnable editor that allows you to navigate+edit, that would be slick
22:06:00*sealmove joined #nim
22:06:32yumaikas(And I'd rather not host the docs on my server atm)
22:06:50*NimBot joined #nim
22:07:36dom96lol, why would you need Jester for that?
22:07:41dom96The site will be 100% static
22:08:27yumaikassomething something dogfood
22:10:23yumaikasNot trying to make things over-complicated, but it'd be nice to be able to update the docs from my cell phone.
22:32:03*LargeEpsilon joined #nim
22:32:38dom96yumaikas, the nim forum is already a much better dogfooding app ;)
22:33:11*ng0 quit (Quit: Alexa, when is the end of world?)
22:34:29yumaikasI suppose so. Depending on how long it takes to write these docs, I might make something for editing for myself, but I'll just start with a repo that has markdown files for now
22:34:34*clyybber quit (Quit: WeeChat 2.6)
22:35:35yumaikasWillyboar: What is your github profile? Mine is github.com/yumaikas
22:37:05*LargeEpsilon quit (Ping timeout: 276 seconds)
22:37:50disruptekcrazy; that's my github profile, too.
22:49:20*tyler569 joined #nim
22:52:36*vsantana quit (Remote host closed the connection)
22:56:14FromGitter<Willyboar> i agree with @dom96 the site is better to be static.
23:07:06*jjido quit (Quit: My MacBook has gone to sleep. ZZZzzzโ€ฆ)
23:20:16*lritter quit (Ping timeout: 252 seconds)
23:31:38*krux02 quit (Remote host closed the connection)
23:33:29*clyybber joined #nim
23:34:13*solitudesf quit (Ping timeout: 268 seconds)