00:08:03 | * | fallback quit (Quit: IRCNow and Forever!) |
00:13:36 | * | pmp-p quit (Ping timeout: 252 seconds) |
00:14:08 | * | pmp-p joined #nim |
00:34:27 | * | fallback joined #nim |
00:52:55 | * | lucerne9 joined #nim |
00:53:34 | * | lucerne quit (Ping timeout: 252 seconds) |
00:53:34 | * | lucerne9 is now known as lucerne |
01:01:55 | FromDiscord | <albassort> leo what do u do when u feel too sick to code and cant focus |
01:02:16 | FromDiscord | <leorize> don't code? |
01:02:24 | FromDiscord | <leorize> have fun by working out other people problems instead |
01:09:45 | FromDiscord | <albassort> hmm |
01:09:56 | FromDiscord | <albassort> but people's problems here are often lame |
01:10:09 | FromDiscord | <albassort> all the cool problems are like complex and too hared to fit into a discord messaage |
01:10:28 | FromDiscord | <albassort> (edit) "hared" => "hard " |
01:30:47 | FromDiscord | <mr_rowboto> In reply to @albassort "leo what do u": If you feel that you still want but just can’t, I’ve been there. |
01:32:48 | FromDiscord | <mr_rowboto> You're not getting distracted because there is external stimuli, you're getting distracted bc brain is tired... and you still want to code bc you are also obsessed.↵↵Except you have ADHD, then you're getting distracted always anyways, and the only solution is to literally chop off all distractions, meticulously, turn on notis, throw away cellphone, use a single screen, tidy room, have nothing on top of table. |
01:32:59 | FromDiscord | <mr_rowboto> (edit) "You're not getting distracted because there is external stimuli, you're getting distracted bc brain is tired... and you still want to code bc you are also obsessed.↵↵Except ... you" added "if" |
01:33:09 | FromDiscord | <mr_rowboto> (edit) "on" => "off" |
01:34:05 | FromDiscord | <mr_rowboto> If you're ok good with the attention thing and can function normally... but just can't code, this will sound stupid, but do something else:↵take a walk, talk to a friend, take a bath. |
01:34:19 | FromDiscord | <mr_rowboto> Let brain rest. |
01:35:16 | FromDiscord | <mr_rowboto> (edit) removed "ok" | "thing" => "disorder thing," |
01:38:08 | FromDiscord | <albassort> idk about the adh |
01:38:09 | FromDiscord | <albassort> (edit) "adh" => "adhd" |
01:38:27 | FromDiscord | <albassort> i feel like a lazy bum if i don't get work done. like I might as well just not exist if im not being productive |
01:39:01 | FromDiscord | <albassort> i could have adhd who knows but its likely some kind of attention thing + my GAD chronic anxiety |
02:19:26 | * | skippy8 joined #nim |
02:21:04 | * | rockcavera quit (Remote host closed the connection) |
04:01:09 | FromDiscord | <albassort> should i use epoll |
04:01:16 | FromDiscord | <albassort> to monitor sockets? |
04:01:42 | FromDiscord | <albassort> so i have a bunch of sockets, currently in an array, poll them every 5ms and do recvLine |
04:01:57 | FromDiscord | <albassort> what if i use epoll, add them to the epoll list, then go through the epollarray |
04:06:10 | FromDiscord | <albassort> sent a code paste, see https://play.nim-lang.org/#pasty=ykeVkKNR |
04:24:31 | FromDiscord | <Elegantbeef> `std/selectors` is undocumented but does exist |
04:37:20 | * | adigitoleo quit (Server closed connection) |
04:37:29 | * | adigitoleo joined #nim |
04:55:16 | FromDiscord | <albassort> In reply to @Elegantbeef "`std/selectors` is undocumented but": well i've done epoll integration now |
04:55:20 | FromDiscord | <albassort> and i dont know how a selector is |
04:56:05 | FromDiscord | <albassort> im uneducateed+old c code stuff is cool+selectors is undocumented+l+ratio |
05:03:27 | FromDiscord | <Elegantbeef> It's just a wrapper over `select` on unix↵(@albassort) |
05:04:08 | FromDiscord | <Elegantbeef> What you can do is select on the sockets then you receive when they have data |
05:04:30 | FromDiscord | <Elegantbeef> Well it uses epoll/kqueue/poll 😄 |
05:05:28 | FromDiscord | <Elegantbeef> https://github.com/beef331/potato/blob/master/src/potato.nim#L209-L235 for a small use case of a selector |
05:05:59 | FromDiscord | <Elegantbeef> Open a socket, add the fd to the selector for when it's ready to `Read` then In my read loop I just act on each select event |
06:29:24 | * | Ekho quit (Server closed connection) |
06:33:15 | * | Ekho joined #nim |
06:37:19 | Amun-Ra | select even works on windows, not on all types tho |
07:47:36 | FromDiscord | <albassort> ``i have never once developed something and expected it to work on windows |
07:48:07 | FromDiscord | <albassort> except for when that was my job |
08:41:32 | Amun-Ra | same tbh |
10:38:26 | FromDiscord | <albassort> i love channels |
10:38:29 | FromDiscord | <albassort> they get so cursed |
10:38:37 | FromDiscord | <albassort> but they're pretty fast, safe, and powerful |
12:12:53 | * | xet7 joined #nim |
13:20:12 | FromDiscord | <blashyrk> sent a code paste, see https://play.nim-lang.org/#pasty=DkAKsKEp |
13:28:54 | FromDiscord | <Robyn [She/Her]> Nim doesn't have a borrow checker↵(@blashyrk) |
13:29:13 | FromDiscord | <blashyrk> > Error: cannot borrow inverseTransform; what it borrows from is potentially mutated↵Sure sounds like borrow checking to me 😄 |
13:29:57 | FromDiscord | <Robyn [She/Her]> afaik it's not really a borrow checker, it doesn't do anything as in-depth as Rust does, at least |
13:36:43 | FromDiscord | <Laylie> can you share the type and proc definitions so we can reproduce this |
13:37:59 | FromDiscord | <spotlightkid> How can I check at run-time whether a non-constant int can be converted into a value of enum `Foo`?↵AI says to check the `Foo.low .. Foo.high` range (for non-sparse enums). Or is there a better/more concise way? |
13:55:04 | FromDiscord | <Laylie> sent a code paste, see https://play.nim-lang.org/#pasty=VgOirteo |
14:04:58 | FromDiscord | <spotlightkid> TIL `HoleyEnum` exists 😉 |
14:18:38 | FromDiscord | <heysokam> Not to be confused with `HolyEnum` |
14:35:04 | * | przmk quit (Ping timeout: 272 seconds) |
14:43:32 | * | przmk joined #nim |
14:52:44 | FromDiscord | <_._winter.> In reply to @heysokam "Not to be confused": what does it mean for an enum to be holy |
14:53:52 | FromDiscord | <flyx> compiles to HolyC↵(@_._winter.) |
14:54:12 | FromDiscord | <_._winter.> the only perfect language |
15:11:05 | FromDiscord | <spotlightkid> You mean the Holy See?↵Where the program is always right, regardless what the users wants. |
15:35:43 | FromDiscord | <mr_rowboto> In reply to @spotlightkid "You mean the Holy": That's "The !C Programming Language" |
15:36:04 | FromDiscord | <mr_rowboto> stylized as `Cn't` |
15:39:06 | FromDiscord | <Robyn [She/Her]> it has been blessed by the current pope, smh↵(@_._winter.) |
16:28:21 | FromDiscord | <flyx> in case you haven’t heard of it, HolyC is an actual programming language, used in TempleOS. the pun is still intended. |
16:37:22 | * | beholders_eye quit (Ping timeout: 252 seconds) |
16:39:25 | * | beholders_eye joined #nim |
17:02:29 | * | beholders_eye quit (Ping timeout: 240 seconds) |
17:10:28 | FromDiscord | <mr_rowboto> In reply to @flyx "in case you haven’t": Of course I've heard of it. Who hasn't heard of Terry,↵`The Best Programmer That Has Ever Lived`↵Rest In Peace, sweet king, fly where glowies can't get you. |
17:10:36 | FromDiscord | <mr_rowboto> (edit) "In reply to @flyx "in case you haven’t": Of course I've heard of it. Who hasn't heard of Terry,↵`The Best Programmer That Has Ever Lived`↵Rest In Peace, sweet king, fly ... where" added "to" |
17:51:08 | FromDiscord | <ollicron_53732> https://tenor.com/view/conspiracy-theory-explaining-gif-15961634830032552817 |
17:51:52 | FromDiscord | <ollicron_53732> how I feel trying to understand ASTs right now https://media.discordapp.net/attachments/371759389889003532/1404522723618717757/giphy.png?ex=689b7f38&is=689a2db8&hm=0399eafa7f8fac106047655ce4529094ecf879573c0f15c6797353c17113537b& |
17:53:03 | FromDiscord | <ollicron_53732> https://media.discordapp.net/attachments/371759389889003532/1404523017446490163/giphy.png?ex=689b7f7e&is=689a2dfe&hm=c4cc19ae146ff7f42d9fc10da7c34d6ad8e92bf003616a67a45ccd13df67e2f7& |
17:53:33 | FromDiscord | <Elegantbeef> AST isn't that bad it's a tree of the language |
17:53:43 | FromDiscord | <Elegantbeef> `import std/macros ` and use `dumptree` |
17:56:05 | FromDiscord | <ollicron_53732> In reply to @Elegantbeef "`import std/macros ` and": the holy `dumptree` function I am learning! |
17:56:12 | FromDiscord | <Robyn [She/Her]> ye, just data |
17:59:09 | FromDiscord | <mr_rowboto> tbh I'd feel more comfortable just writing a big-ass unchecked string and replacing stuff. |
18:00:45 | FromDiscord | <mr_rowboto> the compiler is going to check verify it anyways |
18:00:49 | FromDiscord | <mr_rowboto> (edit) removed "verify" |
18:13:10 | FromDiscord | <leorize> being white space significant, the language is also very hostile to mechanical manipulation of the source code |
18:13:10 | FromDiscord | <leorize> even the official formatter can't output code that compiles |
18:15:07 | FromDiscord | <Elegantbeef> Well that is |
18:15:12 | FromDiscord | <Elegantbeef> to say it can output code that fails to compile |
18:15:22 | FromDiscord | <Elegantbeef> It can also output code that does compile 😄 |
19:12:08 | FromDiscord | <mr_rowboto> we're positive that it can _output code_ |
19:13:43 | FromDiscord | <Elegantbeef> Yes |
19:13:48 | FromDiscord | <Elegantbeef> But not all the code it outputs can compile |
19:37:44 | FromDiscord | <mr_rowboto> sent a code paste, see https://play.nim-lang.org/#pasty=uiRTOQRy |
19:37:56 | FromDiscord | <mr_rowboto> (edit) "https://play.nim-lang.org/#pasty=NYgHiLQj" => "https://play.nim-lang.org/#pasty=CLHbOUWx" |
19:38:43 | FromDiscord | <mr_rowboto> Because it would help a lot to avoid nesting when accessing multiple components from different entities in vecs/yeacs |
20:01:41 | FromDiscord | <Elegantbeef> @mr_rowboto https://github.com/beef331/slicerator/blob/master/src/slicerator.nim#L153 |
20:01:53 | FromDiscord | <Elegantbeef> That's an allocating implementation |
20:02:02 | FromDiscord | <Elegantbeef> https://github.com/beef331/slicerator/blob/master/src/slicerator.nim#L280 non allocating implementation |
20:02:44 | FromDiscord | <Elegantbeef> Though it captures them as closures, you likely do not want that |
20:07:38 | FromDiscord | <mr_rowboto> super nice |
20:07:58 | FromDiscord | <mr_rowboto> that's one huge macro |
20:08:15 | FromDiscord | <Elegantbeef> It's not even that big |
20:08:19 | FromDiscord | <Elegantbeef> Plus it calls `asClosure` which is another macro |
20:08:25 | FromDiscord | <mr_rowboto> hehe |
20:08:32 | FromDiscord | <mr_rowboto> what's the closure for? |
20:09:00 | FromDiscord | <Elegantbeef> I don't recall now 😄 |
20:09:50 | FromDiscord | <Elegantbeef> Think it might've been for ensuring all the iterators were finished |
20:10:00 | FromDiscord | <Elegantbeef> Well were not |
20:10:35 | FromDiscord | <Elegantbeef> Oh no it's cause you need to populate each field and the only way to do with this large iterator is with closures |
20:10:39 | FromDiscord | <Elegantbeef> Since they're continuable |
20:12:41 | FromDiscord | <Elegantbeef> sent a code paste, see https://play.nim-lang.org/#pasty=bbHRikEm |
20:13:42 | FromDiscord | <Elegantbeef> You want to have concurrent iterators and there is no way to provide state to continue from where they left off it's not overly possible to do this anyway else generically |
20:13:50 | FromDiscord | <Elegantbeef> In your case you can probably just turn them into indexers for components |
20:13:57 | FromDiscord | <mr_rowboto> makes sense |
20:14:11 | FromDiscord | <mr_rowboto> I'll probably want the closures |
20:14:21 | FromDiscord | <mr_rowboto> since sooner or later I will want to run stuff on threads |
20:15:01 | FromDiscord | <Elegantbeef> Well they're allocatey and do not ensure that the tree is isolated |
20:15:08 | FromDiscord | <Elegantbeef> So moving them across threads may end badly |
20:15:26 | FromDiscord | <Elegantbeef> Anything automatically managed by Nim being moved to threads is a sad state |
20:15:38 | FromDiscord | <Elegantbeef> With the exception of sinkable types |
20:16:04 | FromDiscord | <mr_rowboto> sent a code paste, see https://play.nim-lang.org/#pasty=wWwEgDgZ |
20:16:53 | FromDiscord | <Elegantbeef> Ah just use an atomic |
20:16:54 | FromDiscord | <Elegantbeef> `std/atomics` are right there or `nim-lang/threading`'s atomics |
20:16:55 | FromDiscord | <mr_rowboto> Thanks again. |
20:17:33 | FromDiscord | <Elegantbeef> No problem, still about sad that yeacs didn't solve your issue, it's a failed ECS! 😄 |
20:27:11 | FromDiscord | <leorize> can't you just use macrocache.CacheCounter to do it all at CT? |
20:28:59 | FromDiscord | <Elegantbeef> You can but I was avoiding macros when I wrote it |
20:29:07 | FromDiscord | <Elegantbeef> Anything with macro in the name |
20:31:16 | FromDiscord | <mr_rowboto> In reply to @Elegantbeef "No problem, still about": It's not a failed ECS at all. It's the ECS that made me learn cool stuff. |
20:31:53 | FromDiscord | <mr_rowboto> IMHO I'd change the pointer stuff because it forces you to deal with move semantics and so on. |
20:32:16 | FromDiscord | <mr_rowboto> but it's just _opinion_. |
20:33:20 | * | beholders_eye joined #nim |
20:33:20 | FromDiscord | <mr_rowboto> incidentally that kind of _dodges_ the nim compiler bug |
20:33:27 | FromDiscord | <Elegantbeef> I want move semantics though |
20:33:28 | FromDiscord | <mr_rowboto> (edit) "incidentally" => "incidentally," |
20:33:36 | FromDiscord | <mr_rowboto> fair enough |
20:34:01 | * | skippy8 quit (Quit: WeeChat 4.6.3) |
20:34:05 | FromDiscord | <mr_rowboto> It's something I have to look closer to. |
20:34:12 | FromDiscord | <mr_rowboto> (edit) "It's something I have to ... look" added "take a closer" | removed "closer" |
20:34:20 | FromDiscord | <mr_rowboto> (edit) "It's something ... I" added "that" |
20:35:17 | FromDiscord | <Elegantbeef> I'll have a gander when you release yours, but yea I don't know there was a reason I did the `seq[byte]` |
21:02:19 | FromDiscord | <mr_rowboto> You have a whole lot of nim code. Can't remember all. |
21:02:24 | FromDiscord | <mr_rowboto> (edit) "all." => "all, it's literally impossible." |
21:17:01 | * | rockcavera joined #nim |
21:30:31 | * | beholders_eye quit (Ping timeout: 255 seconds) |
22:24:23 | * | syl quit (Quit: C-x C-c) |
22:25:04 | * | syl joined #nim |
22:50:04 | * | tiorock joined #nim |
22:50:04 | * | tiorock quit (Changing host) |
22:50:04 | * | tiorock joined #nim |
22:50:04 | * | rockcavera is now known as Guest2207 |
22:50:04 | * | tiorock is now known as rockcavera |
22:52:09 | * | tiorock joined #nim |
22:52:09 | * | rockcavera is now known as Guest9318 |
22:52:09 | * | Guest9318 quit (Killed (copper.libera.chat (Nickname regained by services))) |
22:52:09 | * | tiorock is now known as rockcavera |
22:52:17 | * | zgasma joined #nim |
22:53:46 | * | Guest2207 quit (Ping timeout: 255 seconds) |
23:17:31 | * | xet7 quit (Remote host closed the connection) |