00:00:07 | * | ehmry joined #nim |
00:00:32 | * | lain joined #nim |
00:02:54 | FromDiscord | <hmmm> aaaa why python can have the beautiful a[1:] and we need to have this monstrosity a[1 .. ^1] |
00:07:39 | FromDiscord | <Elegantbeef> You... do realize you can make your own sugar |
00:07:44 | FromDiscord | <impbox [ftsf]> https://github.com/nim-lang/RFCs/issues/311 |
00:09:19 | FromDiscord | <impbox [ftsf]> sounds like one reason is because nim doesn't have support for postfix operators, only prefix and infix |
00:09:35 | FromDiscord | <impbox [ftsf]> and `1..^1` does the job |
00:11:57 | FromDiscord | <evoalg> I would say that `a[1 .. ^1]` is more readable than `a[1:]` anyway. I used to write perl scripts where I would feel cool using a few symbols to do stuff, but it wasn't readable, so I now like the longer form |
00:14:46 | FromDiscord | <impbox [ftsf]> i wouldn't mind having `a[1..]` or `a[..5]` but easy to manage without, it could also be ambiguous in different contexts. `1..` -> `1..type(1).high` ? `..5` `type(5).low..5` would make sense for ranges, but slicing a string you'd probably want it to have a different meaning |
00:15:45 | FromDiscord | <Elegantbeef> Just make `1.^1` sugar π |
00:17:22 | FromDiscord | <evoalg> `a[1 .. a.high]` may be even more readable, yea |
00:18:02 | FromDiscord | <evoalg> dunno |
00:18:20 | FromDiscord | <Elegantbeef> Ideally you avoid these slice operations though, unless you need a sequence |
00:18:30 | FromDiscord | <Elegantbeef> But that's just me going "Memory usage bad" |
00:19:43 | FromDiscord | <evoalg> so would `for x in a[1 .. ^1]` make a new seq and then loop over it? |
00:19:59 | FromDiscord | <Elegantbeef> Yep |
00:20:22 | FromDiscord | <Elegantbeef> to do the 0cost iteration you'd want `for x in a.toOpenArray(1, a.high)` |
00:20:47 | FromDiscord | <evoalg> ooooo |
00:21:00 | FromDiscord | <evoalg> lemme look up toOpenArray |
00:21:25 | FromDiscord | <impbox [ftsf]> oh, i've not encountered that |
00:21:38 | FromDiscord | <Elegantbeef> Though now we can use `[]` for iterators so we can make 0 cost iterators |
00:23:06 | FromDiscord | <evoalg> I looked up toOpenArray is system ... no explanation or examples ... I'm not able to glean stuff form proc definitions yet π¦ |
00:23:17 | FromDiscord | <Elegantbeef> https://play.nim-lang.org/#ix=3EDN |
00:23:29 | FromDiscord | <Elegantbeef> it just returns an `openArray` which is basically a `pointer, len` |
00:23:45 | FromDiscord | <Elegantbeef> It cannot be stored in a variable, it can only be passed to procedures or used in loops |
00:24:03 | FromDiscord | <evoalg> nice π |
00:24:05 | * | LyndsySimon quit (Ping timeout: 260 seconds) |
00:24:32 | * | robertmeta quit (Ping timeout: 268 seconds) |
00:24:42 | * | euantorano quit (Ping timeout: 260 seconds) |
00:24:42 | FromDiscord | <Elegantbeef> But yea if you care about memory usage/performance `toOpenArray` is the way to iterator over slices |
00:25:51 | FromDiscord | <evoalg> I guess if I'm writing something that will only be use used where they'll be plenty of mem and the seq / array isn't too long then I don't have to worry |
00:27:34 | * | ormiret quit (Read error: Connection reset by peer) |
00:27:34 | * | notchris quit (Write error: Connection reset by peer) |
00:28:27 | * | elph quit (Ping timeout: 250 seconds) |
00:29:33 | FromDiscord | <Elegantbeef> Yep bikeshedding is a hobby π |
00:30:46 | FromDiscord | <Elegantbeef> Eh i see zoom is happy that i passed a flag along π |
00:31:41 | FromDiscord | <evoalg> huh? |
00:31:58 | FromDiscord | <Elegantbeef> They reacted to my `[]` comment, which was fixed by passing a flag along |
00:32:16 | FromDiscord | <Elegantbeef> Matrix/discord reactions arent cross bridge sadly |
00:32:32 | FromDiscord | <Zoom> Yeah, implicit seq creation makes me sad |
00:33:06 | FromDiscord | <Elegantbeef> Yea was the reason i looked into it, smelled like a simple issue that should've been easy to fix |
00:34:09 | FromDiscord | <Elegantbeef> Low hanging fruit is my forte! |
00:34:55 | FromDiscord | <impbox [ftsf]> Well slicing is not really implicit |
00:35:35 | FromDiscord | <Elegantbeef> The copy is implicit there are many usages of `for x in a[b..c]` which shouldnt be copies |
00:35:56 | FromDiscord | <Zoom> But you probably should expect it to return a "view type"β΅(@impbox [ftsf]) |
00:36:04 | FromDiscord | <Elegantbeef> Ideally the `a[b..c]` is only a copy when needs to be |
00:36:39 | FromDiscord | <impbox [ftsf]> `var b = a[1..5]` i wouldn't expect to be a view |
00:37:04 | FromDiscord | <Elegantbeef> In that case it shouldnt be you're right |
00:37:09 | FromDiscord | <Elegantbeef> Luckily we can support both now |
00:37:42 | FromDiscord | <impbox [ftsf]> `for x in a{1..5}:` or something for view perhaps? |
00:37:57 | FromDiscord | <Elegantbeef> It doesnt make sense in this case |
00:37:58 | FromDiscord | <impbox [ftsf]> Not sure if that syntax is already used by sets |
00:38:21 | FromDiscord | <impbox [ftsf]> But if the compiler can do the magic to determine the correct thing by context that's cool |
00:38:23 | FromDiscord | <Elegantbeef> `for x a[1..5]` doesnt need to copy since `x` is immutable |
00:38:31 | FromDiscord | <Elegantbeef> It can |
00:38:33 | FromDiscord | <impbox [ftsf]> Nice |
00:38:51 | FromDiscord | <Zoom> I would. Not in Nim, though \:Dβ΅(@impbox [ftsf]) |
00:41:06 | FromDiscord | <Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=3EDQ |
00:43:17 | FromDiscord | <evoalg> seems like magic to me |
00:44:24 | * | elph joined #nim |
00:44:48 | FromDiscord | <Zoom> `let s = x[0..1] & x[3..4]` it would be nice if it didn't create intermediate seqs and copied directly. |
00:45:35 | FromDiscord | <Elegantbeef> Well with TRM that's actually possible π |
00:46:29 | FromDiscord | <evoalg> TRM? |
00:47:18 | FromDiscord | <Elegantbeef> Term rewriting macros, they allow you to use pattern matching to define what to replace |
00:47:55 | FromDiscord | <Elegantbeef> So for instance you could replace `"Hello" & " " & "World"` with `"Hello world"` |
00:48:09 | FromDiscord | <Elegantbeef> not a overly compelling example of course |
00:48:57 | FromDiscord | <Zoom> If slices were immutable by default it would be unnecessary. |
00:49:02 | FromDiscord | <Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=3EDU |
00:49:17 | FromDiscord | <RattleyCooper> In reply to @evoalg "seems like magic to": Wait until you see a template that uses `{.inject.}` π |
00:49:29 | FromDiscord | <evoalg> lol |
00:49:35 | * | elph quit (Ping timeout: 264 seconds) |
00:49:41 | FromDiscord | <Elegantbeef> Unhygienic templates arent that complicated though |
00:50:14 | FromDiscord | <RattleyCooper> But it def seems like magic to me |
00:50:36 | FromDiscord | <Elegantbeef> I dont recall Zoom do you have a performance focused library for iterators or is that someone else |
00:51:10 | FromDiscord | <Zoom> I got nothing. I just liked zero\_functional |
00:51:13 | FromDiscord | <Elegantbeef> Ah |
00:51:35 | FromDiscord | <Elegantbeef> I recall from the forum you + ZF but didnt remember who was the author |
00:51:42 | FromDiscord | <Zoom> Although it's limited |
00:52:20 | * | elph joined #nim |
00:53:14 | * | LyndsySimon joined #nim |
00:54:20 | * | notchris joined #nim |
01:02:06 | FromDiscord | <evoalg> so it's possible that nim could have done slices as iterators by default, but didn't go down that path when nim was developed? |
01:02:14 | * | robertmeta joined #nim |
01:03:14 | FromDiscord | <RattleyCooper> The great thing about nim is you can usually just make it do the things you want, so even if it's not developed that way you can create the iterators you want/need. |
01:04:01 | FromDiscord | <Elegantbeef> Indeed evoalg, especially if someone fixed the bug when it was introduced π |
01:04:59 | FromDiscord | <Elegantbeef> The issue was that `[]` was accidentally disallowed for iterators until 1.6.0, but there is no reason for the stdlib not to have them, personally i'm somewhat considering making a module for it |
01:06:08 | FromDiscord | <Elegantbeef> It'd never be introduced into `iterators` i assume since it'd be a possible breaking change |
01:08:54 | FromDiscord | <Zoom> It would be nice to be considered for v2 |
01:09:51 | FromDiscord | <Elegantbeef> yep |
01:10:54 | FromDiscord | <Zoom> And to be considered it needs to be suggested.. |
01:11:18 | FromDiscord | <evoalg> I heard a rumor that v2 is 1 year away, and it always will be 1 year away ... am I cynical? |
01:11:36 | * | euantorano joined #nim |
01:11:48 | FromDiscord | <evoalg> it's more that I'm worried this will be the case, as I've seen that sort of thing before |
01:14:11 | FromDiscord | <RattleyCooper> I haven't been around that long but since I started using nim it's gone from 1.4.8 to 1.6. Don't know if that's normal or not for that timeframe though |
01:14:29 | FromDiscord | <impbox [ftsf]> does the number matter to you? |
01:14:51 | FromDiscord | <RattleyCooper> Yeah, so long as progress is made it really shouldn't matter if it's 2.0 or 1.9.99 |
01:15:02 | FromDiscord | <impbox [ftsf]> is there's a specific feature you're waiting on? |
01:15:15 | * | elph quit (Quit: Connection closed for inactivity) |
01:15:44 | FromDiscord | <impbox [ftsf]> since the scope for v2 isn't announced, I understand why you'd care when a version with that number it gets released. |
01:17:19 | FromDiscord | <impbox [ftsf]> i think a roadmap would be great though, hopefully we'll see something like that soon |
01:22:08 | FromDiscord | <evoalg> sent a long message, see http://ix.io/3EDY |
01:22:38 | FromDiscord | <RattleyCooper> Ahhh, that makes a lot of sense |
01:23:04 | FromDiscord | <RattleyCooper> Just a backlog of features |
01:23:54 | FromDiscord | <evoalg> will it be as backwards compatible as 1.6 is to 1.4 sort-of-thing? |
01:23:59 | FromDiscord | <Elegantbeef> v2 allows breaking changes, so it will allow many API changes |
01:24:05 | FromDiscord | <evoalg> ahhh ok |
01:24:27 | FromDiscord | <Elegantbeef> Major changes do not need to be backwards compatible |
01:24:40 | * | ormiret joined #nim |
01:25:50 | FromDiscord | <evoalg> so would it be fair to compare v2 to Python2 -> Python3 ? (as fair as we can be with no roadmaps at this stage) |
01:26:11 | FromDiscord | <Elegantbeef> There is a forum post for what araq wants for 2.0 |
01:26:55 | FromDiscord | <Elegantbeef> https://forum.nim-lang.org/t/7983 |
01:27:25 | FromDiscord | <evoalg> thank you! (and I'll stop asking the tough questions π ) |
01:27:54 | FromDiscord | <Elegantbeef> none of us are core devs so cannot say much of what 2.0 will entail |
01:30:00 | FromDiscord | <evoalg> Makes sense ... and please remember I don't really know what I'm talking about ... thank you all for your thoughts |
01:30:21 | FromDiscord | <RattleyCooper> Neither do I! |
01:30:31 | FromDiscord | <Elegantbeef> Well i never know what i'm talking about, i just take the lack of argument for that i do π |
01:31:53 | FromDiscord | <evoalg> π |
01:34:06 | FromDiscord | <impbox [ftsf]> In reply to @evoalg "so would it be": I would guess not, python 2->3 completely fragmented their ecosystem, i imagine nim would not repeat their mistake |
01:35:01 | FromDiscord | <impbox [ftsf]> nim 0 -> 1 was an easy transition, as have been 1.x -> 1.x+1 |
01:40:39 | FromDiscord | <Elegantbeef> you mean `1.x + 2` π |
01:41:13 | FromDiscord | <impbox [ftsf]> true, 1.x -> 1.x+1 was troublesome =p |
01:41:18 | FromDiscord | <Elegantbeef> `x mod 2 == 0` are stable releases `x mod 2 == 1` are devel branches |
01:52:56 | FromDiscord | <Daniel M. JaΓ©n> The best package for MySQL? |
01:53:17 | FromDiscord | <Daniel M. JaΓ©n> (edit) "The" => "What is the" |
02:38:25 | FromDiscord | <exelotl> In reply to @Daniel M. JaΓ©n "What is the best": sadly I think std/db_mysql is the only real option |
02:40:13 | FromDiscord | <exelotl> ndb would be preferable but it only supports sqlite and postgres :( |
02:40:32 | * | arkurious quit (Quit: Leaving) |
02:40:59 | FromDiscord | <Daniel M. JaΓ©n> In reply to @exelotl "ndb would be preferable": F |
02:41:06 | FromDiscord | <Daniel M. JaΓ©n> In reply to @exelotl "sadly I think std/db_mysql": ok |
02:55:02 | * | neurocyte0132889 quit (Ping timeout: 240 seconds) |
03:30:23 | FromDiscord | <Qixt> what's the most recommended nim gui toolkit |
03:40:32 | FromDiscord | <impbox [ftsf]> if you have the option, postgresql is significantly better than mysql |
03:40:47 | * | rockcavera quit (Remote host closed the connection) |
03:54:17 | FromDiscord | <evoalg> I can do `echo @[1, 2, 3, 4, 5].find(3)` but I can't do the same with "rfind", ie `echo @[1, 2, 3, 4, 5].rfind(3)` ... should I reverse the seq and then use find? |
03:56:48 | FromDiscord | <Rika> Is there an rfind for regular seqs? |
03:56:53 | FromDiscord | <Yardanico> In reply to @Rika "Is there an rfind": no, that's the point |
03:57:00 | FromDiscord | <Yardanico> there's only rfind for strings |
03:57:27 | FromDiscord | <evoalg> ohhhhh ok ... so I should reverse using the algorithm module and then use find? |
03:59:22 | FromDiscord | <evoalg> or I could loop through the seq and keep the last matched index I guess |
04:06:01 | * | supakeen quit (Quit: WeeChat 3.3) |
04:06:32 | * | supakeen joined #nim |
04:17:16 | FromDiscord | <impbox [ftsf]> or add an rfind for seqs |
04:17:23 | FromDiscord | <impbox [ftsf]> sounds like a useful thing to have |
04:17:51 | FromDiscord | <Elegantbeef> Well i guess i'll make that iterator module since i cannot be arsed to try to debug opengl's debug handler causing a segfault |
04:18:09 | FromDiscord | <Elegantbeef> Grabbed an old laptop installed an OS and turns out i'm an idiot that forgot the GPU it had sucks π |
04:21:37 | FromDiscord | <evoalg> I make my own rfind https://play.nim-lang.org/#ix=3EEz ... but I haven't been brave enough to make a iterator for it instead |
04:24:05 | FromDiscord | <evoalg> I'm wanting the rfind for seq's so that I can compare eg user input of a number to if it has been previously entered, and if so when, ie the last time, ie the last index, so hence rfind ... if that makes sense |
04:25:10 | FromDiscord | <Elegantbeef> Why is it named `myrfind` π |
04:25:37 | FromDiscord | <Elegantbeef> try `proc rfind[T](s: seq[T], n: T): int` as the proc definition for infinite reuse π |
04:26:05 | FromDiscord | <evoalg> I wasn't brave and thought it might break something ... it'd be the first time I named something the same as a standard proc ... ok I will do that! π |
04:26:13 | FromDiscord | <evoalg> Thank you! |
04:28:46 | FromDiscord | <impbox [ftsf]> sent a code paste, see https://play.nim-lang.org/#ix=3EEH |
04:28:50 | FromDiscord | <impbox [ftsf]> you can do something like this to make it more generic |
04:29:02 | FromDiscord | <impbox [ftsf]> then it'll work with any type of seq |
04:29:28 | FromDiscord | <Elegantbeef> I didnt even look at the body, use that implicit result if you're going to do that style of coding evoalg |
04:29:30 | FromDiscord | <evoalg> I want it to return on the last match not the first though |
04:29:44 | FromDiscord | <impbox [ftsf]> oh right, in which case ,iterate backwards |
04:29:52 | FromDiscord | <impbox [ftsf]> sorry i didn't realise it wasn't doing that |
04:30:07 | FromDiscord | <evoalg> oh I didn't realize I could iterate backwards! |
04:30:32 | FromDiscord | <Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=3EEI |
04:30:36 | FromDiscord | <Elegantbeef> Is one way of doing it |
04:30:56 | FromDiscord | <Elegantbeef> I dont recall if the stdlib provides a reversed iterator |
04:31:01 | FromDiscord | <impbox [ftsf]> sent a code paste, see https://play.nim-lang.org/#ix=3EEJ |
04:31:10 | FromDiscord | <Elegantbeef> open arrays `s.low` is 0 |
04:31:23 | FromDiscord | <evoalg> much nicer and much more efficient, both of you thank you! |
04:31:39 | FromDiscord | <impbox [ftsf]> openarray means it'll work with both seqs and arrrays |
04:32:10 | FromDiscord | <evoalg> ahhh ok! |
04:33:09 | FromDiscord | <impbox [ftsf]> if you wanted to find all occurrences starting from the back you could do an iterator |
04:33:34 | FromDiscord | <impbox [ftsf]> sent a code paste, see https://play.nim-lang.org/#ix=3EEK |
04:34:29 | FromDiscord | <evoalg> gotcha, thanks! ... Elegantbeef gave me a "find all" iterator going forward, so I've got lots to play with now - thank you both! |
04:34:54 | FromDiscord | <impbox [ftsf]> hurrah! have fun! |
04:53:52 | FromDiscord | <evoalg> for the iterator way, I looped over it and it works great. If I wanted to use the iterator only to grab the first match, how do I do that? ... as I can't do `v = myseq.rfind(4)` if it's an iterator |
04:54:26 | FromDiscord | <Elegantbeef> You'd need a proc for that syntax |
04:56:18 | FromDiscord | <evoalg> ok thank you ... gosh I was thinking of using the iterator and then using a for loop and breaking on the first iteration ... that's not particularly good programming practice right? |
04:56:39 | FromDiscord | <Elegantbeef> Not when it can be avoided, you can always make a proc to do that though |
04:56:59 | FromDiscord | <Elegantbeef> https://github.com/beef331/slicerator/blob/master/src/slicterator.nim here's a bunch of inspiration π |
04:57:21 | FromDiscord | <Elegantbeef> Even got tests https://github.com/beef331/slicerator/blob/master/tests/test1.nim |
04:58:05 | FromDiscord | <Rika> When the fuck did you become treeform where you have 91726493 libraries |
04:59:47 | FromDiscord | <evoalg> How do I import slicterator if it's not in nimble? |
05:00:25 | FromDiscord | <Elegantbeef> `requires "https://github.com/beef331/slicerator#0.10` |
05:00:29 | FromDiscord | <Elegantbeef> in your nimble file |
05:01:01 | FromDiscord | <Elegantbeef> If you dont have a nimble file you can just do `nimble install https://github.com/beef331/slicerator` |
05:01:06 | FromDiscord | <Elegantbeef> Then `import slicerator` |
05:01:33 | FromDiscord | <Elegantbeef> To be fair rika i mostly just made this to show evo how one would handle this π |
05:01:53 | FromDiscord | <evoalg> works! |
05:02:07 | FromDiscord | <impbox [ftsf]> In reply to @evoalg "ok thank you ...": you can create a proc and iterator with the same name and they'll do the right thing |
05:02:27 | FromDiscord | <! ash> :shrug: |
05:02:27 | FromDiscord | <Elegantbeef> Is that a question or a statement? π |
05:02:33 | FromDiscord | <! ash> wow |
05:03:05 | FromDiscord | <Elegantbeef> Wow indeed |
05:06:21 | FromDiscord | <evoalg> "Success: slicterator installed successfully." ... but do I import slicerator or slicterator ? |
05:06:36 | FromDiscord | <Elegantbeef> `import slicerator` |
05:07:04 | FromDiscord | <Elegantbeef> Lol i messed up the repo name |
05:07:30 | FromDiscord | <Rika> Lol |
05:07:34 | FromDiscord | <Rika> Like you always do |
05:07:38 | FromDiscord | <Elegantbeef> should be `import sliceterator` |
05:07:53 | FromDiscord | <Elegantbeef> Thanks rika, you're my best friend |
05:08:37 | FromDiscord | <Elegantbeef> You might ask yourself "Where would we be without rika" and the answer is "happy" |
05:08:51 | FromDiscord | <evoalg> or "imoport slicterator" ? |
05:09:10 | FromDiscord | <Elegantbeef> Just monkey at the keyboard it until it works |
05:09:31 | FromDiscord | <Elegantbeef> Do you have a `projectname.nimble`? |
05:09:47 | FromDiscord | <evoalg> "slicterator" worked not "sliceterator" |
05:10:34 | FromDiscord | <evoalg> ... in ~/.nimble/ I only have: bin nimbledata.json packages_official.json packages_temp.json pkgs |
05:11:01 | FromDiscord | <Elegantbeef> That's not what i meant |
05:11:16 | FromDiscord | <Elegantbeef> You generally want to have a nimble file for your project so you can pin dependancies |
05:11:30 | FromDiscord | <Elegantbeef> https://github.com/beef331/truss3d/blob/master/truss3D.nimble stuff like this |
05:13:07 | FromDiscord | <evoalg> oh ... would I put that in the same dir as my nim files? |
05:14:57 | FromDiscord | <Elegantbeef> Yea for your project so you dont need to manually fetch all dependancies if you move computers |
05:15:21 | FromDiscord | <evoalg> ie if I have a myprogram.nim and I'm programming and have includes etc, would I put myprogram.nimble in the same directory ... ahh ok |
05:15:36 | FromDiscord | <evoalg> makes sense! |
05:15:50 | FromDiscord | <Elegantbeef> It's more for libraries/serious projects, for one off stuff it doesnt matter |
05:16:11 | FromDiscord | <evoalg> gotcha ... I guess I'm just playing around learning at the moment |
05:17:11 | FromDiscord | <Elegantbeef> Well then yea no purpose making nimble |
05:17:47 | FromDiscord | <evoalg> I have to run out for a bit ... will play later ... thank you for your help Elegantbeef π |
05:18:24 | FromDiscord | <Rika> Please pin your dependencies |
05:19:06 | FromDiscord | <Elegantbeef> No problem |
05:19:16 | FromDiscord | <Elegantbeef> With evo i probably should make that tip jar impbox π |
05:19:31 | FromDiscord | <impbox> you totally should make a tip jar |
05:20:05 | FromDiscord | <Elegantbeef> I should figure out my opengl issue π |
05:20:35 | FromDiscord | <impbox> what's the prob? |
05:20:43 | FromDiscord | <Elegantbeef> the opengl debug handler causes a seg fault |
05:20:53 | FromDiscord | <Elegantbeef> Atleast enabling it causes it |
05:22:07 | * | blackbeard420 quit (Quit: ZNC 1.8.2 - https://znc.in) |
05:22:17 | * | blackbeard420_ joined #nim |
05:22:17 | FromDiscord | <impbox> hmm, i've used it successfully in the past |
05:24:05 | FromDiscord | <impbox> but also getting crashes now when i use it |
05:24:13 | FromDiscord | <Elegantbeef> Oh so it's not just me?! |
05:25:08 | FromDiscord | <Yardanico> nim is good for when you're too lazy to calculate some stuff by hand :) at the level of python |
05:27:40 | * | riceman_ joined #nim |
05:27:58 | FromDiscord | <impbox> [Elegantbeef](https://matrix.to/#/@elegantbeef:matrix.org)\: seems not, i can't get it to work, can look into it a bit more later |
05:28:15 | * | ecs quit (Ping timeout: 268 seconds) |
05:28:35 | FromDiscord | <Elegantbeef> Appreciated if you can, mine works sometimes but seg faults others |
05:28:41 | FromDiscord | <Elegantbeef> So something is off |
05:29:08 | FromDiscord | <Elegantbeef> Sometimes gdb points towards my gpu drivers sometimes to nim code |
05:29:21 | FromDiscord | <impbox [ftsf]> i'm certain it worked at some point in the past, wonder if a driver update broke it |
05:29:26 | FromDiscord | <impbox [ftsf]> on NVIDIA here |
05:29:36 | FromDiscord | <Elegantbeef> AMD OSS linux drivers here |
05:29:44 | FromDiscord | <impbox [ftsf]> hmm unlikely then |
05:30:12 | * | ecs joined #nim |
05:30:28 | * | krux02 quit (Remote host closed the connection) |
05:30:30 | FromDiscord | <Elegantbeef> https://play.nim-lang.org/#ix=3EEX the odd backtrace from gdb |
05:31:01 | FromDiscord | <Elegantbeef> You're on windows right? |
05:31:06 | FromDiscord | <impbox [ftsf]> yaa |
05:31:24 | FromDiscord | <Elegantbeef> Odd |
05:31:47 | FromDiscord | <Elegantbeef> The last PR was in july |
06:50:43 | FromDiscord | <evoalg> In reply to @Elegantbeef "With evo i probably": Sure let me know when you make a tip jar |
06:51:26 | FromDiscord | <Rika> Damn people tip others for stuff like this? |
06:51:46 | FromDiscord | <Elegantbeef> Fuck if i know impbox suggested it half joking |
06:51:53 | FromDiscord | <Elegantbeef> I jokingly referenced it |
06:52:12 | FromDiscord | <Elegantbeef> Also if impbox responds on discord when i referenced him on matrix i'll question their sanity |
06:52:17 | FromDiscord | <impbox [ftsf]> not jokingly |
06:52:50 | FromDiscord | <Rika> BRB setting up a tip jar 9/10ths jk |
06:53:11 | FromDiscord | <evoalg> I dunno what's expected, I just know Elegantbeef has been answering so many of my noob questions with nice examples |
06:53:49 | FromDiscord | <Rika> Sounds like I need to be home more |
06:54:11 | FromDiscord | <Elegantbeef> You act like you'd be rolling in money |
06:54:39 | FromDiscord | <evoalg> and I try and limit my noob questions to 2 per day ... but then answers raise more questions as usual π |
06:54:46 | FromDiscord | <impbox [ftsf]> well the amount of time you spend helping people here, i figure you're either unemployed or about to get fired, so i figure you could use a tip jar |
06:55:04 | FromDiscord | <Rika> Beef: you donβt know how valuable even a dollar is to me lol |
06:55:06 | FromDiscord | <Elegantbeef> Damn imp is onto me |
06:55:16 | FromDiscord | <Elegantbeef> Well then pitter patter |
06:55:32 | FromDiscord | <impbox [ftsf]> unless beef is getting some of those donated cryptobucks for being our mascot |
06:55:45 | FromDiscord | <Elegantbeef> Sadly not |
06:55:51 | FromDiscord | <Rika> Lol |
06:56:05 | FromDiscord | <Elegantbeef> I'm unemployed, but not needing money |
06:56:40 | FromDiscord | <Rika> Imagine not needing money |
06:56:41 | FromDiscord | <Rika> MBN |
06:56:59 | FromDiscord | <impbox [ftsf]> ahh the glucose guardian |
06:57:08 | FromDiscord | <Rika> What |
06:57:51 | FromDiscord | <Elegantbeef> Probably an australianism |
06:59:41 | FromDiscord | <Elegantbeef> Seems to be gender neutral for someone that doesnt work and gets money from a SO |
07:00:05 | FromDiscord | <Rika> Eh |
07:00:11 | FromDiscord | <Rika> Do you have an SO? I donβt actually know |
07:00:17 | FromDiscord | <Elegantbeef> Nope |
07:03:24 | FromDiscord | <evoalg> I had to look at urban dictionary to find what SO stood for, geez I'm so out of touch with that sort of speak |
07:03:48 | FromDiscord | <Elegantbeef> Evoalg outting that they're a 40 year old π |
07:04:02 | FromDiscord | <evoalg> If I were only that young |
07:04:04 | FromDiscord | <Rika> Better than most, still willing to learn |
07:04:32 | FromDiscord | <evoalg> I'm 53 |
07:04:41 | FromDiscord | <Elegantbeef> Of course, no one is to close to death to learn to program, i mean no one is too old to lear... i mean.... |
07:05:15 | FromDiscord | <Elegantbeef> Is that joke too dark? Hmm i'll have to find a flash light to see |
07:05:30 | FromDiscord | <Rika> Didnβt know you were legally blind |
07:05:37 | FromDiscord | <Elegantbeef> Only occasionally |
07:06:31 | FromDiscord | <evoalg> ... and it's difficult to keep up with you youngsters |
07:06:45 | FromDiscord | <Rika> Yeah Iβm under 25 |
07:06:51 | FromDiscord | <Rika> Tehe |
07:06:53 | FromDiscord | <Elegantbeef> Just go get your cricket bat and cap us |
07:06:56 | FromDiscord | <Elegantbeef> It'll slow us down |
07:07:14 | FromDiscord | <Elegantbeef> I forget if Rika is younger than me |
07:07:20 | FromDiscord | <Rika> Quick, use very zoomer-level slang |
07:07:24 | FromDiscord | <Rika> Obviously |
07:07:31 | FromDiscord | <Elegantbeef> Nah i'm not a fucking degenerate |
07:07:36 | FromDiscord | <Rika> I am younger than basically everyone here |
07:07:45 | FromDiscord | <Rika> Yet older than most teenagers |
07:08:11 | FromDiscord | <Elegantbeef> "Obviously" is so rude |
07:08:43 | FromDiscord | <Elegantbeef> People often think i'm 30 cause of how i type, so that's always fun |
07:08:52 | FromDiscord | <impbox [ftsf]> slowly? |
07:08:59 | FromDiscord | <impbox [ftsf]> with one finger? |
07:09:14 | FromDiscord | <Elegantbeef> Impbox the person with RSI talking about typing slow?! |
07:09:23 | FromDiscord | <Rika> I meant it more like βobviouslyβ as in against me than against you |
07:09:25 | FromDiscord | <Elegantbeef> Jeez i'm surprised your hands let you type insults like that |
07:09:41 | FromDiscord | <Rika> I donβt think 30 year olds use single finger typing |
07:09:46 | FromDiscord | <Rika> Iβd say some 40 |
07:09:58 | FromDiscord | <Elegantbeef> Evoalg nervously looks around |
07:10:10 | FromDiscord | <Rika> I doubt he does use single finger typing |
07:10:13 | FromDiscord | <impbox [ftsf]> i thought it was the youngsters who can't type fast because they're used to touchscreens? |
07:10:17 | FromDiscord | <evoalg> I'm one of the few of my generation to touch type |
07:10:20 | FromDiscord | <Rika> Nice |
07:10:29 | FromDiscord | <Rika> In reply to @impbox "i thought it was": I guess? |
07:10:31 | FromDiscord | <impbox [ftsf]> typewriters have been around for a long time |
07:10:44 | FromDiscord | <Elegantbeef> For sure he probably learned to touch type on an commodore 64 or whatever the kiwi equivlent is |
07:10:50 | FromDiscord | <Rika> Though I assume you mean the way younger youngsters since most people I know touch type |
07:10:57 | FromDiscord | <impbox [ftsf]> i learnt to type on a typewriter as a kid |
07:11:06 | FromDiscord | <evoalg> I did have a commodore 64 actually |
07:11:10 | FromDiscord | <Rika> Me too even if Iβm like under 20 |
07:11:14 | FromDiscord | <impbox [ftsf]> but it was one of those fancy electronic typewriters |
07:11:20 | FromDiscord | <Rika> Rather 25, Iβm not fucking under 20 |
07:11:24 | FromDiscord | <Rika> Mistype |
07:11:32 | FromDiscord | <Elegantbeef> See rika we're not that far apart in age |
07:11:35 | FromDiscord | <Elegantbeef> I'm only 22 |
07:11:36 | FromDiscord | <Rika> My brain is lagging behind my real age |
07:11:52 | FromDiscord | <impbox [ftsf]> so sleek https://media.discordapp.net/attachments/371759389889003532/908252670404464680/unknown.png |
07:11:55 | FromDiscord | <Rika> Beef I was sure you were like 27 or something Christ |
07:12:12 | FromDiscord | <Elegantbeef> See look what i saidd |
07:12:14 | FromDiscord | <Rika> Ah my grandfather had a real mechanical typewriter and I used it before |
07:12:20 | FromDiscord | <Elegantbeef> I type like an asshole apparently |
07:12:26 | FromDiscord | <impbox [ftsf]> yeah, i think we had a mechanical one too |
07:12:28 | FromDiscord | <Rika> Beef: whatβs new? |
07:12:29 | FromDiscord | <Elegantbeef> Well typing like an asshole was a given |
07:12:30 | FromDiscord | <impbox [ftsf]> it made cool sounds |
07:12:36 | FromDiscord | <Rika> Exactly beef |
07:13:06 | FromDiscord | <Elegantbeef> One person said that "you're so jaded which is why you seem old" |
07:13:10 | FromDiscord | <Rika> They made cool sounds but you better have fingers made of lead to type anything more than a paragraph on them |
07:13:40 | FromDiscord | <Rika> Beef I guess your communication reflects more of the older generation than our own generation |
07:14:22 | FromDiscord | <Elegantbeef> Yea certainly |
07:14:45 | FromDiscord | <Rika> I bet I sound like my age though |
07:15:45 | FromDiscord | <Elegantbeef> If you mean a zoomer that uses tiktok unironically, probably π |
07:16:16 | FromDiscord | <Rika> I donβt use tiktok what the fuck dude |
07:16:41 | FromDiscord | <impbox [ftsf]> but it's what all the cool kids are using these days? |
07:17:15 | FromDiscord | <impbox [ftsf]> maybe can do nim tutorials on tiktok |
07:17:25 | FromDiscord | <Elegantbeef> !ban @impbox [ftsf] |
07:17:41 | FromDiscord | <Rika> What the fuck |
07:17:44 | FromDiscord | <Rika> Heresy |
07:18:08 | FromDiscord | <Rika> In reply to @impbox "but it's what all": I mean I guess you can become big as an influencer or entertainer |
07:18:11 | FromDiscord | <Rika> With using it |
07:20:40 | FromDiscord | <Elegantbeef> evoalg's now reminiscing about making stuff using basic, we've lost them |
07:20:52 | FromDiscord | <impbox [ftsf]> those were good times |
07:21:19 | FromDiscord | <Elegantbeef> Wouldnt know, do want to get a commedore eventually though |
07:21:22 | FromDiscord | <Rika> What |
07:21:33 | FromDiscord | <evoalg> why? |
07:21:33 | FromDiscord | <Rika> Sorry I spaced out |
07:22:30 | FromDiscord | <impbox [ftsf]> dunno how we did programming without the internet back then |
07:22:46 | FromDiscord | <evoalg> books |
07:23:46 | FromDiscord | <Rika> I probably could program without internet given the documentation pages of Nim and libraries |
07:23:47 | FromDiscord | <impbox [ftsf]> mmm i somehow learnt qbasic using the help files and a few example scripts, though i never learn to how to return, so i'd always blow the stack and i thought it was just a limitation of qbasic and i needed to upgrade or something |
07:23:54 | FromDiscord | <Rika> In print or in file |
07:24:19 | FromDiscord | <evoalg> but although I've dabbled in bits & pieces, I've never been a serious programmer or anything, I've just sometimes used programming languages to do stuff occasionally ... I don't know much |
07:25:22 | FromDiscord | <Elegantbeef> How'd you stumble onto nim? |
07:25:46 | FromDiscord | <impbox [ftsf]> finally made it back on topic, nice |
07:27:01 | FromDiscord | <Rika> In reply to @evoalg "but although I've dabbled": Isnβt that pretty much everything programmers are? βI just wanted to do this automatically and then I became a programmerβ xd |
07:27:03 | FromDiscord | <evoalg> ahhh well python is a natural fit as I don't have to think about it too much, but then I had some ideas about doing something more serious, and so I wanted speed but I also didn't want me code easily read, so I started reading about compiling (even though some of that can be reversed) and one of the things I read about was nim |
07:27:34 | FromDiscord | <Rika> Lol thatβs one more on the βI looked for fast Pythonβ boat |
07:27:47 | FromDiscord | <Elegantbeef> Ah python -\> nim path for fast automation |
07:28:27 | FromDiscord | <impbox [ftsf]> i used to do a lot of python at old job, i loved it at first (after coming from php eww) |
07:28:54 | FromDiscord | <evoalg> I mean I've never had a job as a programmer ... it's just a hobby, and so I don't know much, hence all my noob questions |
07:29:18 | FromDiscord | <Elegantbeef> hey it's technically a hobby for me aswell |
07:29:36 | FromDiscord | <impbox [ftsf]> it's better as a hobby |
07:29:44 | FromDiscord | <impbox [ftsf]> though as far as jobs go, it's probably pretty good |
07:30:48 | FromDiscord | <Rika> It gets ya the money if ya ainβt picky |
07:31:41 | FromDiscord | <evoalg> so if I wanted to solve some math thing, I'd automatically fire up ipython ... and if fact I'm going through last years advent of code (which I've never done before) and trying them in both python and nim ... to help me learn nim ... and comparing my answers with narimiran's answer on github |
07:32:58 | FromDiscord | <Elegantbeef> Well if you ever want a code review you know where to find me |
07:33:25 | FromDiscord | <evoalg> Thank you Elegantbeef! |
07:34:52 | FromDiscord | <evoalg> but it's natural for me to first play around in ipython, and at the moment it takes me much longer to do it in nim. I find that my programming is very bottom-up and non-functional, so my python solutions look pretty similar to my nim ones |
07:35:11 | FromDiscord | <Rika> Nothing wrong with that is there? |
07:36:53 | FromDiscord | <evoalg> while I'm sharing, my ultimate goal is to try and program AGI ... not machine learning (as I don't like that) but true AGI like the arc challenge https://www.kaggle.com/c/abstraction-and-reasoning-challenge |
07:37:00 | FromDiscord | <Yardanico> wow |
07:37:07 | FromDiscord | <Yardanico> that's a very nice life goal :) |
07:37:13 | * | LyndsySimon quit (Ping timeout: 256 seconds) |
07:37:38 | FromDiscord | <Yardanico> i hope to see AGI during my lifetime |
07:38:04 | * | LyndsySimon joined #nim |
07:38:23 | FromDiscord | <Rika> AGI is very challenging isnβt it |
07:38:25 | FromDiscord | <evoalg> heh yea it's a pretty grand goal but it's the only think I'm interested in, and I don't believe that machine learning is the way forward (and I don't like it) |
07:38:40 | FromDiscord | <Rika> Well it clearly isnβt, thereβs something missing to it |
07:39:04 | FromDiscord | <Yardanico> In reply to @Rika "Well it clearly isnβt,": 86 billion neurons with complex interactions |
07:39:23 | FromDiscord | <Yardanico> but of course simply copying the human brain might be far from the best way to do AGI |
07:39:29 | FromDiscord | <impbox [ftsf]> ahh AGI is different to what I thought |
07:39:33 | FromDiscord | <evoalg> the most interesting and intriguing thing about AGI is that we've made such little progress, and it'll take some real out-of-the-box thinking and anyone might be able to come up with, even me |
07:39:49 | FromDiscord | <impbox [ftsf]> https://en.wikipedia.org/wiki/Adventure_Game_Interpreter |
07:39:52 | FromDiscord | <Yardanico> we just don't know anything than a human brain that can have true intelligence |
07:39:55 | FromDiscord | <Yardanico> In reply to @impbox "https://en.wikipedia.org/wiki/Adventure_Game_Interp": lol |
07:40:00 | FromDiscord | <Rika> https://en.m.wikipedia.org/wiki/Artificial_general_intelligence |
07:40:12 | FromDiscord | <Rika> For the curious |
07:40:44 | FromDiscord | <impbox [ftsf]> ahh |
07:40:55 | FromDiscord | <impbox [ftsf]> close |
07:41:13 | FromDiscord | <evoalg> Yardanico I can tell you know what you're talking about ... most people think it's just around the corner and that Elon Musk will invent it |
07:41:37 | FromDiscord | <Yardanico> i don't know much, I just like to read sci-fi novels :P |
07:42:19 | FromDiscord | <Rika> In reply to @Yardanico "we just don't know": Then we donβt even know how it fucking works lol |
07:42:25 | FromDiscord | <Yardanico> exactly |
07:42:39 | FromDiscord | <evoalg> that's absolutely right |
07:43:39 | FromDiscord | <Rika> Think Iβve thought a bit too much today, Iβve been brainstorming hard for a few hours and Iβm tired |
07:43:41 | FromDiscord | <Elegantbeef> I hope this doesnt mean evo is a musk fan π |
07:43:54 | FromDiscord | <evoalg> no I am not! |
07:44:06 | FromDiscord | <Rika> Beef you are, bet |
07:44:21 | FromDiscord | <Elegantbeef> Do i have douche energy |
07:44:32 | FromDiscord | <Rika> Youβre seriously asking that? |
07:44:42 | FromDiscord | <Elegantbeef> Hey self awareness is for losers |
07:44:43 | FromDiscord | <impbox [ftsf]> i used to think he was cool when i was younger =\ i am ashamed |
07:46:56 | FromDiscord | <Elegantbeef> It's ok, we all get sold snake oil once in our lives |
07:50:26 | FromDiscord | <evoalg> it's easy to get trapped down the path in machine learning with AlphaGo and big NN's, and there's a lot of money in it too actually, but I want to purposely take a path where it might be untravelled |
07:51:07 | FromDiscord | <Rika> Thatβs nice |
07:51:08 | FromDiscord | <Elegantbeef> The only thing i know about AI is that it's a bunch of ifstatements π |
07:51:16 | FromDiscord | <Elegantbeef> Wait that's my game dev hat speaking |
07:51:38 | FromDiscord | <impbox [ftsf]> FSMs are the future of AI |
07:51:49 | FromDiscord | <Elegantbeef> See imp gets it |
07:52:06 | FromDiscord | <Rika> Well technically |
07:52:28 | FromDiscord | <Rika> Current AI could be said to be just some really complicated FSM canβt it lol |
07:53:25 | FromDiscord | <evoalg> true AI, which is AGI, it's more like a 3 month old has leaned things we haven't even come close to getting computers to learn |
07:54:25 | FromDiscord | <evoalg> they can already make abstract inferences that no computer program can (yet) |
07:54:53 | FromDiscord | <evoalg> yes they can't do times tables or even count properly |
07:55:03 | FromDiscord | <evoalg> fascinating stuff π |
07:55:23 | FromDiscord | <Elegantbeef> Do any know why children love the taste of cinnamon toast crunch? |
07:55:32 | FromDiscord | <impbox [ftsf]> i played around a bit with linear regression and stuff, pretty cool, and q learning seems fun |
07:55:46 | FromDiscord | <impbox [ftsf]> speaking of i need to improve my racing AI |
07:55:56 | FromDiscord | <impbox [ftsf]> currently it's just a couple of PID controllers |
08:00:37 | * | ecs quit (Read error: Connection reset by peer) |
08:00:44 | * | ecs joined #nim |
08:02:57 | FromDiscord | <evoalg> A chess playing program is very cool, but in terms of true intelligence it's very dense. No-one has come close to creating the intelligence of a dog, for example. |
08:03:12 | FromDiscord | <evoalg> anyway I digress |
08:03:39 | FromDiscord | <evoalg> the point is, I'm not sure the python will be enough for my needs π |
08:03:53 | FromDiscord | <Rika> It probably wonβt lol |
08:04:03 | FromDiscord | <impbox [ftsf]> depends how long you want to wait |
08:04:12 | FromDiscord | <Rika> The fast stuff is in C and are for traditional machine learning |
08:04:13 | FromDiscord | <impbox [ftsf]> does AGI need to be fast? |
08:04:31 | FromDiscord | <evoalg> In reply to @impbox "does AGI need to": very good question |
08:04:38 | FromDiscord | <impbox [ftsf]> deep thought wasn't very fast |
08:04:39 | FromDiscord | <Rika> In reply to @impbox "does AGI need to": It probably has a lot of complex pieces that need to be fast for the whole thing to even be viable |
08:05:02 | FromDiscord | <Rika> Iterating every few days is agonising |
08:05:20 | FromDiscord | <Yardanico> playing around a bit more with wasm4 https://media.discordapp.net/attachments/371759389889003532/908266127317160027/unknown.png |
08:05:25 | FromDiscord | <impbox [ftsf]> nice |
08:05:45 | FromDiscord | <Elegantbeef> What're you using? |
08:05:48 | FromDiscord | <Yardanico> (i don't know how to properly color mandelbrot and I just used the code from rosetta) https://media.discordapp.net/attachments/371759389889003532/908266244711538709/unknown.png |
08:05:56 | FromDiscord | <Yardanico> @ElegantBeef https://wasm4.org/ |
08:06:09 | FromDiscord | <Yardanico> yesterday dom referred me to a tweet by contextfree about wasm4 for nim |
08:06:12 | FromDiscord | <Elegantbeef> Ah didnt realize it was a fantasy console |
08:06:30 | FromDiscord | <Elegantbeef> wasm4 + nimscript π |
08:06:37 | FromDiscord | <Yardanico> 64KB hard binary limit :) |
08:06:41 | FromDiscord | <Yardanico> and total memory limit |
08:06:48 | FromDiscord | <Elegantbeef> Ah shucks |
08:06:50 | FromDiscord | <Yardanico> so only native languages qualify |
08:06:51 | FromDiscord | <impbox [ftsf]> yeah the name is a bit misleading |
08:07:03 | FromDiscord | <Rika> The limit is only for fun right |
08:07:16 | FromDiscord | <Yardanico> not sure what you mean |
08:07:21 | FromDiscord | <impbox [ftsf]> fantasy consoles are serious business |
08:07:24 | FromDiscord | <Yardanico> the binary limit - yes, it's not actually enforced unless you want to publish |
08:07:27 | FromDiscord | <Yardanico> but memory limit is enforced |
08:07:29 | FromDiscord | <Rika> For no real reason but to be there |
08:07:32 | FromDiscord | <Yardanico> yes |
08:07:41 | FromDiscord | <Rika> Okay I see |
08:07:44 | FromDiscord | <impbox [ftsf]> limitations to push creativity |
08:07:47 | FromDiscord | <Yardanico> you can allocate gigabytes of RAM with wasm and have binaries the size of tens of MBs |
08:08:11 | FromDiscord | <Yardanico> but yeah, with WASI SDK and wasm-opt nim wasm binaries are really small (almost same as C) |
08:08:16 | FromDiscord | <Yardanico> if you don't allocate memory of course :) |
08:08:33 | FromDiscord | <Yardanico> WASI uses dlmalloc for memory allocation so that's +9KB to your binary (after all optimizations) |
08:08:44 | FromDiscord | <Yardanico> i mean heap allocations |
08:35:04 | * | riceman_ quit (Ping timeout: 256 seconds) |
08:36:21 | FromDiscord | <evoalg> In reply to @Elegantbeef "To be fair rika": If it's a personal module, would an include file be just as good? I'm trying understand what's the advantage of a module if it's just a personal one, or are modules intended to be shared? |
08:38:15 | FromDiscord | <Elegantbeef> Include has different semantics if that's what you're talking about |
08:38:20 | FromDiscord | <Rika> Yes |
08:38:25 | FromDiscord | <Rika> It βduplicates codeβ |
08:38:32 | FromDiscord | <Rika> If you include the same module in two other files |
08:38:50 | FromDiscord | <impbox> as to why you'd choose one over the other... i dunno, i just put all my code in one file mostly |
08:38:51 | FromDiscord | <Rika> You canβt use that moduleβs types to pass data to other files |
08:39:01 | FromDiscord | <Rika> Most people opt for imports because itβs just whatβs recommende |
08:39:02 | FromDiscord | <Rika> S |
08:39:07 | FromDiscord | <Rika> In reply to @Rika "S": D |
08:39:11 | FromDiscord | <impbox> yeah, i use import when i split things up |
08:39:23 | FromDiscord | <Rika> Include is really for special cases |
08:39:23 | FromDiscord | <Elegantbeef> Well imports let you actually use modules, include is just splitting large files up and it's generally bad form |
08:39:56 | FromDiscord | <Rika> βActually use modulesβ is vague |
08:40:15 | FromDiscord | <impbox> include feels like C, and that's probably my most hated bit of C |
08:40:17 | FromDiscord | <Elegantbeef> Well include copy pastes the file into the `include` site so things like `yourModule.name` doesnt work |
08:40:42 | FromDiscord | <Rika> But basically if you include A in two files B and C, you canβt use Aβs types included in B with functions that take in Aβs types included in C |
08:41:00 | FromDiscord | <Rika> Since itβs just copy paste, there are two types named the same but are actually different |
08:42:21 | FromDiscord | <Rika> Itβs functionally equivalent to defining the same types in module B and C, sure theyβre the same name and the same data, but since theyβre in different modules, theyβre treated differently |
08:42:37 | FromDiscord | <Rika> And then including both B and C into a file D would probably cause an error |
08:42:50 | FromDiscord | <Rika> Also you donβt get access modifiers this way afaik |
08:43:18 | FromDiscord | <impbox> yeah, they're considered local to that file |
08:43:18 | FromDiscord | <Rika> Thereβs just a lot of generally undesirable behaviour in including |
08:44:39 | * | neurocyte0132889 joined #nim |
08:44:39 | * | neurocyte0132889 quit (Changing host) |
08:44:39 | * | neurocyte0132889 joined #nim |
08:45:16 | FromDiscord | <evoalg> so if I write a proc that depends on strutils (for example), and I import my file instead of include it, I'd also have to import strutils? (if I'm making sense) |
08:45:38 | FromDiscord | <Rika> Yes since imports do not implicitly transfer |
08:46:12 | FromDiscord | <Rika> You can either import again in the importing file or `export strutils` in the imported file |
08:46:42 | FromDiscord | <evoalg> oh I didn't know about export |
08:46:47 | FromDiscord | <Rika> Which you use is up to you |
08:46:59 | FromDiscord | <Rika> Most prefer importing again |
08:47:05 | FromDiscord | <Elegantbeef> Well if a proc depends on strutils you do not need to import strutilsβ΅(@evoalg) |
08:47:06 | FromDiscord | <Rika> A few prefer the export |
08:47:22 | FromDiscord | <Rika> In reply to @Elegantbeef "Well if a proc": But if a type does then you would need to |
08:47:26 | FromDiscord | <Rika> I misread |
08:47:57 | FromDiscord | <Elegantbeef> You can use `export` for all symbols so `proc` `module` `var/let/const`s... |
08:48:09 | FromDiscord | <impbox> think of include as saying "paste this file here", that's pretty much all it is |
08:48:15 | FromDiscord | <impbox> but usually it's not what you want |
08:48:23 | FromDiscord | <impbox> import is much cnier |
08:48:26 | FromDiscord | <impbox> nicer\ |
08:48:53 | FromDiscord | <Rika> Itβs hard to explain when to export |
08:49:02 | FromDiscord | <Rika> But you donβt need to if only your procs need the module |
08:49:28 | FromDiscord | <evoalg> when I import something that's in nimble, like strutils, I never have to import anything that it might rely on (which it good) |
08:49:34 | FromDiscord | <Rika> Yes |
08:50:08 | FromDiscord | <Rika> Sometimes it does expose to you things that you might need to rely on for ergonomics |
08:50:47 | FromDiscord | <Rika> Like letβs say I have a module βjsonβ and I have it split into stuff like βparserβ and βserialiserβ files or so |
08:51:05 | * | LyndsySimon quit (Ping timeout: 264 seconds) |
08:51:05 | FromDiscord | <Rika> I donβt want to import json/parser and json/serialiser all the time or whatever |
08:51:16 | FromDiscord | <Rika> So you can just make the json module file export those two |
08:51:25 | FromDiscord | <Rika> Now you just need to import json and you have both |
08:51:35 | FromDiscord | <Rika> Without including |
08:51:39 | * | LyndsySimon joined #nim |
08:51:49 | FromDiscord | <Rika> Because including has caveats while export generally doesnβt |
08:51:53 | * | pro joined #nim |
08:52:13 | FromDiscord | <Rika> Or rather, including has more caveats than edporting |
08:52:15 | FromDiscord | <Rika> Exporting |
08:53:34 | FromDiscord | <Rika> Itβs for convenience is the gist I guess |
08:53:54 | FromDiscord | <Rika> So you donβt need to keep on importing common modules you would need for a portion of your system |
08:54:24 | FromDiscord | <Rika> If you have a database module I donβt want to keep on importing certain files every time so I collate all module imports and export them in a common database module file |
08:55:17 | FromDiscord | <evoalg> Nice thank you Rika. I can put personal procs I've made into a file and import them (as long as I use the in the right places), but when would I put them into a github module like ElegantBeef did with slicterator ? |
08:55:35 | FromDiscord | <Elegantbeef> When you want to easily distribute them |
08:55:58 | FromDiscord | <Rika> If you want to share π |
08:56:04 | * | PMunch joined #nim |
08:56:10 | FromDiscord | <Elegantbeef> Well or want to easily develop/depend on it π |
08:56:18 | FromDiscord | <evoalg> nice I understand (or I'm starting to) |
08:56:23 | FromDiscord | <Rika> You donβt need to put it in GitHub for that |
08:56:37 | FromDiscord | <Rika> Could just make it a local git repo |
08:57:19 | FromDiscord | <evoalg> I'll try and keep things simple for as long as I can π |
08:57:37 | FromDiscord | <Rika> Whatever floats your boat I guess |
08:57:45 | FromDiscord | <Rika> I tend to do as complex as I can handle to learn stuff |
08:59:19 | FromDiscord | <evoalg> hehe this is just a bit overwhelming ... but yea I was all intent on splitting code and using includes, but now I'll use imports, and for large bits of code I can fold it away (something I've never used before if you can believe it) |
08:59:36 | FromDiscord | <evoalg> (I've never used folds before neovim) |
09:02:42 | FromDiscord | <Rika> Most people havenβt used it afaik |
09:03:03 | FromDiscord | <Elegantbeef> You can fold code?! π |
09:03:18 | FromDiscord | <Elegantbeef> I dont tend to fold code unless i'm debugging and need to really clear my mind |
09:04:28 | FromDiscord | <Rika> I tend to fold code when it is larger than a few lines |
09:04:32 | FromDiscord | <Rika> Letβs say 20 |
09:04:51 | PMunch | I tend to fold mine into nice little paper crane |
09:04:51 | FromDiscord | <impbox> i usually find folding more annoying than not using it |
09:05:06 | FromDiscord | <Elegantbeef> Dont lie pmunch, i've seen your code π |
09:05:17 | PMunch | Hehe |
09:05:47 | * | notchris quit (Ping timeout: 264 seconds) |
09:05:59 | FromDiscord | <evoalg> I don't know why I'm laughing so much at that, I must be tired |
09:06:07 | FromDiscord | <Rika> Folding gets useful when youβre at a few thousand lines really |
09:06:14 | FromDiscord | <Rika> Itβs pretty funny |
09:06:30 | * | notchris joined #nim |
09:06:43 | FromDiscord | <Elegantbeef> I'm a fantastic comedian, atleast people laugh at my face |
09:07:18 | PMunch | That's true comedy, making people laugh without even opening your mouth |
09:09:58 | FromDiscord | <impbox> image.png https://media.discordapp.net/attachments/371759389889003532/908282393679499284/image.png |
09:10:04 | FromDiscord | <impbox> i do like this kind of thing to help me navigate around |
09:10:18 | FromDiscord | <Elegantbeef> You dont like const blocks do you? |
09:10:21 | FromDiscord | <impbox> i find it more helpful than folding |
09:10:26 | FromDiscord | <Rika> Or import blocks |
09:10:34 | FromDiscord | <impbox> i should get into the habit of using blocks for things |
09:10:36 | FromDiscord | <impbox> i just never think of it |
09:10:57 | FromDiscord | <Rika> Thankfully itβs easy if theyβre in a line like that |
09:11:26 | FromDiscord | <Rika> Just put the first one in a new line then replace every other occurrence of βconstβ with a space |
09:11:26 | FromDiscord | <impbox> i guess i just duplicate line and change |
09:11:48 | FromDiscord | <Rika> Ah I guess the multi line ones need an indent too |
09:11:48 | FromDiscord | <Elegantbeef> Let's bike shed about other stuff! |
09:12:05 | FromDiscord | <Rika> Use an enum for those sfx values smh |
09:12:32 | FromDiscord | <Rika> Etc hehe |
09:12:33 | FromDiscord | <impbox> mmm i did use an enum in the past with a converter |
09:12:39 | FromDiscord | <impbox> i forget why it switched to consts |
09:12:41 | FromDiscord | <Rika> You do it beef Iβm mentally dead |
09:12:51 | FromDiscord | <Elegantbeef> you dont need a converter, you just do it `$yourEnum` |
09:13:17 | FromDiscord | <impbox> i'm passing them to procs that take an int |
09:13:30 | FromDiscord | <Rika> Then just make it take an enum instead hehe |
09:13:31 | PMunch | Then `.int` them? |
09:13:35 | PMunch | Or that :P |
09:13:36 | FromDiscord | <Rika> If you canβt use ord |
09:13:43 | FromDiscord | <Elegantbeef> using `self` for all your procedures! |
09:13:46 | FromDiscord | <impbox> the procs are in another module |
09:13:49 | FromDiscord | <Elegantbeef> That's a paddlin |
09:13:56 | FromDiscord | <Rika> Self is fine IMO but I donβt like it |
09:14:19 | FromDiscord | <Elegantbeef> i prefer `thisFuckingInstanceIsItself` |
09:14:21 | PMunch | I kinda like self when code is organised like this. Makes it more obvious what's going on, same as `result` in a way |
09:14:23 | FromDiscord | <impbox> my sidebar thing uses `self` to know which type to associate it with |
09:14:49 | FromDiscord | <impbox> so i can easily look up functions by their main type |
09:14:52 | FromDiscord | <Elegantbeef> I prefer a slightly more informative variable but to each their own |
09:15:03 | * | PMunch looking at newIngredient |
09:15:06 | FromDiscord | <impbox> eg `draw(cat: Cat)` ? |
09:15:12 | FromDiscord | <Elegantbeef> Hell yea! |
09:15:59 | FromDiscord | <Rika> In reply to @impbox "my sidebar thing uses": The main type is always the first one though? |
09:16:03 | NimEventer | New thread by Markspanbroek: Dot-like operations and calls, see https://forum.nim-lang.org/t/8610 |
09:16:11 | FromDiscord | <impbox> yeah it has special cases for `new` and `init` based on their return type |
09:16:25 | FromDiscord | <impbox> @Rika\: not always |
09:16:49 | FromDiscord | <Rika> Then those procs are wrong smh |
09:16:55 | FromDiscord | <Rika> I kid, example? |
09:17:24 | FromDiscord | <impbox> hmm i forget, but i'm sure i encounter them from time to time and get annoyed |
09:17:35 | FromDiscord | <impbox> in think mostly from stdlib |
09:18:04 | FromDiscord | <impbox> or maybe i'm just tripping |
09:19:48 | FromDiscord | <impbox> ohh that's the reason it's using self not first argument, sometimes it shouldn't be linked to the type of the first argument |
09:20:11 | FromDiscord | <impbox> eg. `gameUpdate(dt: float32)` shouldn't be listed under float32 |
09:20:14 | FromDiscord | <Rika> Ah I can see that |
09:20:50 | FromDiscord | <impbox> `proc drawTextBubble(origin: Vec2i, text: string, color: int, offset = vec2i(0,-4), bg = 7, step = -1) =`β΅and shouldn't be listed under `Vec2i` |
09:21:19 | FromDiscord | <impbox> by making the ones that should be listed under their type use `self` it knows how to display them in a nice way |
09:23:05 | FromDiscord | <Rika> Well I guess I would name it the same as my type so βcontainer: Containerβ |
09:23:13 | FromDiscord | <Rika> So that would be what I would use to group with |
09:23:34 | PMunch | Aah I see, that's actually pretty clever. Can we get this for the official documentation as well? :P |
09:23:52 | * | notchris quit (Read error: No route to host) |
09:23:52 | FromDiscord | <impbox> it's such a pain finding which procs are for which type |
09:23:56 | FromDiscord | <impbox> though less useful for generics |
09:23:59 | * | notchris joined #nim |
09:24:12 | FromDiscord | <impbox> @Rika\: could probably be done, though the regex would be even more messy \>\_\< |
09:24:26 | FromDiscord | <Rika> Wouldnβt be regular anymore |
09:24:27 | FromDiscord | <Elegantbeef> Well i feel like it's subjective, but using a pragma might be more appropriate |
09:25:01 | FromDiscord | <impbox> i want it to not be invasive, other than the kind of naming i'd use anyway |
09:25:31 | FromDiscord | <Rika> Ngl would say the pragma would look ugly as fuuuuck |
09:25:39 | FromDiscord | <Elegantbeef> Like the docgen could look for a `{.self: paramName.}` then attach that procedure to that type in a nice list, given we have free standing procedures |
09:25:56 | FromDiscord | <Elegantbeef> I dont deny it |
09:26:22 | FromDiscord | <impbox> maybe something in the doccoments |
09:26:37 | FromDiscord | <impbox> `## listUnder:string` |
09:27:12 | FromDiscord | <Rika> Ngl kinda feel we need a more structured doc comment scheme |
09:27:16 | FromDiscord | <Rika> Would be easier for tooling |
09:27:28 | PMunch | Oh please god no |
09:27:39 | FromDiscord | <Rika> No I donβt mean the shitty one |
09:27:45 | FromDiscord | <Rika> You know not like javadoc or whatever |
09:27:54 | FromDiscord | <Rika> Something much nicer whilst still being structured |
09:27:56 | PMunch | Structured doc comments are such a pain. People never do them properly, and then they drift away from what they're documenting which just makes matters worse.. |
09:28:39 | FromDiscord | <Rika> I see |
09:29:01 | FromDiscord | <Rika> Maybe structured things should be either a pragma or macro I guess |
09:29:15 | PMunch | What I would like though is argument references. So you can do things like "Argument `myarg` takes a value to be printed" and the compiler will complain if you rename `myarg` without renaming it in your documentation |
09:29:48 | FromDiscord | <Rika> Eh |
09:47:27 | * | mjsir911 quit (Quit: Goodbye, World!) |
09:48:25 | * | mjsir911 joined #nim |
09:57:54 | * | pch quit (Remote host closed the connection) |
09:58:12 | * | pch joined #nim |
11:34:11 | * | krux02 joined #nim |
11:36:16 | PMunch | Is `repr` broken in 1.6.0? |
11:36:18 | PMunch | Error: ambiguous call; both repr_v2.repr(x: uint64) [proc declared in /home/peter/.choosenim/toolchains/nim-1.6.0/lib/system/repr_v2.nim(19, 6)] and repr_v2.repr(x: ref T or ptr T) [proc declared in /home/peter/.choosenim/toolchains/nim-1.6.0/lib/system/repr_v2.nim(133, 6)] match for: (uint16) |
11:51:26 | FromDiscord | <Rika> Why do those match what |
11:56:04 | PMunch | Beats me |
12:06:02 | * | supakeen quit (Quit: WeeChat 3.3) |
12:06:32 | * | supakeen joined #nim |
12:38:21 | FromDiscord | <hmmm> hai nimblets I finally finished my small utility that connects to the web takes some data, does some google level magic calculation and spits out data in csv or html form. Now I kind of want to put this thing on some thingy-like server and execute it every hour. What is the most for dummies way of doing it for a dude that never touched web in his life? Possibly using nim since I hate every single lang out there except python |
12:39:15 | FromDiscord | <Rika> uh |
12:39:19 | FromDiscord | <Rika> good luck |
12:39:24 | FromDiscord | <hmmm> ha! |
12:39:33 | FromDiscord | <Rika> i can think of a few ways but its kinda |
12:39:35 | FromDiscord | <Rika> lol |
12:39:37 | FromDiscord | <Rika> not easy |
12:39:42 | FromDiscord | <hmmm> I knew it was impossible π |
12:39:47 | FromDiscord | <Rika> its not |
12:39:55 | FromDiscord | <Rika> oh maybe you can use heroku |
12:39:58 | FromDiscord | <Rika> not that i know how to |
12:40:00 | FromDiscord | <Rika> but its an option |
12:40:59 | FromDiscord | <hmmm> I do not like the not easy implication π€ |
12:41:45 | FromDiscord | <hmmm> heroku seems ovekill tbh π¬ |
12:45:37 | FromDiscord | <Rika> where do you want to run this then |
12:45:41 | FromDiscord | <Rika> on your desktop? |
12:45:44 | FromDiscord | <Rika> or like on a webserver |
12:45:49 | FromDiscord | <Rika> because that was not clear to me |
12:46:06 | FromDiscord | <Rika> if its not on your desktop then its not getting any simpler than heroku i would say |
12:47:31 | FromDiscord | <hmmm> well I can, but I should leave the desktop up, I wanted to put this crap on a serverthingy if it wasn't an enormous hassle, even a raspberry thingy I think |
12:50:21 | FromDiscord | <Rika> well i guess it can be simple as uh |
12:50:24 | FromDiscord | <Rika> boot raspi |
12:50:26 | FromDiscord | <Rika> put program |
12:50:28 | FromDiscord | <Rika> make crontab |
12:50:30 | FromDiscord | <Rika> done |
12:50:38 | NimEventer | New thread by Oyster: When will nimble be ready for new/nightly nim?, see https://forum.nim-lang.org/t/8611 |
12:50:55 | FromDiscord | <Rika> does this program have a webserver |
12:51:14 | FromDiscord | <hmmm> that's what I want rika, but can people other than me access it? |
12:51:29 | FromDiscord | <Rika> In reply to @Rika "does this program have": i asked that |
12:51:32 | FromDiscord | <Rika> so you want it to do that |
12:51:44 | FromDiscord | <hmmm> yea |
12:51:49 | FromDiscord | <Rika> you're gonna have a hell of a time then i would say, if you dont want to try heroku |
12:53:16 | FromDiscord | <Rika> sent a long message, see https://paste.rs/Y5w |
12:53:31 | FromDiscord | <Rika> (afaik most ISPs are using cgnat?) |
12:56:17 | FromDiscord | <hmmm> money is not a problem in general but still if the data served is minimal and the usecase is minimal too I expect to find a solution with appropriate costs, otherwise I can just call someone and pay him to do it for me. Since it's just an hobby project I wanted to DIY |
12:57:09 | FromDiscord | <Rika> i assume its a very cpu-lax program so its prolly gonna cost like idk 2 dollars a month if you try hard to look for the provider |
12:57:21 | FromDiscord | <Rika> (for bare metal, i mean) |
12:57:29 | FromDiscord | <Rika> im no pro at managed providers so i dont know their pricing |
12:57:42 | FromDiscord | <Rika> but they tend to bill per every single factor you can think of |
12:57:55 | FromDiscord | <hmmm> ye like 50$ year are not a problem lol, but if it's an hassle to do it, it is |
12:58:05 | FromDiscord | <Rika> (think money per data uploaded to user) |
12:58:28 | FromDiscord | <Rika> my internet is slow, im downloading a windows iso |
13:08:24 | FromDiscord | <Rika> well idk why do you think heroku is overkill |
13:14:36 | FromDiscord | <hmmm> don't know, I went to the site and seemed like something a small business would use, there is a get started guide and it seems to imply I need to use python/django |
13:14:53 | FromDiscord | <Rika> no you do not |
13:15:02 | FromDiscord | <Rika> many individuals use heroku |
13:15:32 | FromDiscord | <Rika> bare metal servers are even more "something a small business would use" |
13:17:06 | FromDiscord | <Benjamin> By 'bare metal,' do you mean a dedicated server or VPS? |
13:18:26 | FromDiscord | <Rika> perhaps it is the wrong word, i mean unmanaged |
13:22:59 | FromDiscord | <Benjamin> AlphaVPS is the cheapest VPS provider I know if you need a decent amount of space and have low RAM and CPU requirements\: https://alphavps.com/storage-vps.html |
13:24:27 | PMunch | The more I think about this the more I appreciate my server at the university.. |
13:28:20 | FromDiscord | <dom96> Why? VPS' are awesome |
13:31:12 | PMunch | Well what I have is a VPS, but I know the people who run the underlying servers so I can get them to fix things (or get the keys to the castle and fix them myself). And maybe best of all, I don't pay for it :P |
13:32:41 | FromDiscord | <Rika> pay |
13:33:12 | PMunch | Huh? |
13:33:17 | FromDiscord | <Rika> uh |
13:33:21 | FromDiscord | <Rika> my internet fucked itself |
13:33:49 | FromDiscord | <Rika> i was gonna say the pay part but only one of the messages (the correction) seems to have sent |
13:34:19 | PMunch | Hmm, on IRC it just looks like you wrote the word "pay" |
13:34:56 | FromDiscord | <Rika> i know |
13:35:01 | FromDiscord | <Rika> discord didnt send my other message |
13:37:20 | * | rockcavera joined #nim |
13:37:21 | * | rockcavera quit (Changing host) |
13:37:21 | * | rockcavera joined #nim |
13:40:50 | * | ormiret quit (Ping timeout: 260 seconds) |
13:40:51 | * | notchris quit (Read error: Network is unreachable) |
13:40:57 | * | LyndsySimon quit (Read error: Connection reset by peer) |
13:41:01 | * | euantorano quit (Ping timeout: 256 seconds) |
13:42:28 | * | robertmeta_ joined #nim |
13:42:30 | * | robertmeta quit (Ping timeout: 268 seconds) |
13:42:31 | * | robertmeta_ is now known as robertmeta |
13:42:48 | * | LyndsySimon joined #nim |
13:43:03 | * | ormiret joined #nim |
13:43:31 | * | euantorano joined #nim |
13:43:35 | * | notchris joined #nim |
13:43:41 | * | rockcavera quit (Remote host closed the connection) |
13:47:40 | * | rockcavera joined #nim |
13:47:40 | * | rockcavera quit (Changing host) |
13:47:40 | * | rockcavera joined #nim |
13:55:44 | * | arkurious joined #nim |
13:59:04 | * | oddish quit (Quit: nyaa~) |
14:02:45 | NimEventer | New thread by Deech: How do I inject a NimNode directly instead of going through a macro or template?, see https://forum.nim-lang.org/t/8612 |
14:17:25 | * | robertmeta quit (Ping timeout: 250 seconds) |
14:17:32 | * | notchris quit (Ping timeout: 240 seconds) |
14:18:02 | * | euantorano quit (Ping timeout: 240 seconds) |
14:19:09 | * | ormiret quit (Ping timeout: 250 seconds) |
14:19:35 | * | LyndsySimon quit (Ping timeout: 250 seconds) |
14:22:58 | * | euantorano joined #nim |
14:23:21 | * | LyndsySimon joined #nim |
14:23:24 | * | robertmeta joined #nim |
14:23:44 | * | ormiret joined #nim |
14:34:09 | * | notchris joined #nim |
14:35:37 | * | SebastianM joined #nim |
14:38:07 | SebastianM | Hi, is there a way to pass to function variable number of keyword arguments? Like in python **kwargs? |
14:38:57 | * | SebastianM quit (Client Quit) |
14:40:35 | FromDiscord | <dom96> don't think so, you'd need a macro |
14:40:49 | FromDiscord | <dom96> we have `varargs` but no equivalent for kw args. Could be a nice addition |
14:42:04 | PMunch | What does kwargs do differently from varargs? |
14:43:58 | * | SebastianM joined #nim |
14:48:03 | SebastianM | @dom96 Thank you |
14:50:36 | SebastianM | @PMunch I just wanted to fire up function with f(name="Seba", lang="Nim") and get it like varargs |
14:50:55 | PMunch | Aah I see |
14:51:06 | PMunch | No that has to be a macro as dom said |
14:51:17 | PMunch | You might just want to pass it a tuple though.. |
14:51:29 | PMunch | Or you know, name your arguments properly :P |
14:57:48 | SebastianM | @PMunch I'll check the tuple way. Thank you |
14:58:27 | PMunch | Hmm, it won't really do what you want though I think |
14:59:03 | * | pro quit (Quit: WeeChat 3.3) |
15:02:02 | FromDiscord | <dom96> proc f(data: (string, string)) = ...; f({"name": "Seba", "lang": "Nim"}) |
15:02:12 | FromDiscord | <dom96> that's another option since Nim supports this syntax for tuples |
15:06:27 | SebastianM | @dom96 Haven't though about that. Thank you once again |
15:08:40 | * | SebastianM quit (Quit: Bye) |
16:07:29 | * | PMunch quit (Quit: leaving) |
16:17:02 | * | riceman_ joined #nim |
16:17:18 | * | riceman_ quit (Client Quit) |
16:30:18 | * | neurocyte0132889 quit (Quit: The Lounge - https://thelounge.chat) |
16:35:04 | FromDiscord | <reilly> sent a code paste, see https://play.nim-lang.org/#ix=3EHO |
16:36:11 | * | xet7 quit (Remote host closed the connection) |
16:37:09 | * | xet7 joined #nim |
16:38:53 | * | krux02_ joined #nim |
16:40:12 | * | Vladar joined #nim |
16:40:55 | * | krux02__ joined #nim |
16:41:29 | * | krux02 quit (Ping timeout: 264 seconds) |
16:43:27 | * | krux02_ quit (Ping timeout: 250 seconds) |
16:46:29 | * | krux02__ quit (Ping timeout: 250 seconds) |
16:51:00 | * | krux02 joined #nim |
17:02:48 | FromDiscord | <demotomohiro> `rand` proc in your code reads and modify same variable in random module. |
17:06:27 | FromDiscord | <demotomohiro> Create `Rand` with `initRand()` in each thread and use it. |
17:06:51 | FromDiscord | <Rika> they mean that the code compiles but should not |
17:22:32 | FromDiscord | <demotomohiro> Nim forbids threads sharing heap memory, but allows writing a same global variable... |
17:29:19 | Amun-Ra | Pragma mismatch: got '{.locks: 0.}', but expected '{.locks: 0.}'. |
17:29:25 | Amun-Ra | I love these kinds of errors |
17:31:01 | nrds | <Prestige99> Was that the whole error? |
17:32:00 | Amun-Ra | {.gcsafe, locks: 0.} vs {.closure, gcsafe, locks: 0.} |
17:32:10 | * | neurocyte0132889 joined #nim |
17:32:10 | * | neurocyte0132889 quit (Changing host) |
17:32:10 | * | neurocyte0132889 joined #nim |
17:32:19 | nrds | <Prestige99> The erorr is probably about closure |
17:32:31 | nrds | <Prestige99> error* |
17:34:25 | Amun-Ra | yes, I removed raise of ValueError with "not yet implemented" and it worked ;> |
17:46:04 | * | rockcavera quit (Remote host closed the connection) |
18:06:48 | FromDiscord | <dom96> In reply to @reilly "Shouldn't this code be": don't you get a warning for this? |
18:07:19 | FromDiscord | <Rika> i tried it, you dont |
18:11:29 | FromDiscord | <dom96> Oh. You only get the gc safety warnings when itβs a ref |
18:24:50 | FromDiscord | <LilTuxie> why can't I convert a BigInt to int32? I tried it with this and it doesn't work. `int32(BigInt.pow(int32) mod int32)` |
18:25:12 | FromDiscord | <LilTuxie> (replaced variables with their types) |
18:26:37 | FromDiscord | <konsumlamm> it would have to be builtin for that syntax to work |
18:27:02 | FromDiscord | <konsumlamm> and in general, you don't know if it would fit into 32 bits |
18:28:16 | FromDiscord | <LilTuxie> it will because `mod int32` can't be more than 32 bits |
18:28:34 | FromDiscord | <LilTuxie> so is there a way to make it work? |
18:30:10 | FromDiscord | <konsumlamm> apart from the fact that you can't do `x mod int32`, the compiler doesn't know that |
18:31:55 | FromDiscord | <konsumlamm> you could convert it to a string and then parse that, but that's an ugly hack |
18:33:17 | FromDiscord | <LilTuxie> i'd rather not do that. I'll just convert my functions argument from int32 to BigInt |
18:42:37 | Amun-Ra | what would mod int32 even mean? |
18:45:29 | FromDiscord | <konsumlamm> `mod (int32.high.uint32 + 1)` presumably |
18:46:23 | FromDiscord | <konsumlamm> tl;dr seems there is no function to turn a `BigInt` into some standard int, you may wanna open an issue about that |
18:48:02 | * | PMunch joined #nim |
18:49:16 | FromDiscord | <konsumlamm> a conversion could also just cut off the higher bit, so the modulo operation wouldn't even be necessary |
18:58:07 | FromDiscord | <Rika> he said `(replaced variables with their types)` |
18:58:34 | FromDiscord | <Rika> so `int32(<BigInt>.pow(<int32>) mod <int32>)` |
19:27:41 | FromDiscord | <reilly> In reply to @dom96 "Oh. You only get": Shouldn't this still be unsafe though? |
19:30:00 | FromDiscord | <Recruit_main707> its a race condition, its not unsafe perse is it? |
19:35:07 | FromDiscord | <dom96> In reply to @reilly "Shouldn't this still be": Might be worth starting a discussion about it on the forum |
19:36:44 | FromDiscord | <Recruit_main707> what should the warning be, and how easy it would be to implement it |
19:44:25 | FromDiscord | <reilly> Well, I imagine that practically speaking, reading/writing to an integer is fast enough that the likelihood of a race condition is very very low... but not zero. Maybe give us a compiler warning, but let us disable it with a pragma as a way of saying "I understand there is a small risk, now do as I say!" |
19:45:06 | FromDiscord | <Recruit_main707> if its a warning you dont need a flag since it will compile it anyways |
19:45:10 | FromDiscord | <konsumlamm> i think the main problem is not that two writes might happen at exactly the same time |
19:45:31 | FromDiscord | <konsumlamm> but rather that functions use old values of the variables |
19:46:13 | FromDiscord | <konsumlamm> e..g. if you have n threads that all add 1 to some variable (that is initially 0), the end result is not necessarily n |
19:49:11 | FromDiscord | <konsumlamm> "i understand there is a small risk" doesn't sound like you really understand tbh (a bug that only has a small chance of occuring is even worse), the point of such a pragma would be "i'm sure this is safe, eventhough the compiler doesn't know" |
20:03:45 | FromDiscord | <reilly> sent a long message, see http://ix.io/3EJ2 |
20:03:50 | * | kenran joined #nim |
20:22:22 | * | rockcavera joined #nim |
20:22:22 | * | rockcavera quit (Changing host) |
20:22:22 | * | rockcavera joined #nim |
20:38:42 | * | xet7 quit (Remote host closed the connection) |
20:39:29 | * | xet7 joined #nim |
21:09:23 | * | Pyautogui joined #nim |
21:13:54 | * | neurocyte0132889 quit (Ping timeout: 268 seconds) |
21:15:49 | * | Pyautogui quit (Quit: Connection closed) |
21:18:20 | PMunch | Rendering episode 4 of the keyboard firmware series! |
21:19:16 | supakeen | link? |
21:20:11 | nrds | <Prestige99> \o/ |
21:21:46 | PMunch | I mean it's rendering, so it's not uploaded yet, and so no link :P |
21:22:47 | PMunch | It'll be added to this playlist though once it's done: https://www.youtube.com/playlist?list=PL9Yd0XwsGAqwzBkhRNT_H2gsedNcCh4Pw |
21:23:05 | PMunch | But it's going to take about an hour to render. And it's getting late. So I'll probably upload it tomorrow morning |
21:24:11 | FromDiscord | <Elegantbeef> Content with content π |
21:25:26 | PMunch | Ugh, I just looked at the other episodes I've recorded.. Not looking forward to edit nr. 6.. It's almost six and a half hours long, and the first hour I was muted -_- |
21:25:55 | FromDiscord | <Elegantbeef> Ah so you mean only the first hour is watchable |
21:26:12 | FromDiscord | <Elegantbeef> I could not help myself |
21:27:11 | PMunch | Haha :P |
21:27:42 | FromDiscord | <Elegantbeef> You say haha but i can hear the crying from here |
21:28:18 | PMunch | Not at all, people actually seem to prefer my audio to my videos :P |
21:28:49 | FromDiscord | <Elegantbeef> Well the accent is calming, when it's not screaming "viking" |
21:29:27 | FromDiscord | <Elegantbeef> I'm currently taking a break from fighting with framebuffers, so where the hell are all the Nim questions?! |
21:30:49 | PMunch | Accent? Believe me you don't want the Norwegian accent |
21:30:58 | PMunch | Oooh, Nim questions! I know this |
21:31:16 | PMunch | What is the benefit of style insensitivity? |
21:31:42 | PMunch | Since Nim uses C as a backend, does that mean it's a transpiler? |
21:32:04 | PMunch | Can I program Nim with brackets instead of indentation? I don't like whitespace |
21:32:17 | PMunch | Oh, and if I do want to use whitespace, can I use tabs? |
21:32:46 | FromDiscord | <Elegantbeef> Lol |
21:33:01 | PMunch | I really like Nim, just a shame that it uses a GC.. |
21:33:07 | PMunch | Did I miss anything? :P |
21:33:17 | FromDiscord | <Elegantbeef> Oh there's evo π |
21:33:39 | FromDiscord | <evoalg> You called? π Some people use `1..5` and some use `1 .. 5` ... it's just a matter of preference? |
21:34:09 | FromDiscord | <Elegantbeef> Why is my program slower than python? |
21:34:31 | FromDiscord | <evoalg> my question was serious! |
21:34:37 | FromDiscord | <Elegantbeef> i use `a..b` when there is no math, if there is math i do `a .. 1 +5` |
21:34:50 | PMunch | @evoalg, was that actually a question? It's mostly preference, although I think the official styleguide is to use the spaces variant |
21:35:09 | PMunch | `a .. 1 +5`... You psycho |
21:35:18 | FromDiscord | <Elegantbeef> i edited it |
21:35:24 | FromDiscord | <Elegantbeef> `a .. 1 + 5` dumbo |
21:36:06 | PMunch | Haha :P |
21:36:08 | nrds | <Prestige99> I usually wrap mine in parens if anything else is nearby |
21:36:26 | nrds | <Prestige99> but nobody likes the way I do things so :P |
21:36:28 | FromDiscord | <evoalg> thank you ... and some for `1 ..< 5` vs `1..<5` vs `1 .. <5` I guess |
21:36:31 | FromDiscord | <Elegantbeef> Well it's ok to be wrong prestige, just as long as you admit it |
21:36:36 | nrds | <Prestige99> Lol |
21:37:13 | FromDiscord | <Elegantbeef> Yep it's mostly preference but mine is right |
21:37:48 | FromDiscord | <evoalg> I had `a -1` in my and it took me ages to figure out what was wrong (being new to nim) |
21:38:16 | FromDiscord | <Elegantbeef> unary operators! |
21:39:06 | FromDiscord | <evoalg> I didn't understand why the compiler error message was saying I was trying to call a |
21:39:21 | FromDiscord | <evoalg> but in hindsight it obvious |
21:40:16 | PMunch | Haha, yeah the Nim syntax is sometimes so lenient that error messages can be a bit confusing :P |
21:41:30 | FromDiscord | <evoalg> `a -1` in python subtracts 1 ... but yea it's bad practice |
21:42:36 | FromDiscord | <Elegantbeef> Yea it's very ambiguous |
21:43:08 | FromDiscord | <evoalg> Elegantbeef I was looking at your elegant slicterator and I see you cunningly have an iterator call an iterator ... but does that use extra mem? |
21:43:16 | FromDiscord | <Elegantbeef> Nope |
21:43:20 | FromDiscord | <Elegantbeef> Iterators expand at compile time |
21:43:25 | FromDiscord | <Elegantbeef> non closure ones atleast |
21:43:34 | FromDiscord | <evoalg> oh that's soo cool |
21:44:00 | FromDiscord | <evoalg> what is non closure? ... is it meta programing that I'm not up to yet? |
21:44:59 | FromDiscord | <Elegantbeef> closure iterators are iterators that capture their initialization values |
21:45:27 | PMunch | If you need to ask you probably don't need to worry about them |
21:46:54 | FromDiscord | <Elegantbeef> For a shitty example https://play.nim-lang.org/#ix=3EJy |
21:47:01 | FromDiscord | <Elegantbeef> But yea like pmunch said no need to worry |
21:47:25 | FromDiscord | <impbox [ftsf]> closure iterators can capture state and then you can call them at your leisure or pass them around as variables |
21:47:33 | FromDiscord | <impbox [ftsf]> Pretty cool |
21:47:50 | FromDiscord | <impbox [ftsf]> I use them like coroutines |
21:47:51 | PMunch | Fun fact, it's also how async is implemented in Nim |
21:50:35 | FromDiscord | <Elegantbeef> That wasnt too fun, i want a refund |
21:52:20 | PMunch | Well it was free.. |
21:52:42 | FromDiscord | <Elegantbeef> Free things can be good, all the software i use is free! π |
21:52:53 | PMunch | All? |
21:53:31 | * | kenran quit (Quit: WeeChat info:version) |
22:01:16 | FromDiscord | <Elegantbeef> Yep |
22:04:10 | FromDiscord | <dom96> sent a code paste, see https://play.nim-lang.org/#ix=3EJM |
22:07:55 | FromDiscord | <evoalg> I'm confused ... I get subtraction when I do that in python |
22:08:11 | PMunch | I guess it depends on what `a` is defined as |
22:08:27 | FromDiscord | <dom96> yeah, I assigned a function to `a` |
22:08:40 | PMunch | >>> a = 10 |
22:08:40 | * | vicecea quit (Remote host closed the connection) |
22:08:40 | PMunch | >>> a -1 |
22:09:06 | FromDiscord | <evoalg> ah! ... trying to confuse me ... you'll find it's not difficult π |
22:09:12 | * | vicecea joined #nim |
22:11:53 | FromDiscord | <evoalg> ElegantBeef I see with that closure example you gave: https://play.nim-lang.org/#ix=3EJy ... I can't do `echo doThing(5)` or `echo doThing()(5)` ... I have to assign the closure iterator to a variable first? |
22:14:28 | FromDiscord | <Elegantbeef> Yea afaik when you do `var a = doThing` it instantiates the iterator so if you want to do it on one line you'd have to do `echo (var a = doThing; a(5))` |
22:14:39 | FromDiscord | <dom96> heh, PMunch's messages come through as "quotes" on Discord |
22:14:45 | FromDiscord | <Elegantbeef> I dont use closures much so i could be wrong about the semantics there |
22:14:58 | FromDiscord | <Elegantbeef> Well he did quote |
22:15:05 | FromDiscord | <Zoom> You're not |
22:15:13 | PMunch | The messages starting with `>>>` ? |
22:15:14 | FromDiscord | <Elegantbeef> Thanks Zoom |
22:15:20 | FromDiscord | <dom96> PMunch: yeah |
22:15:43 | FromDiscord | <Elegantbeef> yea `>` is the quote in element/discord |
22:15:46 | PMunch | Guess that makes sense, just the bridge trying its best :P |
22:16:30 | FromDiscord | <dom96> I often wonder why closure iterators don't have a clearer way of initialisation |
22:16:44 | FromDiscord | <Zoom> [Elegantbeef](https://matrix.to/#/@elegantbeef:matrix.org)\: any idea on how to add `pairs` to your slierators? |
22:16:54 | FromDiscord | <Elegantbeef> What type of pairs |
22:16:58 | FromDiscord | <Zoom> [Edit](https://discord.com/channels/371759389889003530/371759389889003532/908480390484856892): [Elegantbeef](https://matrix.to/#/@elegantbeef:matrix.org)\: any idea on how to add `pairs` to your slicerators? |
22:17:52 | FromDiscord | <Zoom> immutable and mutable? \:P |
22:18:16 | FromDiscord | <evoalg> gosh Elegantbeef you might have to fix that module name if people are actually going to start using it |
22:18:16 | FromDiscord | <Elegantbeef> Well i can make a macro for mutable pairs |
22:18:34 | FromDiscord | <Elegantbeef> slicerator is probably the better name |
22:18:46 | FromDiscord | <Elegantbeef> sliceterator is too silly |
22:19:09 | FromDiscord | <evoalg> it grows on me after a while π |
22:19:30 | FromDiscord | <Elegantbeef> But i did fix the repo name so it should be fine now |
22:19:49 | FromDiscord | <Elegantbeef> Remember Zoom we cannot do `(int, var T)` but a macro can |
22:19:56 | FromDiscord | <Elegantbeef> So yea i'll throw in some macros for that |
22:20:51 | FromDiscord | <Zoom> Yeah, I figured there's no room for much improvement besides macros. |
22:22:07 | FromDiscord | <evoalg> when I uninstall and install it, it still says "Success: slicterator installed successfully." |
22:22:54 | FromDiscord | <Elegantbeef> Lol |
22:22:56 | FromDiscord | <Zoom> I like and don't like how conservative Nim is with all those suggestion and PRs for iterators and such by Timothee. |
22:23:23 | FromDiscord | <Elegantbeef> I mean iterable is a mess imo |
22:23:28 | FromDiscord | <Elegantbeef> Its a nice idea but poorly implemented |
22:23:58 | FromDiscord | <Zoom> It's something and the scope is limited, so at least not much damage |
22:24:00 | PMunch | Okay, video is finished rendering now, and uploading to YouTube. Should go live once it's ready |
22:24:30 | FromDiscord | <evoalg> I also have to `import slicterator` as `import slicerator` doesn't work ... would my system be caching the old one with the wrong name? |
22:24:55 | FromDiscord | <Elegantbeef> Well sliceterator is the name of the module |
22:25:01 | FromDiscord | <Elegantbeef> Look at the git url and the module in `src` |
22:25:14 | FromDiscord | <Elegantbeef> I will be changing it to slicerator since i prefer that happy accident |
22:25:24 | FromDiscord | <Elegantbeef> But i'm still dicking around with framebuffers |
22:27:15 | PMunch | Now I really have to go to bed.. |
22:27:50 | FromDiscord | <evoalg> I played with `rfind` in slicerator and maybe it should maybe be named `rfindAll` as I think the `re` module has findAll to return all the instances?? |
22:28:23 | FromDiscord | <Elegantbeef> Just dont use regex like a sane person π |
22:28:26 | FromDiscord | <Elegantbeef> I'm kidding of course |
22:33:18 | FromDiscord | <Elegantbeef> The names arent ideal either, so yea will probably change it |
22:35:44 | PMunch | So I should use regex like an insane person? |
22:37:40 | FromDiscord | <evoalg> my Perl days meant I fell in love with regex's |
22:37:54 | FromDiscord | <zentoad> Is there a way to use a C++ class that takes std::vector? |
22:44:12 | PMunch | Video seems to be up now. And I'm off to bed! It's not super interesting unless you're interested in macros, microcontrollers, and/or keyboards though.. |
22:44:13 | PMunch | https://www.youtube.com/watch?v=4lyGYD0C1qQ |
22:44:25 | FromDiscord | <Elegantbeef> Buh bye |
22:44:30 | PMunch | Bye |
22:44:33 | * | PMunch quit (Quit: leaving) |
22:46:26 | * | Vladar quit (Quit: Leaving) |
22:51:12 | FromDiscord | <evoalg> non-closure iterators calling non-closure iterators don't use extra mem, but proc's do right? Each time a proc is called it will assign mem for that proc etc, whereas non-closure iterators are expand inline to the code that called it at compile time ... have I got that right? |
22:52:19 | FromDiscord | <Elegantbeef> Yes |
22:52:29 | FromDiscord | <evoalg> Thank you! |
22:54:04 | FromDiscord | <Elegantbeef> `template` `macro` and non closure `iterator` are expanded at the call site at compile time so you can do 0 cost abstractions there |
22:54:23 | FromDiscord | <Elegantbeef> inb4 "There are no 0 cost abstractions" gang shows up |
22:54:50 | FromDiscord | <tandy> is it possible to make nim bindings for a typescript project? |
22:55:07 | * | stkrdknmibalz joined #nim |
22:55:42 | FromDiscord | <Elegantbeef> There is an (abandoned?) typescript to nim transpiler but nope you cannot just do TS \<-\> Nim since nim doesnt know about TS |
23:00:11 | FromDiscord | <logo> Once PMunch comes back up, I need to talk to him about keyboards lmao. |
23:02:05 | FromDiscord | <PMunch> Did someone say keyboards? |
23:02:58 | FromDiscord | <evoalg> So an iterator is good for low mem and probably some faster code too right? .. but other than that, everything an iterator can do a proc can do?? |
23:03:24 | FromDiscord | <logo> In reply to @PMunch "Did someone say keyboards?": Mechanical keyboard nerd here! |
23:04:00 | FromDiscord | <logo> opens spreadsheet |
23:04:17 | FromDiscord | <logo> https://media.discordapp.net/attachments/371759389889003532/908492359262679070/unknown.png |
23:04:34 | FromDiscord | <logo> Not too much rn |
23:04:40 | FromDiscord | <PMunch> Oh damn! |
23:04:55 | FromDiscord | <logo> Been in the hobby for like two years now? |
23:04:58 | FromDiscord | <tandy> https://github.com/mcclure/dts2nim |
23:05:00 | FromDiscord | <tandy> https://github.com/bung87/ts2nim |
23:05:04 | FromDiscord | <PMunch> Still way more than my single board π |
23:05:07 | FromDiscord | <tandy> i found these |
23:05:09 | FromDiscord | <logo> Ah we should move to #offtopic |
23:07:04 | FromDiscord | <tandy> niceβ΅(@logo) |
23:07:10 | FromDiscord | <tandy> have you guys seen the dactyl generator josh reve is building? |
23:07:11 | FromDiscord | <tandy> https://github.com/joshreve/dactyl-keyboard |
23:07:31 | FromDiscord | <tandy> hmm yesβ΅(@logo) |
23:07:42 | FromDiscord | <Elegantbeef> Using iterators over procs generally reduces the memory foot print and reduces allocations increasing performance |
23:08:10 | FromDiscord | <Elegantbeef> That doesnt hold true 100% but in cases you're slicing to iterate using Nim's built in `[]` slice proc you're going to get better performance from a proper iterator |
23:12:29 | FromDiscord | <evoalg> Thank you! |
23:15:21 | FromDiscord | <Elegantbeef> No problem, finally got my framebuffers to work properly! |
23:22:28 | FromDiscord | <demotomohiro> But inline iterator always inlining code in call site. Isn't that make your code larger than using proc and affect instruction cache? |
23:22:52 | FromDiscord | <Elegantbeef> Oh no larger code, whatever will we do! |
23:25:18 | FromDiscord | <Elegantbeef> Yes it makes the binary larger probably, but given that we're comparing `a[3..5]` duplicating a slice then iterating the children vs just iterating over the elements directly there is no issue |
23:26:31 | FromDiscord | <demotomohiro> I see |
23:31:40 | FromDiscord | <impbox [ftsf]> sent a code paste, see https://play.nim-lang.org/#ix=3EK3 |
23:31:48 | FromDiscord | <impbox [ftsf]> i thought i'd try that block style syntax |
23:32:19 | FromDiscord | <Elegantbeef> Ah you're too good for `import std/[os, strformat, strutils]` i see |
23:33:36 | FromDiscord | <Elegantbeef> You just need commas for that one since that's a single import statement |
23:33:51 | FromDiscord | <Elegantbeef> Oddly it doesnt support newline seperated ones |
23:34:46 | * | rockcavera quit (Remote host closed the connection) |
23:41:46 | * | rockcavera joined #nim |
23:41:46 | * | rockcavera quit (Changing host) |
23:41:46 | * | rockcavera joined #nim |
23:41:47 | FromDiscord | <evoalg> In reply to @Elegantbeef "No problem, finally got": Well done! |
23:44:57 | FromDiscord | <tandy> im gna try use futhark to wrap this https://github.com/TeamAntumbra/libantumbra |
23:50:09 | FromDiscord | <impbox [ftsf]> so a C type has a null terminated array of chars `char szPname[123];` I want to convert this to a nim string, what's the recommended method? |
23:50:56 | FromDiscord | <impbox [ftsf]> using $ on it gives me `[82, 111, 108, 97, 110, 100, 32, 68, 1...` |
23:51:40 | FromDiscord | <Elegantbeef> If you know the length make a new string of that length and copymem, if you dont know the length iterate over it adding each to the string |
23:51:41 | * | mal`` quit (Quit: Leaving) |
23:52:17 | FromDiscord | <Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=3EK4 |
23:52:28 | FromDiscord | <impbox [ftsf]> I know the size of the array, but it's null terminated so it will be shorter |
23:52:56 | FromDiscord | <impbox [ftsf]> i figured i could cast it to a cstring and then $ that, but can't figure out how |
23:53:25 | FromDiscord | <impbox [ftsf]> `Error: expression cannot be cast to cstring` |
23:53:25 | FromDiscord | <Elegantbeef> should just be `cast[cstring](yourCharStr[0].addr)` |
23:53:37 | FromDiscord | <impbox [ftsf]> ` result.add($cast[cstring](caps.szPname))` ahh i was doing this |
23:55:44 | FromDiscord | <Elegantbeef> Did the cast to cstring work? |
23:55:51 | FromDiscord | <impbox [ftsf]> hmm only gives me the first character |
23:56:43 | FromDiscord | <Elegantbeef> Wait is the a reason you dont just wrap it as a cstring? |
23:56:56 | FromDiscord | <impbox [ftsf]> i didn't write the wrapper |
23:57:08 | FromDiscord | <Elegantbeef> Isnt it for all intents and purposes a cstring |
23:57:10 | FromDiscord | <Elegantbeef> Ah |
23:57:26 | FromDiscord | <impbox [ftsf]> windows api shit |
23:57:33 | FromDiscord | <Elegantbeef> perhaps `$cast[ptr cstring](yourCharStr.addr)[]` though that seems odd |
23:58:44 | * | mal`` joined #nim |
23:58:49 | FromDiscord | <impbox [ftsf]> https://play.nim-lang.org/#ix=3EK5 mmm it works here |
23:58:53 | FromDiscord | <impbox [ftsf]> wonder what's different |