<< 13-04-2022 >>

00:21:44*vicfred quit (Quit: Leaving)
00:53:44Amun-Rahmm… I wish nim had flags pragma for enum (sets are suckish in this dept)
00:56:11FromDiscord<Elegantbeef> What do you mean?
00:56:45FromDiscord<Rika> Why?
00:57:32Amun-Rahttps://play.nim-lang.org/#ix=3V0q
00:58:41FromDiscord<Elegantbeef> Eh you can do this with a set and an array of uint32s
01:00:25FromDiscord<Elegantbeef> https://play.nim-lang.org/#ix=3V0r
01:00:26Amun-RaI'd like to use that for high level interop with some library
01:00:39FromDiscord<Rika> That’s the wrong way to use sets and enums I believe
01:01:19Amun-RaI need it to work one way
01:01:27FromDiscord<Elegantbeef> What's the library API?
01:01:41FromDiscord<Rika> look at what beef sent maybe
01:01:41*jmd_ joined #nim
01:01:43*SamuelMarks joined #nim
01:01:45*jmdaemon quit (Ping timeout: 248 seconds)
01:02:28Amun-Raover 20+ #defines that are ored as flags
01:03:00Amun-RaI guess I'll take beef's approach
01:03:04FromDiscord<Rika> uh
01:03:09FromDiscord<Rika> beef why the fuck
01:03:13FromDiscord<Rika> okay
01:03:25FromDiscord<Elegantbeef> Why the fuck?
01:03:50FromDiscord<Rika> so enums in a set, the value of an enum represents the # of bits shifted ex. `1 shl x` where x is the enum value right?
01:03:52FromDiscord<Elegantbeef> You also can lose type safety and do https://play.nim-lang.org/#ix=3V0s
01:03:58FromDiscord<Rika> why bother with the array if you could do that
01:04:11FromDiscord<Rika> beef are you on drugs or something
01:04:32FromDiscord<Elegantbeef> What the fuck are you talking about?
01:04:41FromDiscord<Rika> what the fuck are YOU talking about
01:04:59Amun-Rahmm
01:05:05FromDiscord<Elegantbeef> I'm talking about how to hold on to constant values that are too big for a bitset with enums and still have a bitset
01:08:52FromDiscord<Rika> https://play.nim-lang.org/#ix=3V0u ?
01:09:45*SamuelMarks quit (Ping timeout: 246 seconds)
01:09:46FromDiscord<Elegantbeef> Ah yes that works, but there are some weird flags sometimes that have more than 1 bit
01:09:58FromDiscord<Rika> i assumed there isnt in this case
01:10:06FromDiscord<Rika> if there is, then fuck that library
01:10:08FromDiscord<Rika> xdd
01:10:58FromDiscord<Rika> i wouldnt bother with only enums if there are flags that have more than 1 bit; id use an object at such point
01:18:35FromDiscord<Elegantbeef> Amun here's the start of a 0 cost version if there is bitflag overlap https://play.nim-lang.org/#ix=3V0y
01:18:51Amun-Rahow do you [dis]like that? https://play.nim-lang.org/#ix=3V0A
01:19:00Amun-Rahow much*
01:19:22FromDiscord<Elegantbeef> Hey that's pretty much waht i was doing
01:19:42FromDiscord<Elegantbeef> But i'm doing it with normal set stuff minus the set constructor
01:19:44Amun-Rayes, a variant of that
01:20:21FromDiscord<SirOlaf> Where does parameter resolution happen
01:20:47FromDiscord<Elegantbeef> I think in semoverloadedcall
01:20:55FromDiscord<Elegantbeef> You may want to ask in #internals
01:21:54FromDiscord<SirOlaf> No, think I got some type of idea what's going wrong now
01:24:13*SamuelMarks joined #nim
01:24:55Amun-RaElegantbeef: I think I'll take a varargs approach as the method with the converter has a drawback, non obvious passing Enum to proc taking Flag arg
01:25:57FromDiscord<Elegantbeef> Yea finish adding in the set ops for the type and go to town
01:27:28Amun-Rahmm, I think I've discovered another compiler error ;>
01:27:53FromDiscord<Elegantbeef> Ruh roh
01:28:49Amun-Ranope, that was pebkac
01:29:06FromDiscord<Elegantbeef> Ah only worse to pebcak
01:29:24Amun-Raand picnic ;>
01:29:37FromDiscord<Elegantbeef> Bit too cold for a picnic
01:30:37Amun-Raand a bit too dark (3am here)
01:31:19FromDiscord<SirOlaf> Yeah so after what should be parameter resolution it's still stuck as identifier which is pretty funny
01:31:34FromDiscord<huantian> In reply to @Elegantbeef "also `static FunnyKind`": actually I think I can omit the static because an enum member `is` the enum↵so `fkCow is FunnyKind == true`
01:32:04FromDiscord<SirOlaf> Maybe compiler is getting tricked by the bracket expression
01:34:58FromDiscord<Elegantbeef> What
01:35:10FromDiscord<Elegantbeef> Huan i do not follow
01:35:52FromDiscord<huantian> you said that without static, doing `Kind: FunnyKind` would make the only thing that I could pass to it be `FunnyKind`
01:36:06FromDiscord<Elegantbeef> Yes
01:36:16FromDiscord<huantian> but since enum members are subtypes of the Enum kind, I think the compiler lets me pass them in
01:36:27FromDiscord<Elegantbeef> `Kind: FunnyKind` is a generic constrained to the type `FunnyKind`
01:36:33FromDiscord<Elegantbeef> What the fuck
01:37:07FromDiscord<Elegantbeef> Ok that's weird
01:37:17FromDiscord<Elegantbeef> But there is 0 benefit to that
01:37:21FromDiscord<Elegantbeef> Like you can do anything with that `fkCow` passed in
01:37:33FromDiscord<Elegantbeef> Inside the object it's assumed to be a `FunnyKind`
01:37:37FromDiscord<Elegantbeef> So you have no delimination
01:39:20FromDiscord<huantian> yeah I don't think there's a point to omitting `static` has any point really
01:39:38FromDiscord<huantian> just something funny
01:40:08FromDiscord<Elegantbeef> Well it's cause generic instantiations assume values are supposed to be `typeof`
01:41:02FromDiscord<Elegantbeef> It's an intentional thing i just forgot about since it's a pointless distinction 😛
01:41:10FromDiscord<Elegantbeef> It saves a `typeof` in macros and the like though
01:42:40FromDiscord<huantian> wait typeof?
01:43:18FromDiscord<huantian> oh cus `typeof(FunnyKind)` and `typeof(fkCow)` are the same?
01:43:19FromDiscord<Elegantbeef> `type MyGeneric[T: int] = object` `MyGeneric[100]()` is turned into(internally) `MyGeneric[typeof(100)]()`
01:44:04FromDiscord<huantian> oh huh
01:44:35FromDiscord<Elegantbeef> Huan is learning things they never cared about and still dont care about. 😛
01:44:44FromDiscord<huantian> yep
01:44:46FromDiscord<Elegantbeef> Hows the await PR going
01:45:00FromDiscord<Elegantbeef> Are we going to make async less of a ballache to use?
01:45:05FromDiscord<huantian> should be wrapping up
01:45:21FromDiscord<Elegantbeef> Ah good safe asynchrounous code
01:45:33FromDiscord<huantian> well slightly better errors for async code
01:45:42FromDiscord<huantian> there's still the other fun ones like discarding a Future[void]
01:45:54FromDiscord<Elegantbeef> Dont undersell it, those are quite an improvment
01:46:08FromDiscord<Elegantbeef> "Cannot yield" is fucking unhelpful
01:47:50FromDiscord<huantian> don't think there's anything to add to the pr ↵other than making the error show up on the entire await when that becomes possible
01:48:09FromDiscord<huantian> should I bump with a comment or something
01:49:39FromDiscord<Elegantbeef> Perhaps, also could mention someone
01:53:38FromDiscord<!Patitotective> someone knows how to convert a PXImage into a pixie image? 💀
01:53:41FromDiscord<!Patitotective> (edit) "💀" => "💀↵https://github.com/nim-lang/x11/blob/master/x11/xlib.nim#L200"
01:54:05FromDiscord<SirOlaf> So, prepareOperand(c: PContext; a: PNode) in sigmatch.nim seems to do something weird
01:54:15FromDiscord<SirOlaf> Probably gonna need an adult from here
01:54:30FromDiscord<SirOlaf> It tries considerGenSyms instead of semOperand
01:54:36FromDiscord<huantian> https://play.nim-lang.org/#ix=3V0H↵ideally this error would be better
01:54:50FromDiscord<huantian> because rn it's just completely useless
01:54:59FromDiscord<Elegantbeef> Patito there is a `data` field and format/width/height use that to make a new image
01:56:35FromDiscord<huantian> also the error `expression 'something' has no type (or is ambiguous)` shows up so much
01:56:37FromDiscord<Elegantbeef> I mean this is a nim issue
01:57:15FromDiscord<!Patitotective> In reply to @Elegantbeef "Patito there is a": `XImage.data[0].addr`? where do i use that data?↵i mean, to create a new pixie image
01:57:27FromDiscord<Elegantbeef> You get to learn low level operations
01:57:32FromDiscord<Elegantbeef> I'm not going to walk you through it
01:57:45FromDiscord<SirOlaf> Yep I got the issue
01:57:50FromDiscord<SirOlaf> For PMunch bug
01:57:52FromDiscord<Elegantbeef> Nice!
01:58:01FromDiscord<SirOlaf> Question is just what the fix should be
01:59:18FromDiscord<SirOlaf> So, basically this check seems kinda flawed https://github.com/nim-lang/Nim/blob/devel/compiler/sigmatch.nim#L2311
01:59:25FromDiscord<Elegantbeef> Huantian there is also https://github.com/nim-lang/Nim/issues/19654
02:00:35FromDiscord<SirOlaf> If you, for testing, add ` or a.kind == nkBracketExpr` to the condition I sent it gives you some type of output
02:00:45FromDiscord<SirOlaf> Or rather gives what it should
02:01:20FromDiscord<SirOlaf> So `result = -53.67085806695344 + 0.0 x + 0.0 ln(x) + 35.36216119564057 arctan(x / 223.9725251168868 + 10.85527993806166)` with untyped
02:01:31FromDiscord<huantian> In reply to @Elegantbeef "Huantian there is also": hm maybe I'll add this asnyc thing onto it for now
02:01:56FromDiscord<huantian> I wonder if there's a way to, while processing the proc to make it async,↵check if any Future[void] is getting `discard`ed and raise an error
02:03:12FromDiscord<Elegantbeef> You can of course
02:05:14FromDiscord<SirOlaf> Any idea what the real fix should be
02:07:06FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=3V0J
02:07:32FromDiscord<Elegantbeef> You of course have to have async do that introspection and emitting but yea it should work and would be a nice quality of life for `async` procedures
02:07:55FromDiscord<huantian> wow asyncSingleProc is big
02:09:01FromDiscord<SirOlaf> For some reason a.typ is float so it never gets passed to sem stage
02:11:27*xet7 joined #nim
02:13:53FromDiscord<huantian> wonder if I should put possible improvements to multisync and async errors in the same issue
02:13:58FromDiscord<huantian> pull request I mean
02:16:13FromDiscord<xflywind> better not, it can possibly make merging process slower.
02:17:03*xet7 quit (Quit: Leaving)
02:17:15FromDiscord<Elegantbeef> 1 PR = 1 change 😀
02:17:38*xet7 joined #nim
02:17:41FromDiscord<!Patitotective> sent a long message, see http://ix.io/3V0M
02:17:59FromDiscord<Elegantbeef> it does have `getPixel`
02:18:05FromDiscord<Elegantbeef> Also you can read the format and see what they mean
02:18:37FromDiscord<!Patitotective> the format is `cint`? https://github.com/nim-lang/x11/blob/master/x11/xlib.nim#L217↵.confu
02:18:44FromDiscord<!Patitotective> (edit) "https://github.com/nim-lang/x11/blob/master/x11/xlib.nim#L217↵.confu" => "https://github.com/nim-lang/x11/blob/master/x11/xlib.nim#L217↵😕"
02:18:47FromDiscord<Elegantbeef> no it's not cint
02:18:48FromDiscord<Elegantbeef> RTFM
02:18:57FromDiscord<Elegantbeef> ` int format; / XYBitmap, XYPixmap, ZPixmap /`
02:19:04FromDiscord<Elegantbeef> Ok let's look at what those are
02:20:59FromDiscord<Elegantbeef> It might be best just to use `getPixel` and copy that to pixie
02:22:19FromDiscord<Elegantbeef> So what's the format you get in?
02:23:21FromDiscord<!Patitotective> 2 which should be ZPixmap
02:24:49FromDiscord<Elegantbeef> Yep the data isnt image data
02:24:56FromDiscord<Elegantbeef> So then it's best probably to `getPixel`
02:26:44FromDiscord<Elegantbeef> You also could just operate with `getPixel`
02:27:11FromDiscord<Elegantbeef> So huan you going to work on the discard guards?
02:28:06FromDiscord<!Patitotective> sent a code paste, see https://play.nim-lang.org/#ix=3V0O
02:28:12FromDiscord<Elegantbeef> it's the colour in a single integer
02:28:23FromDiscord<Elegantbeef> each byte represents rgba in 0..255 afaik
02:28:35FromDiscord<Elegantbeef> So bitwise convert it or just make a struct and cast it to that
02:28:47*noeontheend quit (Ping timeout: 240 seconds)
02:30:51FromDiscord<!Patitotective> In reply to @Elegantbeef "So bitwise convert it": bitwise `x11pixel` with what? how's a rgba byte? 😕
02:31:32FromDiscord<Elegantbeef> `let (r, g, b, a) = cast[ptr (byte, byte, byte, byte)](myPixelData.addr)[]`
02:32:33FromDiscord<huantian> sent a code paste, see https://play.nim-lang.org/#ix=3V0Q
02:32:36FromDiscord<huantian> right here <https://github.com/nim-lang/Nim/blob/version-1-6/lib/pure/asyncmacro.nim#L298=>
02:32:46FromDiscord<Elegantbeef> Nice
02:32:49FromDiscord<huantian> with a better message though
02:33:08FromDiscord<Elegantbeef> I dont use async much but it's nice to see someone put the effort in that i'd otherwise put in if i used it 😛
02:33:37FromDiscord<creikey> https://github.com/nim-lang/Nim/issues/19713 ↵I think to fix this I'm gonna have to reinstall windows
02:33:44FromDiscord<creikey> but then I'll never find out why it was broken
02:33:50FromDiscord<Elegantbeef> Nice can install a real OS that doesnt use NT
02:33:59FromDiscord<creikey> I need to use windows
02:34:09FromDiscord<creikey> for a lot of reasons
02:34:19FromDiscord<Elegantbeef> Keep telling yourself that
02:34:30FromDiscord<creikey> I would rather be using linux I used it for years and I'm used to it
02:34:50FromDiscord<creikey> on linux I could probably actually figure this out
02:35:08FromDiscord<creikey> I just don't understand how it could be an issue with dlls like the error code suggests
02:35:17FromDiscord<creikey> gcc from nim threads:on isn't linking to anything
02:35:18FromDiscord<Elegantbeef> Yea i dont know either
02:35:20FromDiscord<creikey> I don't see pthreads included
02:35:25FromDiscord<creikey> like the only difference is some nim threading code
02:35:32FromDiscord<Elegantbeef> Have you tried with msvc?
02:35:39FromDiscord<Elegantbeef> or `vcc` i guess
02:35:42FromDiscord<creikey> no I'm not sure where to even start with that
02:35:46FromDiscord<creikey> but I'll try that now I guess
02:35:52FromDiscord<Elegantbeef> typially you download visual studio
02:35:52FromDiscord<creikey> msvc I would anticipate to have a bunch of other issues
02:35:56FromDiscord<creikey> no I have msvc
02:35:56FromDiscord<Elegantbeef> then you select it's C compiler
02:35:57FromDiscord<creikey> and vcvars
02:36:04FromDiscord<creikey> I just don't know its flags
02:36:04FromDiscord<Elegantbeef> then you do `nim c --cc:vcc`
02:36:40FromDiscord<creikey> In reply to @Elegantbeef "then you do `nim": is this just what msvc is called? the compiler isn't called vcc.exe
02:37:31FromDiscord<creikey> https://media.discordapp.net/attachments/371759389889003532/963628973261226044/image.png
02:37:31FromDiscord<creikey> In reply to @Elegantbeef "then you do `nim": huh
02:37:32FromDiscord<creikey> msvc
02:37:33FromDiscord<creikey> works
02:37:33FromDiscord<Elegantbeef> It's what they call their C++ compiler i think and is why the name is used
02:37:35FromDiscord<Elegantbeef> I could be wrong
02:37:36FromDiscord<creikey> no issues
02:37:49FromDiscord<creikey> https://media.discordapp.net/attachments/371759389889003532/963629048846749758/image.png
02:37:53FromDiscord<Elegantbeef> Can you send the code again?
02:37:59FromDiscord<!Patitotective> beef, it stills outputs an empty image...↵https://play.nim-lang.org/#ix=3V0S 😕
02:38:14FromDiscord<Elegantbeef> Why the fuck are you using floats
02:38:15FromDiscord<creikey> that is actually really helpful
02:38:18FromDiscord<creikey> thanks beef
02:38:24FromDiscord<creikey> it's something with the mingw install
02:38:31FromDiscord<creikey> In reply to @Elegantbeef "Can you send the": `echo "hello"`
02:38:43FromDiscord<Elegantbeef> ah it's that simple
02:38:47FromDiscord<creikey> yeah
02:38:49FromDiscord<creikey> just compile anything
02:38:53FromDiscord<creikey> with the shipped nim compiler
02:39:10FromDiscord<Elegantbeef> Yea it works here
02:39:11FromDiscord<creikey> I feel like it has to be something with `gcc.exe` shipped with nim linking to libraries not built with the mingw version it's shipping with
02:39:18FromDiscord<creikey> because I know I have like 3 mingws installed on my computer
02:39:19FromDiscord<Elegantbeef> With mingw i should add
02:39:30FromDiscord<!Patitotective> In reply to @Elegantbeef "Why the fuck are": cause pixie's pixels are https://nimdocs.com/treeform/chroma/chroma/colortypes.html#Color (?)
02:39:38FromDiscord<Elegantbeef> Yes but cast doesnt convert
02:39:50FromDiscord<creikey> In reply to @creikey "I feel like it": now how to start with this
02:39:52*xet7 quit (Remote host closed the connection)
02:39:52FromDiscord<creikey> there's only one gcc.exe
02:39:53FromDiscord<Elegantbeef> the data is stored as bytes
02:39:57FromDiscord<Elegantbeef> or uint8s
02:40:12FromDiscord<Elegantbeef> you casting to a float means the first value is all of the data
02:40:18FromDiscord<Elegantbeef> the rest is noise of the stack
02:41:06FromDiscord<!Patitotective> using bytes it says `Error: type mismatch: got 'byte' for '436207668[0]' but expected 'float32'`
02:41:15FromDiscord<!Patitotective> (edit) "using bytes it says `Error: type mismatch: got 'byte' for '436207668[0]' but expected 'float32'` ... " added "😕"
02:41:18FromDiscord<Elegantbeef> yes cause you're assigning to a float
02:41:23FromDiscord<Elegantbeef> you cant just cast to make datas convert
02:41:46FromDiscord<Elegantbeef> you then have to do `myPixel = color(r.float32,g.float32,b.float32,a.float32)`
02:41:58*xet7 joined #nim
02:42:10FromDiscord<Elegantbeef> A uint8 is 1/4 the size of a float32 casting doesnt do anything but wrong
02:42:16FromDiscord<Elegantbeef> I chose the type explicitly
02:42:57FromDiscord<creikey> In reply to @Elegantbeef "A uint8 is 1/4": just kinda curious what does `0.uint8.float` actually do
02:43:08FromDiscord<creikey> like is there an x86 instruction for converting the one byte of data to a float
02:43:20FromDiscord<creikey> (edit) "`0.uint8.float`" => "`1.uint8.float`"
02:43:21FromDiscord<Elegantbeef> I dont know i doubt it
02:43:39FromDiscord<creikey> https://media.discordapp.net/attachments/371759389889003532/963630520669982851/image.png
02:43:42FromDiscord<Elegantbeef> Given they're primitives the C or Nim compiler probably optimizes it away
02:43:44FromDiscord<creikey> so like gcc is using the built in toolchain right
02:43:54FromDiscord<Elegantbeef> Seems so
02:44:01FromDiscord<creikey> I don't remember where my other mingws are
02:44:11FromDiscord<creikey> oh chocolatey
02:44:15FromDiscord<creikey> I think one is chocolatey
02:44:21FromDiscord<creikey> and another is the other linux on windows toolchain stuff
02:44:53FromDiscord<Elegantbeef> And there is a non-zero chance patito that it's actually `(a, b, g, r)` but i dont know
02:45:00FromDiscord<Rika> Cursed
02:45:02FromDiscord<yoyojambo> is there a prettier way to iterate over a 2d array than nested for loops?
02:45:13FromDiscord<Elegantbeef> Make your own iterator
02:45:17FromDiscord<Rika> In reply to @yoyojambo "is there a prettier": Nested map?
02:45:18FromDiscord<Rika> Or that
02:45:23FromDiscord<Rika> What does prettier mean to you
02:46:08FromDiscord<yoyojambo> In reply to @Rika "What does prettier mean": I guess in a single line
02:46:12FromDiscord<yoyojambo> In reply to @Elegantbeef "Make your own iterator": good idea
02:46:24FromDiscord<Elegantbeef> Iterators are the god's nectar
02:46:35*rockcavera joined #nim
02:46:35*rockcavera quit (Changing host)
02:46:35*rockcavera joined #nim
02:46:36FromDiscord<huantian> hm one day i'll figure out what `owned` does, looks like it has something to do with old newruntime? I have no idea what newruntime is so idk
02:46:48FromDiscord<Elegantbeef> New runtime is orc/arc
02:46:53FromDiscord<Rika> Afaik it doesn’t do anything in effect anymore?
02:47:00FromDiscord<Rika> Or was that something else
02:47:05FromDiscord<Elegantbeef> I dont think it does anything anymore
02:47:08FromDiscord<Elegantbeef> It's not in the manual
02:47:28FromDiscord<Rika> Insert question about <//> here
02:47:33FromDiscord<!Patitotective> sent a code paste, see https://paste.rs/giP
02:48:12FromDiscord<Elegantbeef> Guess i was relying on UB like a silly person
02:49:03FromDiscord<!Patitotective> (same happens with `color(r.float32,g.float32,b.float32,a.float32)`)
02:49:14FromDiscord<!Patitotective> (edit) "`color(r.float32,g.float32,b.float32,a.float32)`)" => "`pixel = color(r.float32,g.float32,b.float32,a.float32)`)"
02:49:25FromDiscord<Elegantbeef> Oh it's assignment
02:49:28FromDiscord<Elegantbeef> Just make a new colour
02:49:37*arkurious quit (Quit: Leaving)
02:49:47FromDiscord<Elegantbeef> What you're doing wont work anyway
02:49:59FromDiscord<Elegantbeef> image.setColor(x, y, myColor)\`
02:51:10*xet7 quit (Remote host closed the connection)
02:51:48FromDiscord<!Patitotective> seems like the error is actually here `let (r, g, b, a) = cast[ptr (byte, byte, byte, byte)](x11pixel.addr)[]`
02:51:58FromDiscord<!Patitotective> In reply to @Elegantbeef "image.setColor(x, y, myColor)\`": `image.setColor(x, y, color(r.float32, g.float32, b.float32, a.float32))`?
02:52:02FromDiscord<!Patitotective> (edit) "a.float32))`?" => "a.float32))`, righ?"
02:52:06FromDiscord<!Patitotective> (edit) "righ?" => "right?"
02:52:10FromDiscord<Elegantbeef> No clue i'm not the one using pixie
02:52:32FromDiscord<!Patitotective> In reply to @Patitotective "seems like the error": this is not pixie 🤷‍♂️
02:52:36FromDiscord<Elegantbeef> Pixie might even have a api for a colour from bytes
02:52:44FromDiscord<Elegantbeef> .. i know i'm not stupid
02:52:52FromDiscord<Elegantbeef> Time to get the old bitwise ops out then
02:52:54FromDiscord<Elegantbeef> Have fun with that
02:52:58FromDiscord<!Patitotective> In reply to @Elegantbeef "Pixie might even have": let me read the ~~fucking~~ manual
02:53:30FromDiscord<Elegantbeef> I still could be wrong about the colour data
02:53:53FromDiscord<Elegantbeef> I've never used xlib's XImage so i'm just assuming xgetPixel returns that data and not something else
02:54:44FromDiscord<!Patitotective> In reply to @Elegantbeef "Pixie might even have": (pixie or chroma? cause github cannot even find the word byte in chroma's code lol)
02:55:29*xet7 joined #nim
02:55:31FromDiscord<!Patitotective> In reply to @Elegantbeef "I've never used xlib's": > _The XGetPixel function returns the specified pixel from the named image. The pixel value is returned in normalized format (that is, the least significant byte of the long is the least significant byte of the pixel). The image must contain the x and y coordinates. _
02:55:55FromDiscord<Elegantbeef> It might also be a uint8
02:56:12FromDiscord<!Patitotective> isnt byte == uint8? or wdym
02:56:33FromDiscord<Elegantbeef> I mean the used name might be uint8 not byte
02:56:42FromDiscord<Elegantbeef> https://github.com/treeform/chroma/blob/640f26142f47fea023a87bfd684a3fa770a785ae/src/chroma/colortypes.nim#L126-L140
03:02:45FromDiscord<huantian> wow this is going to be fun how do I detect if a NimNode returns a Future[void]
03:03:09FromDiscord<Elegantbeef> It needs to be typed so you cannot in the async macro
03:03:29FromDiscord<Elegantbeef> You have to emit a when statement like i showed
03:04:04FromDiscord<huantian> ah so do that for all things that are `dicarod await ...`
03:04:17FromDiscord<Elegantbeef> Yep
03:04:24FromDiscord<Elegantbeef> Like i said though this doesnt make anysense
03:04:33FromDiscord<Elegantbeef> You are not supposed to `discard await` anyway
03:04:37FromDiscord<Elegantbeef> So you might aswell just emit an error
03:04:41FromDiscord<Elegantbeef> "use async check"
03:05:07FromDiscord<huantian> you have to use `asyncCheck` even in an async proc?
03:05:34FromDiscord<Elegantbeef> image.png https://media.discordapp.net/attachments/371759389889003532/963636030710358026/image.png
03:06:23FromDiscord<Elegantbeef> Any code that does `discard await` is doing so cause the library didnt prevent it
03:06:50FromDiscord<huantian> but waitFor would be blocking, it wouldn't pass up execution to the loop
03:06:52FromDiscord<Elegantbeef> I'm sure araq will say "Cannot do that as it changes past behaviour" but I've been wrong before
03:07:00FromDiscord<Elegantbeef> Did you read the entire thing?
03:07:26FromDiscord<Elegantbeef> If you want to block you use `waitFor` if you want to await it you do `asyncCheck` you do not `discard` it
03:07:43FromDiscord<Elegantbeef> `asyncCheck` is the proper way to `discard` a `Future`
03:08:00FromDiscord<Elegantbeef> The only reason you can discard it inside an `async` is cause no one introduced an error
03:09:06FromDiscord<huantian> if you do `discard await` you aren't discarding the Future though, you're waiting on it, then when you get the result, you discard that
03:09:11FromDiscord<huantian> (edit) "if you do `discard await` you aren't discarding the Future though, you're waiting on it, then when you get the ... result," added "non-future"
03:09:20FromDiscord<Elegantbeef> no you are discarding it
03:09:31FromDiscord<Elegantbeef> `discard await` is wrong
03:09:36FromDiscord<Elegantbeef> The docs say as much
03:09:36FromDiscord<huantian> hmm ok
03:10:01FromDiscord<Elegantbeef> If i'm wrong fix the docs, if i'm right fix the macro
03:10:27FromDiscord<huantian> https://github.com/nim-lang/Nim/issues/5021
03:10:28FromDiscord<huantian> hm ok
03:10:55FromDiscord<huantian> maybe I should update the docs then :P
03:11:16FromDiscord<!Patitotective> Omg almost↵@ElegantBeef thank you beeeeeeeeeeeeeeeeeeeeeeeeeeeef 🙃 https://media.discordapp.net/attachments/371759389889003532/963637467280474122/screenshot_2022-04-12_22_10_39.png
03:11:45FromDiscord<Elegantbeef> Like i said it might be `abgr` not `rgba`
03:16:38FromDiscord<!Patitotective> In reply to @Elegantbeef "Like i said it": no, its not https://media.discordapp.net/attachments/371759389889003532/963638815153610812/screenshot_2022-04-12_22_16_05.png
03:17:13*Gustavo6046 quit (Ping timeout: 248 seconds)
03:17:19FromDiscord<Elegantbeef> well screenshot a blue screen, a red screen, and a greenscreen and then look at the reported values
03:17:44FromDiscord<!Patitotective> it was `bgra` lol
03:17:53FromDiscord<!Patitotective> thanks beef 🙃
03:18:02*Gustavo6046 joined #nim
03:18:08*dropkick joined #nim
03:18:09FromDiscord<ynfle> Wrong endian?
03:20:34termeris there a way to upload arbitrary data with AsyncHttpClient as a file?
03:20:56termerI'm looking at AsyncHttpClient.add and I'm seeing no way to do that
03:35:52*SamuelMarks quit (Ping timeout: 248 seconds)
03:59:07FromDiscord<!Patitotective> fast enough screenshots? `[1s 880ms 620μs 893.91ns] ± [51ms 634μs 648.92ns] per loop (mean ± std. dev. of 7 runs, 1 loops each)`
04:02:42*SamuelMarks joined #nim
04:04:02FromDiscord<Elegantbeef> Is that release?
04:04:20FromDiscord<!Patitotective> ... one sec
04:05:34FromDiscord<!Patitotective> `[159ms 121μs 300.57ns] ± [1ms 914μs 66.91ns] per loop (mean ± std. dev. of 7 runs, 1 loops each)`
04:05:38FromDiscord<!Patitotective> much faser
04:05:39FromDiscord<!Patitotective> (edit) "faser" => "faster"
04:05:56FromDiscord<Elegantbeef> Only way to be faster is if you didnt need to convert it 😛
04:07:08FromDiscord<!Patitotective> anyways as linerino can stay still forever there's no speed limitation (i think)
04:07:12*SamuelMarks quit (Ping timeout: 246 seconds)
04:07:23FromDiscord<huantian> the speed limitation is your patience
04:07:43FromDiscord<Elegantbeef> I mean you only need a single image to solve it
04:07:49FromDiscord<huantian> true lmao
04:08:02FromDiscord<huantian> can't wait for non-deterministic linerino
04:08:21FromDiscord<Elegantbeef> Lol fighting cmake so going to be waiting a while
04:09:21FromDiscord<!Patitotective> In reply to @Elegantbeef "I mean you only": then why am i making this? 🥲
04:09:33FromDiscord<Elegantbeef> No clue
04:09:51FromDiscord<!Patitotective> lmao
04:11:52*vicfred joined #nim
04:17:17*dropkick quit (Remote host closed the connection)
04:19:14FromDiscord<aph> sent a code paste, see https://play.nim-lang.org/#ix=3V15
04:19:36FromDiscord<aph> i was trying to turn `test` to `BoneNil` with some inheritance magic, it doesn't work as i expected
04:19:38FromDiscord<Elegantbeef> `new BoneNil`
04:19:43FromDiscord<aph> In reply to @Elegantbeef "`new BoneNil`": ahh
04:20:31FromDiscord<aph> it seems like i done something wrong in the inheritance thing `but expected 'InheritBone = ref InheritBone:ObjectType'`
04:20:46FromDiscord<huantian> hm shouldn't `BoneType = ref object of RootObj` and so on
04:21:19FromDiscord<aph> In reply to @huantian "hm shouldn't `BoneType* =": not sure, i thought `object` must have fields, brb lemme check thx
04:21:24FromDiscord<aph> (edit) "ahh" => "ahh, ty"
04:21:49FromDiscord<Elegantbeef> objects dont have to have fields
04:22:16FromDiscord<aph> whoopsi
04:22:23FromDiscord<!Patitotective> hey beeef, could you tell me whats linerino's window default size? hehe
04:23:00FromDiscord<Elegantbeef> You mean how many pixels does the screen "have"
04:23:05*slowButPresent quit (Quit: leaving)
04:23:07FromDiscord<!Patitotective> In reply to @Elegantbeef "You mean how many": i guess
04:23:15FromDiscord<Elegantbeef> It's 128x128
04:23:25FromDiscord<!Patitotective> thanks 🙃
04:26:12FromDiscord<!Patitotective> ~~if i run linerino it blocks the program so it can't take the screenshot 💀 ~~
04:27:57FromDiscord<huantian> beef has anticheat!
04:28:11FromDiscord<!Patitotective> In reply to @huantian "beef has anticheat!": he's just playing with me 💀
04:28:55FromDiscord<!Patitotective> anyways, its time to sleep↵gn https://media.discordapp.net/attachments/371759389889003532/963657008274350150/Screenshot_from_2022-04-12_23-28-21.png
04:28:57FromDiscord<!Patitotective> 🌃
04:35:09*SamuelMarks joined #nim
04:41:27*SamuelMarks quit (Ping timeout: 256 seconds)
04:44:26*vicfred quit (Quit: Leaving)
04:47:53*yoyojambo joined #nim
04:49:24*yiggityswaps quit (Ping timeout: 240 seconds)
05:32:14*kenran joined #nim
05:35:59*rockcavera quit (Remote host closed the connection)
05:52:21FromDiscord<morgan> is there any reason why i should get this warning `Error: undeclared identifier: 'result'`?
05:52:30FromDiscord<morgan> that's the only instance of result in that proc
05:52:42FromDiscord<Elegantbeef> entire code
05:53:04FromDiscord<morgan> sent a code paste, see https://paste.rs/yNN
05:53:11FromDiscord<Elegantbeef> No return type
05:53:29FromDiscord<morgan> oohhh thanks
05:54:46FromDiscord<Elegantbeef> Do i mention now that your callback could just be a `pointer`?
05:54:47FromDiscord<Elegantbeef> then on invoking you cast to the type based off your flag descrim
06:04:48*zeus-supreme1 joined #nim
06:07:52*zeus-supreme quit (Ping timeout: 248 seconds)
06:18:27FromDiscord<Rika> In reply to @Elegantbeef "`discard await` is wrong": Futures shouldn’t be discarded. Await doesn’t return a future
06:20:59FromDiscord<Rika> Discard await is fine and you misinterpret the docs
06:34:40*Gustavo6046 quit (Quit: Goodbye! Leave messages at my XMPP @ [email protected] or my Discord Gustavo6046#9009 or possibly my Mastodon [email protected] – I don't check my email often since it's full of crap, but in any case, [email protected])
06:52:30*neurocyte8614492 joined #nim
07:04:30*SamuelMarks joined #nim
07:08:16*ltriant quit (Ping timeout: 250 seconds)
07:08:52*ltriant joined #nim
07:09:34*SamuelMarks quit (Ping timeout: 250 seconds)
07:31:15*PMunch joined #nim
07:40:00*ltriant quit (Ping timeout: 246 seconds)
08:08:07*ltriant joined #nim
08:13:57*jmd_ quit (Ping timeout: 246 seconds)
08:52:08*yoyojambo quit (Ping timeout: 248 seconds)
09:11:11*yoyojambo joined #nim
09:37:07FromDiscord<Elegantbeef> Ah then yea i'm dumb, and it should be a check for `discard await someProc()` that ensures `someProc() isnot Future[void]` though really the compiler should just be better
09:45:23FromDiscord<Rika> Doesn’t it already catch if you discard something that gives a void
09:45:33FromDiscord<Rika> Or is the error just opaque is what you mean
09:45:35FromDiscord<Tanguy> Or a `.nondiscardable.` and a `forcediscard`
09:46:50FromDiscord<Rika> You can’t discard void in the first place though so
09:50:33FromDiscord<tandy> how do i add a project to this month with nim?
09:50:51FromDiscord<tandy> [Elegantbeef](https://matrix.to/#/@elegantbeef:matrix.org)\: arent you involved ?
09:52:37FromDiscord<Rika> You pretty much request it
09:54:13FromDiscord<tandy> pull request?
09:54:18FromDiscord<tandy> or issue
09:55:01FromDiscord<Rika> Dunno ngl
09:55:42FromDiscord<tandy> organisation
09:56:10FromDiscord<tandy> https://github.com/beef331/website#adding-your-project-to-month-with-nim
09:56:12FromDiscord<tandy> found this
09:56:36PMunch@tandy, yes
09:56:43PMunchYou basically just make an issue here: https://github.com/beef331/website/issues?q=is%3Aissue+is%3Aclosed
09:57:31*PMunch quit (Quit: Leaving)
10:02:35FromDiscord<tandy> done
10:13:53*SamuelMarks joined #nim
10:19:11*SamuelMarks quit (Ping timeout: 256 seconds)
10:35:15FromDiscord<jmgomez> sent a code paste, see https://paste.rs/AYX
10:44:50FromDiscord<Solitude> 2 is less awkward, especially in method call chains.
10:50:16FromDiscord<Rika> Dunno, depends on you
10:50:19FromDiscord<Rika> I think either is fine
10:50:39FromDiscord<Rika> 1 doesn’t have much an issue for method call chains
10:55:52FromDiscord<jmgomez> Okay, never saw something like typedesc in other langs. Is there a good explanation out there on how it works?
11:05:34FromDiscord<Rika> It’s a “type descriptor”
11:22:24FromDiscord<jmgomez> do you know a good article/entry on the docs for it?
11:22:41FromDiscord<jmgomez> or maybe source code to look at
11:23:59FromDiscord<demotomohiro> https://nim-lang.org/docs/manual.html#special-types-typedesc-t
11:47:55FromDiscord<jmgomez> the concept of types as values is pretty powerful, have to dig in yet into templates and macros
11:48:42FromDiscord<Rika> Yeah I don’t know why all these other language stopped at functions as values
11:49:16FromDiscord<Rika> Why not types as well? And why not everything for that matter
12:02:20*SamuelMarks joined #nim
12:07:20*SamuelMarks quit (Ping timeout: 248 seconds)
12:18:02*noeontheend joined #nim
12:28:28FromDiscord<sOkam!> I'm translating some Ansi C code with c2nim↵It's giving me a lot of `cint`, `cchar` and all those other `c` variable types↵I understand that those are aliases for `{.importc}` variables, so hence my Q:↵- Do I need to care about `c` variables at all, if I won't be interfacing with C with the resulting code?
12:31:10FromDiscord<sOkam!> The goal is to convert that Ansi C project into pure Nim↵But I don't know if I should take the extra time to change the variable types, or if I can just leave them as they are and not worry about it too much 🤔
12:31:46FromDiscord<Rika> If you change the types, your behaviour may change as well
12:31:57FromDiscord<Rika> If you understand well enough what happens then feel free to change them
12:32:08FromDiscord<Rika> I’d recommend writing tests before that though
12:32:10FromDiscord<sOkam!> I'm surely don't 🙈
12:32:19FromDiscord<sOkam!> (edit) "I'm" => "I"
12:32:29FromDiscord<sOkam!> Will leave them as `c` then
12:34:14FromDiscord<sOkam!> It is also converting `void` functions into typeless `proc`s.↵Should I manually add void at the end, or are nim procs void by default?
12:34:45FromDiscord<Rika> Void by default
12:35:09*zeus-supreme joined #nim
12:38:07*zeus-supreme1 quit (Ping timeout: 240 seconds)
12:42:15*rockcavera joined #nim
12:42:15*rockcavera quit (Changing host)
12:42:15*rockcavera joined #nim
12:57:22*xet7 quit (Remote host closed the connection)
12:59:54*xet7 joined #nim
13:09:29*SamuelMarks joined #nim
13:20:04*noeontheend quit (Ping timeout: 250 seconds)
13:34:55*jjido joined #nim
13:43:11*SamuelMarks quit (Ping timeout: 256 seconds)
13:49:13FromDiscord<konsumlamm> In reply to @Rika "Why not types as": because types only exist at compile time, usually (and you can't really use `typedesc` for runtime types either)↵althoufh dependent types exist, which somewhat give you that
13:49:50FromDiscord<sOkam!> are double pointers allowed in nim?↵also, where can I read about how they work in the language? 🤔
13:51:49FromDiscord<sOkam!> (edit) "they" => "pointers"
13:54:41FromDiscord<Rika> In reply to @konsumlamm "because types only exist": I wasn’t asking asking
13:54:57FromDiscord<Rika> In reply to @sOkam! "are double pointers allowed": Sure
13:55:20*arkurious joined #nim
13:55:52FromDiscord<Yardanico> In reply to @sOkam! "are double pointers allowed": = ptr, void = pointer, & = addr
13:56:17FromDiscord<Yardanico> for dereferencing you use `[]`
13:56:58*xet7 quit (Remote host closed the connection)
14:03:45FromDiscord<Yardanico> https://nim-lang.org/docs/manual.html#types-reference-and-pointer-types
14:08:35FromDiscord<sOkam!> In reply to @Yardanico "https://nim-lang.org/docs/manual.html#types-referen": ty! 🙂
14:13:34*rockcavera quit (Remote host closed the connection)
14:26:49FromDiscord<sOkam!> sent a code paste, see https://play.nim-lang.org/#ix=3V2x
14:27:12FromDiscord<sOkam!> (edit) "https://play.nim-lang.org/#ix=3V2x" => "https://paste.rs/j7U"
14:29:34nrds<Prestige99> Is there a way to statically compile c dependencies into a nim library? E.g. I'm using SDL for my game engine, and would like to compile a game to a single binary
14:34:35FromDiscord<Jakraes> So far what's the best sdl2 wrapper for nim? sdl2 or sdl2_nim?
14:35:20nrds<Prestige99> sdl2_nim I believe, it's what I'm using at least
14:41:26FromDiscord<Jakraes> I'll try that out then, thank you
14:42:36nrds<Prestige99> This may be of use https://github.com/avahe-kellenberger/shade/blob/master/src/shadepkg/game/game.nim
14:43:51NimEventerNew Nimble package! useradd - Linux adduser/useradd library with all batteries included., see https://github.com/theAkito/nim-useradd
14:44:47FromDiscord<hmmm> lol nim programmers have the freshest avatars 😃
14:45:51FromDiscord<Jakraes> In reply to @nrds "<Prestige> This may be": I'll also try that out, also, is it normal to have "Could not load SDL2_xyz.dll" errors? I'm having this with SDL2-image.dll
14:47:36nrds<Prestige99> Yeah you need to have the dll files in your PATH I think on windows (I'm on linux and use LD_LIBRARY_PATH, not very familiar with windows)
14:47:54FromDiscord<Solitude> In reply to @Jakraes "I'll also try that": you sure its a 64bit dll?
14:49:00nrds<Prestige99> Yeah looks like on windows you need the dll files to be in a directory that's in your PATH environment variable
14:50:12nrds<Prestige99> I'm actually trying to figure out how to statically compile for that reason
14:50:56FromDiscord<Jakraes> In reply to @Solitude "you sure its a": Yeah it's 64bit, so I'm not sure why it's not working
14:51:04FromDiscord<Jakraes> Already added it to the path
14:51:09FromDiscord<Jakraes> Doesn't work :/
14:51:16nrds<Prestige99> Is it the right name?
14:51:24FromDiscord<Jakraes> Yup
14:51:50nrds<Prestige99> Can you provide all the info? Error message, path it's in, name etc
14:51:55nrds<Prestige99> Sounds like it should be working
14:53:09FromDiscord<Jakraes> This is the error https://media.discordapp.net/attachments/371759389889003532/963814099278495825/Screenshot_1.png
14:53:30FromDiscord<Jakraes> Like, SDL2 itself is working because when I run the first example from sdl2_nim, it works perfectly
14:55:06FromDiscord<Jakraes> And the sdl2.dll file is in my nim directory https://media.discordapp.net/attachments/371759389889003532/963814589785604176/Screenshot_2.png
14:55:11FromDiscord<Yardanico> you need SDL2_image.dll as well
14:55:18FromDiscord<Yardanico> it's an extension of SDL so it's a separate library
14:55:19FromDiscord<Jakraes> Oh, it's not included in sdl2?
14:55:21nrds<Prestige99> ^ it's a different dll
14:55:24FromDiscord<Jakraes> Gotcha
14:55:26FromDiscord<Yardanico> well, it says right in the error that it's a different dll
14:59:07*SamuelMarks joined #nim
14:59:23FromDiscord<konsumlamm> In reply to @sOkam! "Is there any difference": no
14:59:51FromDiscord<Yardanico> In reply to @sOkam! "Is there any difference": `;` is only useful in a couple of cases
14:59:59FromDiscord<Yardanico> with `using` and with generics
15:00:38FromDiscord<Yardanico> https://nim-lang.org/docs/manual.html#procedures
15:01:44FromDiscord<Recruit_main707> i use it bc why not, but yeah, not needed
15:02:12*slowButPresent joined #nim
15:03:07FromDiscord<sOkam!> I see. Yeah, the question comes because c2nim is converting all `,` into `;`, so wondered why 🤷‍♂️
15:04:04FromDiscord<Yardanico> because Аraq prefers `;` :)
15:04:23FromDiscord<Yardanico> and it's generally just a little better so you won't have weird errors in some rare cases
15:04:29FromDiscord<sOkam!> makes senses 🙂
15:04:52FromDiscord<Recruit_main707> In reply to @Yardanico "because Аraq prefers `;`": Araq based
15:12:34FromDiscord<Solitude> https://github.com/nim-lang/Nim/pull/19711 beef, what the hell
15:13:31FromDiscord<sOkam!> c2nim its doing this thing where its automatically naming arguments for things↵are unnamed arguments disallowed in nim, but allowed in AnsiC? Or am I missing something else? 🤔 https://media.discordapp.net/attachments/371759389889003532/963819225917558884/unknown.png
15:15:01FromDiscord<Yardanico> those at the top are C forward declarations, but yes, in Nim arguments should always be named
15:15:05FromDiscord<Yardanico> even in forward declarations, unlike C
15:17:02FromDiscord<Solitude> !eval proc t(_: int) = discard
15:17:04NimBot<no output>
15:17:10FromDiscord<Solitude> amazing
15:17:19FromDiscord<Yardanico> but `_` isn't empty
15:17:31FromDiscord<Solitude> funny, that the only place _ is mentioned in manual is tuple unpacking
15:17:44FromDiscord<Yardanico> yes
15:17:50FromDiscord<Solitude> even tho it can be used everywhere
15:17:56FromDiscord<Yardanico> sent a code paste, see https://paste.rs/voc
15:18:07FromDiscord<sOkam!> In reply to @Yardanico "even in forward declarations,": is there any doc about forward declarations? google not being very helpful on this one 😔
15:18:13FromDiscord<Yardanico> for C or Nim?
15:18:16FromDiscord<sOkam!> nim
15:18:21FromDiscord<sOkam!> (edit) "In reply to @Yardanico "even in forward declarations,": is there any doc about ... forward" added "nim"
15:18:23FromDiscord<Yardanico> https://nim-lang.org/docs/manual.html#procedures
15:18:29FromDiscord<Yardanico> i linked it already
15:18:32FromDiscord<Yardanico> it's all in there
15:18:51FromDiscord<Yardanico> but again, the ones c2nim defines aren't really forward declarations, they're imports of the C functions to Nim
15:19:10FromDiscord<Yardanico> nim forward declarations are only made for nim-native procedures and functions
15:19:32FromDiscord<sOkam!> i see
15:19:39FromDiscord<sOkam!> In reply to @Yardanico "i linked it already": sry, didn't see it
15:20:32FromDiscord<sOkam!> considering that nim doesn't use header files, should I be translating `.h` files at all?
15:21:10FromDiscord<sOkam!> Or should I just merge both `.h` and `.c` files of the same name into one `.nim` file, with the header content at the top?
15:21:51FromDiscord<Solitude> if you're not rewriting it in nim, .h files are the only thing you should be translating
15:22:05FromDiscord<sOkam!> I am
15:22:16FromDiscord<Solitude> ...
15:22:47FromDiscord<Solitude> so are you planning to reuse c code?
15:22:59FromDiscord<sOkam!> Should I not do that, and keep the whole project in C?↵I want to write nim, not ansic
15:23:00FromDiscord<Solitude> or are you doing straight port of c code to nim?
15:23:08FromDiscord<Solitude> you tell me
15:23:14FromDiscord<Yardanico> In reply to @sOkam! "Should I not do": it's better to do it step-by-step
15:23:25FromDiscord<Yardanico> since you can easily compile Nim code with C, just start making some Nim code with exportc
15:23:30FromDiscord<Yardanico> that you'll be using in C code
15:23:38FromDiscord<Yardanico> and do that until you converted your whole project
15:23:54FromDiscord<Yardanico> although, if it's small enough the direct "convert everything" approach will probably work too
15:24:17FromDiscord<sOkam!> In reply to @Yardanico "although, if it's small": its not small at all
15:25:04FromDiscord<sOkam!> but i don't mind. its a long term investment. I just want to end up eventually writing only nim and forget that the project was C back in who knows when
15:26:18FromDiscord<Yardanico> the thing is - direct conversion is fine, but after all you'll have to rewrite your code so it's actually idiomatic Nim
15:27:09FromDiscord<Yardanico> and i don't know if it's even useful to convert your C code to direct Nim alternative with all the C types if you'll have to rewrite large chunks of it later anyway
15:27:18FromDiscord<sOkam!> In reply to @Yardanico "since you can easily": i tried figuring that out, but i failed pretty bad. and c2nim looks pretty straight forward, since I can check line by line and slowly translate
15:27:18FromDiscord<Yardanico> so they become actual Nim with nim's native types
15:27:41FromDiscord<Yardanico> well, but again, if you just want to convert the C code directly to Nim without making it use Nim native types and containers, there's really no point
15:28:09*ehmry quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
15:28:11FromDiscord<sOkam!> That would be great, but I'm definitely not knowledgeable enough to understand the type conversion part
15:28:32FromDiscord<Yardanico> not just simple type conversion
15:28:43FromDiscord<Yardanico> e.g. your C project is using C libc functions for string management
15:28:45FromDiscord<sOkam!> In reply to @Yardanico "well, but again, if": there is one big point. I don't need to write C if the whole thing is nim
15:28:50FromDiscord<Yardanico> you'll have to rewrite them to use nim strutils and stuff
15:28:58FromDiscord<Yardanico> In reply to @sOkam! "there is one big": You don't have to write C either even if your project is in C
15:29:06FromDiscord<Yardanico> you can extend it with Nim as well, just using the C native types
15:29:28FromDiscord<sOkam!> I tried asking for help here before, and it was always "use futhark" or something similar
15:29:31FromDiscord<sOkam!> I really tried, and failed
15:29:39FromDiscord<sOkam!> I have no clue how to do that 😔
15:30:27*SamuelMarks quit (Ping timeout: 240 seconds)
15:31:44nrds<Prestige99> Is there a way to statically compile c code into a nim binary?
15:31:58nrds<Prestige99> Maybe I should post on the forum..
15:32:41FromDiscord<Yardanico> you just use {.compile.}
15:32:49FromDiscord<Yardanico> or compile your C code to object files and then link that with your Nim code
15:33:57nrds<Prestige99> Yeah my goal is to ship one binary without external dynamic libs, I'll look into the compile pragma
15:37:07nrds<Prestige99> This might be complicated for something like SDL I guess
15:37:27nrds<Prestige99> I can already statically compile SDL but yeah
15:39:48*ehmry joined #nim
15:41:38nrds<Prestige99> Can I statically link with {.link.} ?
15:42:25FromDiscord<demotomohiro> Why dont you use dynamic link library?
15:43:07nrds<Prestige99> Big pain to deal with shipping the dependencies, and it's recommended to statically link for WASM
15:44:35FromDiscord<demotomohiro> SDL are installed on most of linux or package manager can install it. On windows, people ship program with .dll.
15:45:08nrds<Prestige99> Sure but it's more than just the main SDL library, and also that still wouldn't help with WASM
15:45:42nrds<Prestige99> I'm currently dynamically linking because I haven't figured out static linking with Nim, I really don't want to be dynamically linking
15:47:41FromDiscord<demotomohiro> `--clib:LIBNAME` option or `--passL:-lstaticlibname` option doesn't work to link static lib?
15:48:23nrds<Prestige99> I'll have to try it - haven't found info on how to do it, so I've had little success
15:50:34*kenran quit (Quit: WeeChat info:version)
15:52:37FromDiscord<demotomohiro> At first, when you link C library statically, you need to get it or build it as static library. Most of build tools for C have option to compile to static library.
15:52:55FromDiscord<juan_carlos> sent a long message, see http://ix.io/3V2Q
15:53:21nrds<Prestige99> I think I have all but 1 built statically
15:58:23*vicfred joined #nim
16:09:43*SamuelMarks joined #nim
16:11:55arkanoidboth "vorbis" and "ogg" packages in nible repo are broken (404 not found). Do you know if there are bindings for libogg?
16:12:01*Gustavo6046 joined #nim
16:16:11*Gustavo6046 quit (Read error: Connection reset by peer)
16:16:13*Gustavo6046_ joined #nim
16:16:26*SamuelMarks quit (Ping timeout: 250 seconds)
16:16:54*Gustavo6046_ quit (Read error: Connection reset by peer)
16:22:39*jjido quit (Quit: My MacBook Air has gone to sleep. ZZZzzz…)
16:23:44FromDiscord<Yayko> Hello everyone, I'm learning more about Nim, I wanted to know what "include" is for, I didn't quite understand?
16:24:38FromDiscord<Yardanico> In reply to @Yayko "Hello everyone, I'm learning": it literally just "adds" the code from the file you specify in the include statement to the place where you have "include"
16:25:15FromDiscord<Yardanico> sent a code paste, see https://paste.rs/Q6n
16:25:24FromDiscord<Yardanico> but it's recommended to avoid `include` where possible instead using nim's module system
16:27:16FromDiscord<Yayko> In reply to @Yardanico "it literally just "adds"": Ok that's what I understood, but I don't find too much use compared to an import ^^
16:27:36FromDiscord<Yardanico> sometimes when you just want to break one big file into two files without making proper `import` statements and exporting symbols
16:32:56*Gustavo6046 joined #nim
16:34:34*xet7 joined #nim
16:40:24*xet7 quit (Ping timeout: 248 seconds)
16:40:24*jjido joined #nim
16:43:01FromDiscord<Jakraes> Does anyone have the link for that blog that talked about good code practices in nim?
16:43:29FromDiscord<Jakraes> I lost the link :/
16:43:41*SamuelMarks joined #nim
16:49:03*SamuelMarks quit (Ping timeout: 256 seconds)
16:58:08*jjido quit (Quit: My MacBook Air has gone to sleep. ZZZzzz…)
16:59:03arkanoidit's so damn difficult getting autocompletion to work with nim
17:00:38*jjido joined #nim
17:02:01arkanoidthe logging of the vscode extension doesn't say anything, it's completely useless
17:02:10FromDiscord<Yardanico> it always works for me 🤷
17:02:17FromDiscord<Yardanico> well, not always, but in most of cases
17:02:23FromDiscord<Yardanico> just get a blessing from the nim gods
17:02:34arkanoiddo you use "nim.project" settings?
17:03:58FromDiscord<Yardanico> no
17:04:05FromDiscord<Yardanico> but how would those change anything
17:04:46arkanoidI manage to get back to nim every now and then, and this lack of turnkey experience always makes me want to throw nim out of the window
17:05:28arkanoidmy vscode settings.json is empty for my workspace, so I'm using stock config
17:07:42*kenran joined #nim
17:15:06*vicfred quit (Quit: Leaving)
17:19:52*SamuelMarks joined #nim
17:24:45*SamuelMarks quit (Ping timeout: 256 seconds)
17:25:27*kenran quit (Quit: WeeChat info:version)
17:25:39*kenran joined #nim
17:41:53FromDiscord<hmmm> hmmm what does the science of progamming say about looping a buncha things but you need the first iteration to behave slightly differently? As usual I'm using the caveman approach but I'm pretty sure there must be an elegant way I don't know 🤔
17:43:46FromDiscord<Solitude> nah, we wish there was
17:44:04FromDiscord<hmmm> sadge 😦
17:45:03FromDiscord<d4rckh> I forgot what they were called, but its those integer timestamps, how can I get one from DateTime?
17:45:12FromDiscord<hmmm> solibro always on the freshest vernacular I see 😄
17:46:11FromDiscord<Solitude> In reply to @d4rckh "I forgot what they": tounix or something
17:57:06*vicfred joined #nim
17:59:12FromDiscord<d4rckh> thanks!
17:59:39FromDiscord<d4rckh> can i get nano seconds from a datetime object?
17:59:43FromDiscord<d4rckh> (edit) "object?" => "object when formatting it?"
18:01:21FromDiscord<d4rckh> fff seems to work
18:01:34*rockcavera joined #nim
18:01:35*rockcavera quit (Changing host)
18:01:35*rockcavera joined #nim
18:10:03*SamuelMarks joined #nim
18:15:13*SamuelMarks quit (Ping timeout: 272 seconds)
18:21:30*enyc quit (Ping timeout: 252 seconds)
19:01:17*kenran quit (Quit: WeeChat info:version)
19:01:39*SamuelMarks joined #nim
19:04:29*rockcavera quit (Ping timeout: 256 seconds)
19:05:21*zeus-supreme1 joined #nim
19:06:20*jmdaemon joined #nim
19:06:43*SamuelMarks quit (Ping timeout: 260 seconds)
19:07:40*zeus-supreme quit (Read error: Connection reset by peer)
19:11:05*SamuelMarks joined #nim
19:17:34FromDiscord<Jakraes> Is it possible to define an array with an undefined size?
19:18:08nrds<Prestige99> Nah but you can create a sequence which can change size at runtime
19:18:42FromDiscord<Jakraes> Hmmm that does work as well
19:33:13Amun-RaJakraes: only seq
19:33:28Amun-Rayes, you can create arrays in compile time
19:34:26FromDiscord<jmgomez> Does nim has support for some sort of reflection at runtime? i.e. executing a method on an object by str?
19:35:41FromDiscord<Yardanico> no, but generally it's not needed as you have a lot of advanced macro stuff at the compile time
19:35:45Amun-Ramacros
19:36:07FromDiscord<Yardanico> you can have "executing by proc name" if you store procedures in a table of course, but then they all have to be the same type
19:36:40FromDiscord<jmgomez> okay
19:36:40FromDiscord<jmgomez> thanks
19:37:14Amun-RaI'd refactor that code, tho
19:38:59FromDiscord<jmgomez> Im just curios as Im looking for how to approach a large cpp binding
19:39:12FromDiscord<jmgomez> I do have a reflection mechanism on the cpp side of things
19:41:36Amun-Rawhat mechanism do you use on cxx side?
19:41:42*noeontheend joined #nim
19:45:01FromDiscord<jmgomez> UE's Reflection System
19:45:27FromDiscord<jmgomez> Im planning to use Im not actually using it yet
19:45:29FromDiscord<jmgomez> lol
19:46:32*jmdaemon quit (Read error: Connection reset by peer)
19:46:42*jmd_ joined #nim
19:47:07*jjido quit (Quit: My MacBook Air has gone to sleep. ZZZzzz…)
19:54:10*bananahead joined #nim
19:55:01Amun-Ra:>
20:04:09*SamuelMarks quit (Ping timeout: 272 seconds)
20:07:27FromDiscord<Jakraes> Quick question, I'm using the same imported library on various files, is there a way to just import it once across all files?
20:12:52FromDiscord<!Patitotective> id say no↵but if those modules import each other you could export it https://nim-lang.org/docs/manual.html#modules-export-statement
20:17:30FromDiscord<Yardanico> In reply to @Jakraes "Quick question, I'm using": there is one way, but it's kind of unclean anyway
20:18:06FromDiscord<Yardanico> `--import` compiler flag, although I don't think it allows to import stdlib modules if you don't know their PATH
20:18:07FromDiscord<Yardanico> https://nim-lang.org/docs/nimc.html
20:18:12FromDiscord<Yardanico> so yeah, just import in all files, it's not a big deal
20:24:10FromDiscord<hmmm> In reply to @Jakraes "Quick question, I'm using": hey jak why is bad importing the same stuff for every module? 🤔 (signed by a serial mass importer that is now sweating)
20:25:34FromDiscord<Jakraes> In reply to @Yardanico "`--import` compiler flag, although": I might try that out, and I'll try export as well and see which one works best for what I want
20:25:57FromDiscord<Jakraes> In reply to @hmmm "hey jak why is": It's just C habits more or less, since you can just import everything into a header file
20:26:51FromDiscord<Yardanico> well, Nim doesn't work that way really
20:28:03FromDiscord<Jakraes> Yeah I figured, it's no biggie though, I don't mind the imports that much
20:30:17FromDiscord<spoon> wouldn't you still have to include that header file in everything?
20:30:26*SamuelMarks joined #nim
20:30:55FromDiscord<Jakraes> Yeah, but instead of import 3 or 4 libraries you can import all of them into a header file and just import that file
20:31:40FromDiscord<spoon> well i mean i'm pretty sure in theory you could make a nim file that just `import`s all the libraries and then `export`s them
20:32:06FromDiscord<spoon> then just include that
20:32:22FromDiscord<ynfle> In reply to @spoon "well i mean i'm": This is used for `std/prelude`
20:33:42FromDiscord<spoon> its also how a lot of libraries have one core file, by exporting all the submodules
20:33:56FromDiscord<hmmm> anyway the real nastiness about imports is the recursive thingy. I want a simple world in which A imports B and B imports A and all is nice in the world 🧐
20:35:03FromDiscord<spoon> In reply to @hmmm "anyway the real nastiness": export statement?
20:35:09*SamuelMarks quit (Ping timeout: 256 seconds)
20:37:18FromDiscord<hmmm> hmm I don't use it. I use a weird matrioska way in which types are the smallest and gets imported by everyone and you have bigger modules that import the smallest. It's mental and I hope Araq will soon free me from it 🤔
20:45:07*noeontheend quit (Ping timeout: 240 seconds)
20:48:05*SamuelMarks joined #nim
20:52:27*SamuelMarks quit (Ping timeout: 240 seconds)
20:54:40*supakeen quit (Remote host closed the connection)
20:58:53FromDiscord<SolitudeSF> thats not nice↵(@hmmm)
20:59:16*jjido joined #nim
20:59:45FromDiscord<hmmm> hmm? 🤔
21:05:45Amun-Rafree in what matter?
21:12:10*vicfred quit (Quit: Leaving)
21:15:42*rockcavera joined #nim
21:15:43*rockcavera quit (Changing host)
21:15:43*rockcavera joined #nim
21:26:45FromDiscord<Ayy Lmao> sent a code paste, see https://play.nim-lang.org/#ix=3V45
21:27:12FromDiscord<Ayy Lmao> (edit) "https://play.nim-lang.org/#ix=3V45" => "https://play.nim-lang.org/#ix=3V46"
21:32:04FromDiscord<konsumlamm> looks like a bug to me
21:46:47FromDiscord<!Patitotective> In reply to @hmmm "anyway the real nastiness": that would be so confusing, having a `commons.nim` module makes everything cleaner and clearer if it's not your code, i think
21:47:09FromDiscord<!Patitotective> i have never needed a recursive import, until now 🤷‍♂️
21:47:52FromDiscord<!Patitotective> (edit) "import," => "import"
21:51:13FromDiscord<Generic> I desparately need cyclic imports
21:52:11FromDiscord<Generic> it really depends on your project, some just have this cyclic property, there's no way around it
21:52:29*SamuelMarks joined #nim
21:53:12FromDiscord<Elegantbeef> Well Nim has limited cyclical support but requires using the noggin to make it work
21:53:22FromDiscord<Generic> I'm using that already as much as possible
21:53:28FromDiscord<Generic> but I've come to the point where it breaks cgen
21:53:57FromDiscord<Generic> so I have to resort to even exportc/importc
21:54:02FromDiscord<Elegantbeef> breaking cgen instead of Nim compiling using it is quite a challenge
21:54:45FromDiscord<Generic> the problem is that it somehow forgets to generate the function prototype in one file
21:55:02FromDiscord<Generic> but I couldn't make a minimal example, so I didn't report it
21:55:57*dv^_^ quit (Quit: dv^_^)
21:56:26*dv^_^ joined #nim
21:57:08*dropkick joined #nim
21:57:12*SamuelMarks quit (Ping timeout: 248 seconds)
21:57:38FromDiscord<!Patitotective> sent a code paste, see https://play.nim-lang.org/#ix=3V47
21:57:44FromDiscord<!Patitotective> (edit) "https://play.nim-lang.org/#ix=3V47" => "https://play.nim-lang.org/#ix=3V48"
21:58:12FromDiscord<!Patitotective> (edit) "https://play.nim-lang.org/#ix=3V48" => "https://paste.rs/F4x"
21:58:26FromDiscord<Elegantbeef> `igWindow do:`
21:59:32*SamuelMarks joined #nim
22:00:07FromDiscord<!Patitotective> sent a code paste, see https://play.nim-lang.org/#ix=3V49
22:00:31FromDiscord<Elegantbeef> Yes
22:00:39FromDiscord<Elegantbeef> `do` should pass to the last argument
22:01:06FromDiscord<!Patitotective> same error :C↵https://play.nim-lang.org/#ix=3V4b
22:01:34FromDiscord<Elegantbeef> Well then you need a seperate template
22:02:55FromDiscord<morgan> sent a code paste, see https://play.nim-lang.org/#ix=3V4d
22:03:02FromDiscord<morgan> obvs in that example it doesn't matter
22:03:21FromDiscord<morgan> but when i have several long types being or'd together it's a bit more helpful
22:03:34FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=3V4e
22:03:43FromDiscord<Elegantbeef> the infix operator has to be at the end of a line
22:04:16FromDiscord<Elegantbeef> This way the compiler knows "Hey the next statement is apart of this one"
22:04:49FromDiscord<morgan> ooohh ok makes sense
22:04:51FromDiscord<morgan> thanks
22:05:33FromDiscord<!Patitotective> In reply to @Elegantbeef "This way the compiler": ~~if that were that easy 💀 ~~
22:05:54FromDiscord<Elegantbeef> What?
22:07:15FromDiscord<!Patitotective> npeg is sometimes not that handy so it gets complicated, at least for me
22:07:49FromDiscord<!Patitotective> i mean, parsing
22:08:11FromDiscord<Elegantbeef> I mean the same rule applies
22:08:13FromDiscord<Elegantbeef> DSLs have to abide by the Nim parser
22:09:51FromDiscord<morgan> sent a code paste, see https://paste.rs/HPR
22:09:58FromDiscord<Elegantbeef> Wrap your procs with `()`
22:10:09FromDiscord<Elegantbeef> Also you know you dont need the `: void`?
22:10:16FromDiscord<Yardanico> In reply to @MorganAlyssa "aw i can't seem": this won't work
22:10:21FromDiscord<Yardanico> first of all, you can't store a `var` in a tuple
22:10:39FromDiscord<Yardanico> ah, callback might work, but then your tuples won't be interchangeable
22:11:08FromDiscord<Elegantbeef> Eh i've already told them they can use a `pointer` for their tagged unions and cast back
22:11:13FromDiscord<Elegantbeef> That works
22:11:17FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=3V4f
22:11:23FromDiscord<Elegantbeef> The issue is `: void or`
22:11:27FromDiscord<morgan> ok
22:12:46FromDiscord<Elegantbeef> `func initFlag(t: typedesc[ValidFlags], args... , callback: proc(val: t)): FlagVariant = result.callBack = cast[pointer](callback)`
22:13:17FromDiscord<Elegantbeef> Think they didnt like that they had to do `type.initFlag` or something, they'd rather have a tedious api from what i can tell
22:14:38FromDiscord<morgan> what im working on now, it's gonna let you input a list of tuples containing the params you'd put into one of the procs and then loop over that to add them
22:15:08*jjido quit (Quit: My MacBook Air has gone to sleep. ZZZzzz…)
22:16:02FromDiscord<morgan> so yes im trying to make an easier api
22:16:10FromDiscord<Elegantbeef> Well the api you
22:16:15FromDiscord<Elegantbeef> you
22:16:15FromDiscord<Elegantbeef> Jesus
22:16:19FromDiscord<Elegantbeef> ..... i cannot hit '
22:16:39FromDiscord<Elegantbeef> you're making is just the same as the one i suggested but more complicated
22:18:02FromDiscord<morgan> from what i remember you suggesting, this would be simpler to a user
22:18:14FromDiscord<morgan> instead of a list with a bunch of procs or something idr exactly
22:26:54*supakeen joined #nim
22:29:36FromDiscord<!Patitotective> sent a code paste, see https://play.nim-lang.org/#ix=3V4m
22:33:02FromDiscord<morgan> really annoyed that im gonna have to have like 20 tuples or'd for this instead of 4 with a param having an or'd type
22:33:50FromDiscord<Elegantbeef> https://play.nim-lang.org/#ix=3V4n
22:34:32FromDiscord<Elegantbeef> Sorry
22:34:32FromDiscord<Elegantbeef> https://play.nim-lang.org/#ix=3V4o here
22:35:22FromDiscord<Elegantbeef> No need for tuples or anything wacky
22:35:23FromDiscord<morgan> hm i could do two openarrays instead of one, with one just for callbacks or references
22:36:35*syl quit (Quit: ZNC 1.8.2 - https://znc.in)
22:37:10*syl joined #nim
22:39:54*SamuelMarks quit (Quit: leaving)
22:47:19*gsalazar quit (Ping timeout: 256 seconds)
22:50:09*noeontheend joined #nim
22:56:59FromDiscord<Elegantbeef> patito look at the code you're generating
22:56:59FromDiscord<Elegantbeef> https://play.nim-lang.org/#ix=3V4u
22:57:00FromDiscord<Elegantbeef> `greet()` isnt valid
22:58:16FromDiscord<!Patitotective> becase it missed the parameters, right?
23:07:25FromDiscord<Elegantbeef> yes
23:09:14FromDiscord<Forest> Heya, what's a good library for making android apps?
23:09:44FromDiscord<Forest> I wanna make a game, and I'd preferably want it to be usable on PC and Android, but Android is my main focus (and tbh iOS would be a plus)
23:09:57FromDiscord<Elegantbeef> Dont think most libraries are setup to be programmed from mobile
23:10:20FromDiscord<Forest> I wanna make an app for mobile lol, not with
23:10:32FromDiscord<Elegantbeef> Have you changed?
23:10:38FromDiscord<Forest> ~~Since i already have the android ndk and sdk installed on my phone~~
23:10:44FromDiscord<Yardanico> In reply to @Forest "I wanna make a": making a game is not the same as making an app
23:10:50FromDiscord<Yardanico> for making a game on android you can use the same tools as on desktop
23:10:53FromDiscord<Yardanico> e.g. SDL
23:10:56FromDiscord<Forest> Oh fair
23:10:57FromDiscord<Yardanico> nico for example works well on android
23:11:03FromDiscord<Forest> Alright, thanks!
23:11:04FromDiscord<Elegantbeef> Yep sdl2 is quite easy to work with
23:11:15FromDiscord<Elegantbeef> make a new activity that inherits the sdl2 activity and use ndk to build your project
23:12:41FromDiscord<Forest> Alright, thanks!
23:14:12FromDiscord<Forest> Hm would Naylib be a good idea for making a character creator app?
23:15:09FromDiscord<Yardanico> there's no really notion of "good idea" or not, since it's not a game engine and just a game framework
23:15:49FromDiscord<Yardanico> also why do you have a different nickname each time you become active on this server again 🤔
23:16:10FromDiscord<Elegantbeef> Yard can you change your name to metreanico?
23:16:21FromDiscord<Yardanico> no
23:16:33FromDiscord<Elegantbeef> Damn was worth a try to get you to metric
23:16:39FromDiscord<Yardanico> im metric already
23:16:50FromDiscord<Elegantbeef> A yard is imperial
23:18:14FromDiscord<Forest> In reply to @Yardanico "there's no really notion": Fair
23:18:25FromDiscord<Forest> In reply to @Yardanico "also why do you": Eh? I haven't changed it for a long time now?
23:18:36FromDiscord<Forest> I've had this for a few months xD
23:20:08FromDiscord<Yardanico> > few months
23:20:16FromDiscord<Yardanico> that is very often in my book
23:23:26FromDiscord<!Patitotective> @ElegantBeef now its adding the parameters but i guess not the right way cause it says `Error: internal error: environment misses: name`↵https://play.nim-lang.org/#ix=3V4znot sure how to convert param into an ident or to something that's evaluated as a variable
23:23:30FromDiscord<!Patitotective> (edit) "name`↵https://play.nim-lang.org/#ix=3V4znot" => "name`↵https://play.nim-lang.org/#ix=3V4z↵not"
23:31:17FromDiscord<Elegantbeef> You're really making this backwards and upside down
23:32:02FromDiscord<!Patitotective> :C
23:32:18FromDiscord<!Patitotective> you gotta write a macro's article
23:32:28FromDiscord<Elegantbeef> I have
23:32:53FromDiscord<!Patitotective> :o
23:33:10FromDiscord<!Patitotective> this https://dev.to/beef331/demystification-of-macros-in-nim-13n8 ?
23:37:31FromDiscord<Elegantbeef> https://play.nim-lang.org/#ix=3V4B
23:37:32FromDiscord<Elegantbeef> Write less `[]` not more
23:37:50FromDiscord<Yardanico> [] is the Nim way of smiling
23:37:54FromDiscord<Yardanico> :]
23:37:58FromDiscord<!Patitotective> lmao
23:38:03FromDiscord<Yardanico> we actually have [: in the language
23:38:09FromDiscord<Elegantbeef> No it's the way of writing ugly macros
23:38:14FromDiscord<Elegantbeef> Micros not macros, cmon people!
23:38:21FromDiscord<Yardanico> Macrohard
23:38:32FromDiscord<Elegantbeef> No micros easy
23:38:37FromDiscord<!Patitotective> In reply to @Yardanico "we actually have [:": :[
23:38:38FromDiscord<Yardanico> Microsoft
23:38:39*jmd_ quit (Quit: ZNC 1.8.2 - https://znc.in)
23:38:57*jmdaemon joined #nim
23:38:58FromDiscord<!Patitotective> gotta try micros
23:39:11FromDiscord<Elegantbeef> I really need to actually make a nimib or nimibook writeup for micros it's a big blackbox
23:39:24FromDiscord<Elegantbeef> But it's much cleaner to read/write
23:40:58FromDiscord<!Patitotective> btw is it better to use `genast` or `quote do`? i dont like importing stuff lol
23:41:27*noeontheend quit (Ping timeout: 240 seconds)
23:42:22FromDiscord<Elegantbeef> `genast` is better than quote do
23:42:31FromDiscord<Elegantbeef> "i dont like importing stuff" is dumb
23:42:36FromDiscord<Elegantbeef> Modules exist, use them
23:42:41*vicfred joined #nim
23:43:31FromDiscord<!Patitotective> In reply to @Elegantbeef "`genast` is better than": why
23:43:39FromDiscord<!Patitotective> In reply to @Elegantbeef "Modules exist, use them": :]
23:47:36FromDiscord<Elegantbeef> Cause it doesnt require accquoting and you dont need `let x = a` before the call