<< 09-07-2022 >>

00:10:23*hc0re quit (Ping timeout: 256 seconds)
00:12:53*hc0re joined #nim
00:21:37FromDiscord<xflywind> I used vtune to profile the Nim compiler, then my PC crashed.
00:22:32FromDiscord<Elegantbeef> "Ah it says here the entire program is a problem"
00:24:55FromDiscord<xflywind> lol, tried again. different crash code 🤣
00:27:01FromDiscord<xflywind> https://media.discordapp.net/attachments/371759389889003532/995123875916558346/unknown.png
00:27:17FromDiscord<xflywind> It seems that the hardware mode is quite dangerous
00:28:19FromDiscord<Generic> ah yes vtune bsod with hw based sampling
00:42:01FromDiscord<ajusa> Has anyone used vmath's swizzle functionality? Wondering where it would be useful
00:42:24FromDiscord<Elegantbeef> Swizzling is useful whenever you want specific components of a vector
00:43:03FromDiscord<enthus1ast> swizzle ist that right?↵.rgb↵mat
00:43:06FromDiscord<Elegantbeef> Say you have a vector3 and want to pass it as a vector2 for whatever reason
00:43:18FromDiscord<enthus1ast> [Edit](https://discord.com/channels/371759389889003530/371759389889003532/995127913122906224): swizzle ist that right?↵col.rgb↵col.rgba
00:43:20FromDiscord<Elegantbeef> it's the component level access on a vector
00:43:26FromDiscord<ajusa> In a certain order, right? I'm looking at https://www.3dbrew.org/wiki/SMDH (specifically the last part of the graphics section) and wondering if swizzling would help there
00:43:54FromDiscord<ajusa> Since it seems to encode it in tiles
00:44:12FromDiscord<Elegantbeef> The point of swizzling is to access specific components in a specific order
00:44:21FromDiscord<Elegantbeef> If you need that then swizzling is useful
00:44:42FromDiscord<ajusa> Okay, sounds like I'm confusing tiling and swizzling. Thanks for clarifying!
00:48:50FromDiscord<sOkam!> Does someone know how to work with `mat` types from `glm`?
00:49:08FromDiscord<Elegantbeef> Probably
00:49:12FromDiscord<Elegantbeef> What's the actual question
00:51:53FromDiscord<sOkam!> sent a code paste, see https://play.nim-lang.org/#ix=420q
00:52:33FromDiscord<sOkam!> I'm reading the source file of glm/mat.... but I don't understand why b is not a valid field of a matrix, when abcd are listed in the source code
00:54:04FromDiscord<Elegantbeef> Where are they listed in the source code?
00:54:31FromDiscord<sOkam!> sent a code paste, see https://play.nim-lang.org/#ix=420r
00:55:08FromDiscord<sOkam!> sent a code paste, see https://play.nim-lang.org/#ix=420s
00:55:25FromDiscord<Elegantbeef> Did you read what that template does?
00:55:37FromDiscord<sOkam!> I read it, doesn't mean I understand it
00:55:49FromDiscord<Elegantbeef> It calls the constructors
00:55:58FromDiscord<sOkam!> And there is no documentation on the matrices, just on the vectors
00:56:13FromDiscord<Elegantbeef> you want `a.arr[0].y` probably
00:56:33FromDiscord<Elegantbeef> or just `a[1]` rather
00:57:00FromDiscord<sOkam!> so there is no alias for each row?
00:57:13FromDiscord<Elegantbeef> There is not
00:58:32*jmdaemon joined #nim
00:59:04FromDiscord<sOkam!> and how do you access the components of each row?
00:59:18FromDiscord<Elegantbeef> `rows`
00:59:33FromDiscord<Elegantbeef> Sorry `row`
00:59:57FromDiscord<sOkam!> ?
01:00:12FromDiscord<Elegantbeef> https://github.com/stavenko/nim-glm/blob/master/glm/mat.nim#L316-L335
01:01:06FromDiscord<Elegantbeef> you can do `mat[x, y]` to access a specific component and `mat[x]` to get specific group
01:01:29FromDiscord<Elegantbeef> I dont know what `mat[x]` returns if it's what people call rows or columns
01:01:29FromDiscord<sOkam!> is mat the variable or the type?
01:01:37FromDiscord<sOkam!> or a proc
01:01:38FromDiscord<Elegantbeef> You're kidding right
01:01:47FromDiscord<sOkam!> im not, ive been stuck in this for hours for a reason
01:01:53FromDiscord<Elegantbeef> It's an instance
01:01:56FromDiscord<sOkam!> please don't assume i understand this, because i dont
01:02:28FromDiscord<sOkam!> never dealt with templates in my life, so this file is mega cryptic for me
01:02:29FromDiscord<Elegantbeef> The `[]` and `[]=` are defined https://github.com/stavenko/nim-glm/blob/master/glm/mat.nim#L44-L56
01:03:15FromDiscord<sOkam!> If i knew templates i could read the file no issue. But I don't understand it, so linking to the file I have open won't help much šŸ˜”
01:03:41FromDiscord<Elegantbeef> Are we talking about generics or that one template?
01:04:01FromDiscord<Elegantbeef> Nothing here is complicated, so let's solve your lacking of understanding
01:04:16FromDiscord<sOkam!> about accesing field `a.x` of mat3x3f. Just a simple example of that, which there is no documentation about
01:04:37FromDiscord<Elegantbeef> No we're going to make you understand this file
01:04:39FromDiscord<sOkam!> `thing.a.x` is what I thought I was supposed to access
01:04:58FromDiscord<Elegantbeef> If you cant read this code you're not going to be able to figure anything out with it
01:05:08FromDiscord<sOkam!> there is no a... so I try `thing[0].x`.... and still same issue
01:05:18FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=420v
01:05:55FromDiscord<sOkam!> proc `[]=` that returns nothing, which takes some mat thing (no clue) an int and some vector (also no clue)
01:06:18FromDiscord<sOkam!> (edit)
01:06:22FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=420w
01:06:34FromDiscord<Elegantbeef> So the generic here ensures that the matrix and the vector are of the same type
01:06:59FromDiscord<Elegantbeef> `M` is the number of matrix elements, `N` is the number of vector elements and `T` is the type of element
01:07:19FromDiscord<Elegantbeef> So a 3 by 3 matrix with float32 is `Mat[3, 3, float32]`
01:09:03FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=420x
01:09:37FromDiscord<Elegantbeef> With that in mind if you do `myMat[1].x` it will return the x component of the second row(Like i said i'm fucking awful at esoteric names)
01:10:09FromDiscord<Elegantbeef> So in your case you want to do `result[1, 0] = a.y`
01:10:12*bigbyt quit (Read error: Connection reset by peer)
01:10:40*bigbyt joined #nim
01:10:42FromDiscord<Elegantbeef> Or `result[1].y = a.y`
01:11:13FromDiscord<sOkam!> `this[0].x` is saying that there is no X
01:11:45FromDiscord<sOkam!> https://media.discordapp.net/attachments/371759389889003532/995135131335528549/unknown.png
01:11:52FromDiscord<sOkam!> can't copypaste, sry about the size
01:12:59FromDiscord<sOkam!> sent a code paste, see https://play.nim-lang.org/#ix=420y
01:13:43FromDiscord<Elegantbeef> Is the compiler erroring or the lsp?
01:13:47FromDiscord<Elegantbeef> Cause it compiles
01:13:47FromDiscord<sOkam!> lsp
01:13:54FromDiscord<Elegantbeef> ...
01:14:18FromDiscord<sOkam!> nimls specifically
01:14:53FromDiscord<sOkam!> if I change it to array indexes only, it seems to not complain
01:15:41FromDiscord<Elegantbeef> Restart your editor
01:15:41FromDiscord<Elegantbeef> Both LSPs work fine here
01:17:08FromDiscord<Elegantbeef> It doesnt complain eitherway for me
01:17:21FromDiscord<Elegantbeef> `nim -v`?
01:31:53FromDiscord<sOkam!> sent a code paste, see https://play.nim-lang.org/#ix=420A
01:46:33FromDiscord<xflywind> Is the nim compiler the blocker for compilation time?
01:46:38FromDiscord<xflywind> https://media.discordapp.net/attachments/371759389889003532/995143914480738355/unknown.png
01:47:45FromDiscord<xflywind> For a full compilation, it occupies 10% of the compilation time.
01:48:34FromDiscord<Rika> I mean that depends on which C compiler you use of course
02:00:55FromDiscord<Generic> time for the Nim compiler to start outputting code directly
02:01:32FromDiscord<Generic> I already have a terrible SSA based intermediate representation with a code generator for it in my emulator
02:02:02FromDiscord<Elegantbeef> The slow down is stil a majority Nim
02:02:07FromDiscord<Elegantbeef> Turns out reference based compilers are not fast
02:05:30FromDiscord<xflywind> I think incRef in the compiler hotpot can be probably optimized since I can turn them into cursor/ptr.
02:06:13FromDiscord<xflywind> https://media.discordapp.net/attachments/371759389889003532/995148842951520287/unknown.png
02:06:48FromDiscord<Elegantbeef> Also what's the program you're compiling?
02:06:55FromDiscord<Elegantbeef> And this is with a orc booted Nim compiler?
02:07:12FromDiscord<xflywind> orc booted compiler to compile the Nim compiler
02:07:20FromDiscord<xflywind> (edit) "orc booted compiler to compile the Nim compiler ... " added "using orc"
02:07:23FromDiscord<Elegantbeef> Ah ok that's what i imagined
02:07:42FromDiscord<xflywind> https://media.discordapp.net/attachments/371759389889003532/995149216081002606/unknown.png
02:09:59FromDiscord<sOkam!> sent a code paste, see https://play.nim-lang.org/#ix=420H
02:10:08FromDiscord<enthus1ast> i might be to tired but these (257,292ms) are 0.2 seconds or↵(@xflywind)
02:10:08FromDiscord<Elegantbeef> `var T`
02:10:19FromDiscord<Elegantbeef> `thing: var MyType`
02:10:36FromDiscord<enthus1ast> [Edit](https://discord.com/channels/371759389889003530/371759389889003532/995149826301890570): i might be to tired but these (257,292ms) are 0.2 seconds or 257 seconds?
02:10:39FromDiscord<sOkam!> var links as a reference?
02:10:53FromDiscord<xflywind> In reply to @enthus1ast "[Edit](https://discord.com/channels/371759389889003": 0.2 seconds
02:11:00FromDiscord<Luckayla> It's a point. 257 point 292 ms
02:11:02FromDiscord<Elegantbeef> `var T` is a mutable reference
02:11:18FromDiscord<sOkam!> ic
02:11:33FromDiscord<enthus1ast> points are thousends (in germany)↵(@Luckayla)
02:12:04FromDiscord<Elegantbeef> Decimal comma vs decimal point
02:12:05FromDiscord<Elegantbeef> Always a lovely chat
02:12:17FromDiscord<enthus1ast> how long does the compilation takes overall @xflywind
02:12:37FromDiscord<Elegantbeef> thought germans were all about efficiency odd that they use decimal commas
02:12:42FromDiscord<enthus1ast> ask that excel
02:13:08FromDiscord<xflywind> https://media.discordapp.net/attachments/371759389889003532/995150583021457509/unknown.png
02:13:44FromDiscord<Elegantbeef> This reminds me https://erikmcclure.com/blog/windows-malloc-implementation-is-a-trash-fire/ is a fun writeup
02:13:48FromDiscord<xflywind> 38.3% of 17.741s
02:14:30FromDiscord<xflywind> Probably I should try -d:useMalloc
02:15:11FromDiscord<Elegantbeef> Also is this without a cache?
02:15:37FromDiscord<Elegantbeef> I imagine not since 20s is fucking fast
02:15:39FromDiscord<xflywind> It is a partial compilation I changed something
02:15:49FromDiscord<xflywind> (edit) "It is a partial compilation I changed something ... " added "in compiler."
02:15:52FromDiscord<Elegantbeef> Ok so there we go
02:15:54FromDiscord<Elegantbeef> The Nim compiler doesnt have to do much
02:16:11FromDiscord<Elegantbeef> It'd take forever but if you passed `-f` you'd see drastically different data
02:16:26FromDiscord<Elegantbeef> Actually representative of the slowdowns
02:16:33FromDiscord<xflywind> 40s for a full compilation and occupy 10%
02:16:50FromDiscord<Elegantbeef> Jesus 40s, way to insult my poor CPU
02:16:51FromDiscord<xflywind> 7s for a recompilation
02:32:21FromDiscord<huantian> In reply to @Elegantbeef "This reminds me https://erikmcclure.com/blog/window": Bunny
02:37:28FromDiscord<xflywind> In reply to @flywind "": Optimized
02:37:37FromDiscord<xflywind> sent a code paste, see https://play.nim-lang.org/#ix=420J
02:38:28FromDiscord<xflywind> original version
02:38:36FromDiscord<xflywind> sent a code paste, see https://play.nim-lang.org/#ix=420L
02:38:55FromDiscord<xflywind> (edit) "https://play.nim-lang.org/#ix=420J" => "https://play.nim-lang.org/#ix=420N"
02:42:06FromDiscord<sOkam!> sent a code paste, see https://play.nim-lang.org/#ix=420P
02:42:24FromDiscord<Elegantbeef> Using integer manually
02:42:40FromDiscord<sOkam!> i mean
02:42:49FromDiscord<sOkam!> the point is to NOT use integers, why would I make this list otherwise
02:42:58FromDiscord<Elegantbeef> atleast to me `mat[A]` is way less descriptive than `mat[0].x`
02:43:08FromDiscord<Elegantbeef> `mat[A, X]`
02:43:59FromDiscord<sOkam!> missing the point. I was asking for a way to declare multiple constants in a compact way
02:44:10FromDiscord<Elegantbeef> There is no compact way
02:44:59FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=420Q
02:44:59FromDiscord<Elegantbeef> That's the most compact you can do
02:46:59FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=420R
02:53:19FromDiscord<xflywind> It seems to allocate lots of memroy here.
02:53:22FromDiscord<xflywind> https://media.discordapp.net/attachments/371759389889003532/995160704497766451/unknown.png
02:54:41FromDiscord<xflywind> (edit) "lots of memroy" => "too much time"
02:54:54FromDiscord<xflywind> (edit) "much time" => "many times"
02:57:47FromDiscord<xflywind> let me try the larger start size.
03:04:25FromDiscord<Rika> In reply to @huantian "Bunny": bnuuy
03:40:26FromDiscord<Space Ghost> Does anyone know how to turn on a switch when compiling to show timings, i.e. how long it took to compile, maybe with some details, etc.?
03:41:01FromDiscord<enthus1ast> you could have a look at benchy
03:41:02FromDiscord<Elegantbeef> Default Nim shows time
03:41:36FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=4215
03:41:52FromDiscord<Space Ghost> I am in an embedded terminal I will try it from the command line, thank you.
03:42:56FromDiscord<Elegantbeef> I dont know how an embedded terminal changes that but, yea it's there
03:44:02FromDiscord<Space Ghost> In reply to @Elegantbeef "I dont know how": You are both right, i am wrong, it is there and I simply missed it. Thank you.
03:45:01FromDiscord<Elegantbeef> If you want to benchmark runtime code both `timeit` and `benchy` exist
03:45:16FromDiscord<Elegantbeef> Not apart of the stdlib but are in the nimble registry
03:48:11FromDiscord<Space Ghost> In reply to @Elegantbeef "Not apart of the": Thank you.
03:54:14*arkurious quit (Quit: Leaving)
03:57:17FromDiscord<ripluke> Does nim have a ā€œmascotā€
03:57:32FromDiscord<Rika> No
03:57:35FromDiscord<Rika> Technically no
03:57:40FromDiscord<ripluke> Oh
03:57:44FromDiscord<Rika> There’s the badger
03:57:53FromDiscord<Rika> :nimRawr:
03:58:00FromDiscord<ripluke> Oh
03:58:11FromDiscord<ripluke> Does it have a name
03:58:59FromDiscord<Elegantbeef> I like to think it's not named like a pet but with a title that it earned. "The last thing you see" is the title I imagine its earned.
03:59:46FromDiscord<ripluke> Um that's kinda ominous lol
03:59:50*bigbyt quit (Read error: Connection reset by peer)
04:00:11FromDiscord<Elegantbeef> Have you seen the fucking badger?
04:00:22FromDiscord<ripluke> They're kinda tiny
04:00:32FromDiscord<Elegantbeef> The thing looks like it kidnaps kids from the playground and eats it for lunch
04:00:34FromDiscord<ripluke> Compared to a lion or something
04:00:40*bigbyt joined #nim
04:00:45FromDiscord<huantian> lion + crown seems cool
04:00:46FromDiscord<ripluke> In reply to @Elegantbeef "The thing looks like": Well maybe they eat kids
04:00:49FromDiscord<huantian> but might be a bit pretentous
04:00:53FromDiscord<Elegantbeef> https://user-images.githubusercontent.com/1189414/94371104-5090e900-00ca-11eb-8e5b-d229504b1435.png
04:01:00FromDiscord<Elegantbeef> Full image
04:01:19FromDiscord<ripluke> In reply to @Elegantbeef "https://user-images.githubusercontent.com/1189414/9": It bears a striking resemblance to your profile picture šŸ’€
04:01:35FromDiscord<Elegantbeef> Nah my dog would never do that
04:01:49FromDiscord<ripluke> That's a dog?
04:01:57FromDiscord<ripluke> I thought it was a rodent šŸ’€
04:01:59FromDiscord<huantian> ripluke blind confirmed
04:02:04FromDiscord<ripluke> I'm not a biologist
04:02:09FromDiscord<Elegantbeef> Jeezus
04:02:28FromDiscord<ripluke> Well now that you mention it it does look a bit like a dog
04:02:32FromDiscord<huantian> how do you not knwo what a dog looks liek w
04:02:55FromDiscord<ripluke> In reply to @Elegantbeef "Nah my dog would": Which part? The children eating or the crown wearing
04:03:30FromDiscord<ripluke> In reply to @huantian "how do you not": Yea lol I have a dog
04:05:07FromDiscord<zhmtzhmt> why ?
04:05:07FromDiscord<zhmtzhmt> sent a code paste, see https://play.nim-lang.org/#ix=4219
04:05:34FromDiscord<zhmtzhmt> they are in different folders.
04:07:10FromDiscord<Yardanico> you need to use `as` to import the other
04:07:18FromDiscord<Yardanico> because otherwise you'll have ambiguous module symbols
04:07:33FromDiscord<Yardanico> Nim allows one to use symbols from a module as `modulename.proc()`, so in your case that'll lead to ambiguity
04:07:52FromDiscord<zhmtzhmt> I see
04:08:07FromDiscord<zhmtzhmt> Thank you very much.
05:23:20FromDiscord<ripluke> Is there a Bluetooth library for nim?
05:23:49FromDiscord<Elegantbeef> nimble.directory does exist
05:23:52FromDiscord<Elegantbeef> https://github.com/Electric-Blue/NimBluez
05:25:30FromDiscord<ripluke> In reply to @Elegantbeef "nimble.directory does exist": Ik I'm there now
05:26:02FromDiscord<ripluke> In reply to @Elegantbeef "https://github.com/Electric-Blue/NimBluez": Linux only?
05:26:13FromDiscord<ripluke> It seems to use bluez
05:26:22FromDiscord<Elegantbeef> > You can find wrappers for BlueZ in nimbluez/bluez folder. For Microsoft Bluetooth protocol stack wrappers look at nimbluez/msbt.
05:26:32FromDiscord<ripluke> Ok
05:26:43FromDiscord<Elegantbeef> It has highlevel wrappings for those APIs
05:26:51FromDiscord<Elegantbeef> If you need anything else you can manually do it
05:27:01FromDiscord<ripluke> In reply to @Elegantbeef "It has highlevel wrappings": Pretty much all I'll need
05:28:44*rockcavera quit (Remote host closed the connection)
05:57:19FromDiscord<ripluke> In reply to @Elegantbeef "https://github.com/Electric-Blue/NimBluez": Lol the main feature I need doesn't work .-.
05:57:37FromDiscord<Elegantbeef> That is?
05:57:44FromDiscord<ripluke> I'll have to do some jury rigging with Bluetoothctl
05:57:53FromDiscord<ripluke> In reply to @Elegantbeef "That is?": Device discovery
05:57:56FromDiscord<Elegantbeef> "jury rigging"
05:58:01FromDiscord<ripluke> Yea
05:58:06FromDiscord<ripluke> With execCmd
05:58:10FromDiscord<Elegantbeef> Isnt it "jerry rigging"
05:58:21FromDiscord<Elegantbeef> What doesnt work?
05:58:37FromDiscord<ripluke> In reply to @Elegantbeef "Isnt it "jerry rigging"": Yea
05:58:53FromDiscord<ripluke> In reply to @Elegantbeef "What doesnt work?": It can't detect any device
05:59:21FromDiscord<ripluke> And I know there's many in range because blueberry can detect 3-4
06:00:20FromDiscord<ripluke> The maintainer doesn't seem active
06:00:25FromDiscord<ripluke> For a few years
06:03:40*sagax quit (Remote host closed the connection)
06:05:16FromDiscord<Elegantbeef> I have to get my dongle setup but you'll be hearing from me
06:07:00FromDiscord<huantian> Hey beef how’s that template unexpanding error pr thingy going
06:07:13FromDiscord<Elegantbeef> Not i didnt get a response
06:07:30FromDiscord<Elegantbeef> Araq said no, i suggest multiple solutions he said "...."
06:08:05FromDiscord<Elegantbeef> He didnt actually say "..." but he didnt respond
06:09:15FromDiscord<huantian> Perhaps error messages just aren’t his top priority
06:10:49FromDiscord<Elegantbeef> I mean there is an issue that it requires changing the AST
06:10:59FromDiscord<Elegantbeef> Atleast afaict
06:11:17FromDiscord<Elegantbeef> My solution bloats the Nim runtime by adding another 8 bytes to every single AST node
06:11:46FromDiscord<huantian> Yeah true
06:12:23FromDiscord<huantian> What would the proper fix involve?
06:12:24FromDiscord<Elegantbeef> I tested and with the Nim compiler it only adds another 200mb but it's still there
06:12:40FromDiscord<huantian> Dang that’s like half a chrome tab
06:16:39*sagax joined #nim
06:16:43FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=421h
06:17:20FromDiscord<Elegantbeef> It atleast works with my phone, doesnt seem to work with my steam controller which is BLE
06:24:16FromDiscord<ripluke> sent a code paste, see https://play.nim-lang.org/#ix=421i
06:25:10FromDiscord<ripluke> How can I split a string for every line?
06:26:21FromDiscord<Elegantbeef> `splitLines`
06:28:34NimEventerNew post on r/nim by treeform: Discussing Nim 2.0 - Its already here [video]., see https://reddit.com/r/nim/comments/vuvg5t/discussing_nim_20_its_already_here_video/
06:29:36FromDiscord<ripluke> sent a code paste, see https://play.nim-lang.org/#ix=421k
06:29:42FromDiscord<ripluke> what am i doing wrong with this code
06:30:27FromDiscord<ripluke> sent a code paste, see https://play.nim-lang.org/#ix=421l
06:30:46FromDiscord<ripluke> no error when compiling tho
06:30:49FromDiscord<ripluke> (edit) "https://play.nim-lang.org/#ix=421m" => "https://paste.rs/YIt"
06:31:53FromDiscord<Elegantbeef> It's a runtime error it says the issue is on line 9
06:32:11FromDiscord<Elegantbeef> Where do you index on line 9
06:33:15FromDiscord<ripluke> im splitting the device string
06:33:36FromDiscord<Elegantbeef> You then index it
06:34:18FromDiscord<ripluke> hmm i think the split isnt working
06:34:25FromDiscord<Elegantbeef> ...
06:35:06FromDiscord<ripluke> i wonder why tho
06:35:22FromDiscord<ripluke> there are many spaces in the command output
06:35:35FromDiscord<Elegantbeef> If only there was a better way
06:35:41FromDiscord<Elegantbeef> `std/strscans`
06:35:49FromDiscord<ripluke> oh
06:36:35FromDiscord<ripluke> its quite confusing
06:36:47FromDiscord<Elegantbeef> It's like regex but for sane people
06:36:51FromDiscord<Elegantbeef> What's the string you have?
06:37:36FromDiscord<ripluke> Device 70:EA:41:69:FC:A7 Jabra Elite 75t
06:38:18FromDiscord<Elegantbeef> `line.scanf("Device $s$.", myId)`
06:38:36FromDiscord<ripluke> ah so then it returns s right?
06:39:02FromDiscord<Elegantbeef> That should be uhh `$+$s$.` and it returns a bool
06:39:08FromDiscord<Elegantbeef> There are docs you know
06:39:26FromDiscord<Elegantbeef> It writes the captured id to `myId`
06:40:01FromDiscord<ripluke> oh
06:41:51FromDiscord<Prestige> Elegantbeef I didn't see if you answered about the wayland compositor, I think we should work on one together
06:41:56FromDiscord<Prestige> If you're inclined
06:42:07FromDiscord<Elegantbeef> I am but we need wlroots and libwayland wrapped
06:42:13FromDiscord<Elegantbeef> futhark screwed the pooch on that one
06:42:20FromDiscord<ripluke> In reply to @Elegantbeef "It writes the captured": it did an awesome job 😃 ↵@["", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""]
06:42:46FromDiscord<Prestige> hmm are those C libraries?
06:42:49FromDiscord<ripluke> time to rtfm
06:42:58FromDiscord<Prestige> Could try to manually wrap them I suppose
06:43:00FromDiscord<Elegantbeef> Yes those are C libraries
06:43:07FromDiscord<Elegantbeef> I mean j-james has wlroots wrapped
06:43:14FromDiscord<Prestige> oh
06:43:19FromDiscord<Elegantbeef> libwayland isnt yet we talked about it in offtopic earlier today
06:43:34FromDiscord<Elegantbeef> Also for your matrix woes checkout the cinny matrix client
06:44:05FromDiscord<Prestige> hm that looks a lot better
06:44:57FromDiscord<Prestige> Futhark fails to wrap libwayland, have you talked to pmunch about it?
06:45:33FromDiscord<Elegantbeef> Nah he's on vaca
06:46:16FromDiscord<Elegantbeef> Seems you can just do `"Device $+ "`
06:46:30FromDiscord<Elegantbeef> Well it does wrap both libraries but they're written in some horrid code
06:46:50FromDiscord<Prestige> interesting
06:47:15FromDiscord<Avahe> This matrix client is pretty nice
06:48:16FromDiscord<ripluke> In reply to @Elegantbeef "Seems you can just": ah yes thats good
07:14:38FromDiscord<tylerlinuxdev> Would be nice if they introduce C language library for Matrix chat.
07:15:36FromDiscord<tylerlinuxdev> That would help accelerate the usability of Matrix chat by a lot by making it so just about every programming language could bind to it and then everyone could create their own Matrix Client or bot.
07:17:38FromDiscord<tylerlinuxdev> Would be nice to have native chat, well I guess Thunderbird counts as one on version 102
07:38:02FromDiscord<d4rckh> im making some sort of http redirector/proxy (https://github.com/d4rckh/http-redirector). i have an issue where sometimes some requests to the website i want to proxy not get resolved
07:38:09FromDiscord<d4rckh> https://media.discordapp.net/attachments/371759389889003532/995232374147272835/unknown.png
07:38:56FromDiscord<d4rckh> and the original request wont resolve too, because i am not getting the response from example.org https://media.discordapp.net/attachments/371759389889003532/995232572579782656/unknown.png
07:39:09FromDiscord<d4rckh> this will load forever
07:40:46FromDiscord<d4rckh> this only happens 1/3 of the time
07:44:40FromDiscord<Elegantbeef> I'm not overly proficient but it's mostly just web requests and encryption
07:45:25FromDiscord<tylerlinuxdev> It's a bit more involved than that especially on the cryptography aspect.
07:45:47FromDiscord<tylerlinuxdev> As programming goes, cryptography is the most difficult to get right.
07:46:10FromDiscord<Elegantbeef> I do want to eventually make my own matrix client but ugh the list of things is larger
07:46:38FromDiscord<Elegantbeef> Avahe are you using the web or desktop client?
07:46:53FromDiscord<Elegantbeef> Atleast i assume you're still on matrix
07:47:15FromDiscord<tylerlinuxdev> Going to try opening up thunderbird 102 to see how it goes
07:48:19*ggsx joined #nim
07:48:55FromDiscord<Prestige> In reply to @Elegantbeef "Avahe are you using": I was using the desktop client
07:49:09FromDiscord<Elegantbeef> Ah it's not electron based if you didnt see
07:49:14FromDiscord<Prestige> I hate that the ui completely locks up if it is loading messages though
07:49:29FromDiscord<Prestige> element does it too
07:49:36FromDiscord<tylerlinuxdev> Yeah, sometime element have a problem with the mouse flickering and UI freezing up
07:49:43FromDiscord<tylerlinuxdev> I had to kill it and restart it
07:50:07FromDiscord<Elegantbeef> Maybe one day a client will be made that i dont mind contributing to šŸ˜€
07:52:24FromDiscord<tylerlinuxdev> If I finish STL-C, I could look into C++ implementation of Matrix chat and see if I can transpose it
07:52:45FromDiscord<tylerlinuxdev> (STL-C is basically C++ STL ported to C with support for both Thread-safe data container and non-thread safe IE concurrentqueue and whatnot.)
07:53:55FromDiscord<tylerlinuxdev> Just tried Thunderbird Beta for Matrix Chat, it works, but pretty... slow... just UI freezing up a lot when you switch chat.
07:54:13FromDiscord<Prestige> Elegantbeef even if we did it in Nim, I don't know what UI framework I would like to use
07:54:17FromDiscord<tylerlinuxdev> And the conversation list is unorganized
07:54:21FromDiscord<Prestige> I hear bad things about all of them, lol
07:54:52FromDiscord<Elegantbeef> Gtk is what i'm partial t o
07:55:09FromDiscord<d4rckh> In reply to @d4rckh "this only happens 1/3": looks like it gets stuck at `await response.body`
07:55:09FromDiscord<tylerlinuxdev> @Prestige\: Lol, funny thing I was working on creating new GUI Toolkit to replace GTK and QT, basically C library that uses Vulkan acceleration by default
07:55:21FromDiscord<Elegantbeef> Or wxwidgets
07:55:28FromDiscord<Elegantbeef> The down side is that it's not "fancy"
07:55:42FromDiscord<Prestige> I know/knew a guy that was working on his own UI framework but I haven't spoken to him in a while. Called neogfx
07:55:51FromDiscord<Prestige> https://neogfx.org/
07:55:55FromDiscord<Prestige> but it's c++ so I'll disregard it
07:57:11FromDiscord<tylerlinuxdev> Ah, basically I originally try to work on replacing Wayland entirely, but realized that it's a massive PITA if I have to fight with QT and GTK to add support for new replacement for Wayland
07:57:14FromDiscord<Elegantbeef> GUI is just shit in general
07:57:42FromDiscord<tylerlinuxdev> So it basically become the chicken and the egg problem
07:57:55FromDiscord<tylerlinuxdev> You need GUI Toolkit first to have something to work with on your new replacement for X11 and Wayland
07:58:32FromDiscord<tylerlinuxdev> Funny thing is... Wayland whined about how they can't get Nvidia GPU to work
07:58:33FromDiscord<tylerlinuxdev> I was able to
07:58:53FromDiscord<Prestige> šŸ¤”
07:59:43FromDiscord<Prestige> So my smart light switch is able to be controlled by wifi, but it's not open source it seems. I found a python library that can control it, but is super buggy and half the commands don't work
08:00:19FromDiscord<Prestige> Been trying to copy the very basic command to send a request for the status of the switch but I think I'm misinterpreting what the python code is doing. I hate python
08:01:12FromDiscord<tylerlinuxdev> [Elegantbeef](https://matrix.to/#/@elegantbeef:matrix.org)\: Because they keep repeating the same mistake of trying to force GUI to fit within a tiny box that doesn't offer any flexibility or creativity and because they often don't write the GUI Toolkit library in C in the first place basically limiting the library to be ONLY be usable in the language it's written in like QT.
08:01:28FromDiscord<tylerlinuxdev> (I can almost guaranteed that you'll never see C binding for QT that is complete.)
08:02:12FromDiscord<tylerlinuxdev> [Edit](https://discord.com/channels/371759389889003530/371759389889003532/995238178086727704): [Elegantbeef](https://matrix.to/#/@elegantbeef:matrix.org)\: Because they keep repeating the same mistake of trying to force GUI to fit within a tiny box that doesn't offer any flexibility or creativity and because they often don't write the GUI Toolkit library in C in the first place basically limiting the library to ONLY be usable in t
08:03:11FromDiscord<Elegantbeef> Well yea
08:03:29FromDiscord<Elegantbeef> QT is really unusable outside of C++, which is why it's not overly attractive
08:03:42FromDiscord<Elegantbeef> i mean QML and it's designer does exist
08:03:50FromDiscord<tylerlinuxdev> Yeah, but extensibility is gone
08:04:08FromDiscord<Elegantbeef> GTK is just more attractive as it can be used 1\:1 as it's source language if you really need to
08:04:24FromDiscord<Elegantbeef> It's not really writing it in C in the first place it's that it's as usable as the source
08:04:50FromDiscord<tylerlinuxdev> The biggest problem with GTK is how they break ABI regularly, I maintain a database of all libraries symbols, GTK top that list.
08:05:33FromDiscord<tylerlinuxdev> (Basically `objdump -T` all of the libraries and parse it into PostgreSQL for any changed symbols and have that script hooked into pacman install hook)
08:07:27*ggsx quit (Quit: Client closed)
08:07:40*ggsx joined #nim
08:08:47FromDiscord<Elegantbeef> But but it runs the web \:P↵(@Prestige)
08:09:09FromDiscord<tylerlinuxdev> It honestly not a surprise that we're seeing new apps for Linux just in a web browser, because they just go, "Ah F\\\ it"
08:09:32FromDiscord<Prestige> Python runs the web? eh
08:09:39FromDiscord<Elegantbeef> Well it's down to that web apps are relatively painless cross platform and allow nice looking gui
08:09:40FromDiscord<Prestige> I still think it's a crap language
08:09:52FromDiscord<Elegantbeef> It can but i'm just joking
08:10:04FromDiscord<Phil> Even if gtk was the most convenient toolkit on the planet, pwa and electron would still win
08:10:06FromDiscord<Elegantbeef> Nice looking gtk on windows is a feat afaik
08:10:20FromDiscord<Phil> Basically no effort is hard to beat
08:10:38FromDiscord<Elegantbeef> Yea but luckily we're talking about making our client
08:10:44FromDiscord<Elegantbeef> So we can say "fuck you mr. web man"
08:11:23FromDiscord<tylerlinuxdev> Only that you have to stick with javascript which sucks for electron, you might squeak by with webasm, but I don't think it support DOM manipulation yet... after decade...
08:11:38FromDiscord<Phil> Fair. I was playing around with the idea of a Linux native matrix client. But the feature set would be so much effort
08:11:44FromDiscord<Elegantbeef> I think gtk is nice if you have a decalrative GUI, though i havent played with glad + gintro
08:11:55FromDiscord<Phil> In reply to @tylerlinuxdev "Only that you have": Angular makes it pretty ready
08:11:59FromDiscord<Phil> Easy
08:12:05*matt_13377 quit (Ping timeout: 255 seconds)
08:12:08FromDiscord<Elegantbeef> I mean there are a group of us here that are interested in a matrix client
08:12:19FromDiscord<Elegantbeef> Enthus, Prestige, Me, You, ....
08:12:20FromDiscord<tylerlinuxdev> Isn't Angular a dead framework?
08:12:34FromDiscord<Phil> Not really
08:12:43FromDiscord<tylerlinuxdev> image.png https://media.discordapp.net/attachments/371759389889003532/995241077353234442/image.png
08:12:45FromDiscord<tylerlinuxdev> https://killedbygoogle.com/
08:13:03FromDiscord<Phil> Angularjs is the first iteration
08:13:08FromDiscord<tylerlinuxdev> Ah
08:13:28FromDiscord<Prestige> I'd rather work on a wayland compositor tbh Elegantbeef
08:13:32FromDiscord<Phil> That is dead, yes, that's also the reason why angularjs and angular are 2 very different things
08:14:01FromDiscord<tylerlinuxdev> Haven't kept up with web dev in a while, I quit programming professionally and switch career to IT admin with RHCA certification basically
08:14:02FromDiscord<Elegantbeef> I mean same prestige
08:14:02FromDiscord<Elegantbeef> But there is some desire so hey it's not hard to imagine more would contribute
08:14:06FromDiscord<Phil> The API changes between versions were so drastic that they basically said to start from scratch
08:15:05FromDiscord<Phil> It's why react has such a much larger market share. The companies that bought into angularjs at the start haven't been that forgiving
08:16:02FromDiscord<tylerlinuxdev> Yeah, just oof... thanks god I am out of Webdev
08:16:17FromDiscord<Phil> It's been solid since though and that was like 7 years ago or sth. Very stable and complete every since and a very different approach to react
08:17:34FromDiscord<Phil> It's fairly good through enforced usage of rxjs and typescript.↵The routing it uses, like all other front-end routing I've seen so far, is batshit insane though
08:18:32FromDiscord<Phil> Django did it right and sane. No idea what the guys that settled on the routing paradigms where smoking
08:18:52FromDiscord<tylerlinuxdev> I looked over Reactjs, apparently it still require hundred of dependencies.
08:19:49FromDiscord<Phil> Never worked with react, glanced over some routing examples and saw the same stuff that made me cringe in angular
08:20:15FromDiscord<tylerlinuxdev> Yeah, honestly just happy not to deal with web anymore... wow
08:20:22*matt_13377 joined #nim
08:21:24FromDiscord<Prestige> I've used react a lot for work, it's.. not great
08:21:33FromDiscord<Prestige> but maybe the "best" js front end framework we have
08:22:07FromDiscord<Prestige> Typescript makes js almost bearable
08:22:13FromDiscord<tylerlinuxdev> Back then, i just do Bootstrap + JQuery, because I don't want to bother dealing with 1000+ javascript modules
08:22:17FromDiscord<Phil> I think it's fine. I would need to write a gui with gtk etc. To compare but what I've seen seems somewhat more difficult to work with.↵Though chances are that's me being used to typescript and rxjs
08:22:54FromDiscord<Phil> I wayyyy preferred angular for choice precisely because it is opinionated
08:23:32FromDiscord<Prestige> Isn't treeform working on Fidget 2?
08:23:40FromDiscord<Phil> Enforced typescript and rxjs, routing out of the box, enforced project structure, pre supplied ways of defining service workers etc
08:23:42FromDiscord<Prestige> or was that some weird fever dream I had
08:25:59FromDiscord<tylerlinuxdev> It's a bit interesting that Electron takes about 68 MB at min whereas my GUI Toolkit for the same thing uses about 4 MB at most
08:26:17FromDiscord<Prestige> interesting is a good word for it
08:30:30FromDiscord<xflywind> There is tauri aiming to replace electron which planned Nim backend.
08:30:32FromDiscord<xflywind> https://media.discordapp.net/attachments/371759389889003532/995245560103698432/unknown.png
08:31:00FromDiscord<Prestige> Sounds interesting
08:35:13FromDiscord<untoreh> sent a code paste, see https://play.nim-lang.org/#ix=421C
08:36:06FromDiscord<xflywind> unique id for each symbol
08:36:26FromDiscord<tylerlinuxdev> Yeah, that mangled name for symbol in C++
08:38:57FromDiscord<tylerlinuxdev> And it sometime used to uniquely version the library API
08:40:38*kenran joined #nim
08:51:00FromDiscord<d4rckh> how do i convert an Uri object to an actual string i can plug in an url?
08:51:20FromDiscord<d4rckh> `fmt"https://example.org{magicFunction(myUri)}"`
09:01:27*kenran quit (Quit: WeeChat info:version)
09:09:24FromDiscord<tylerlinuxdev> `combine(parseUri("https://example.org"), magicFunction(myUri))` is how you usually do it and you can treat uri object as a string
09:09:44FromDiscord<tylerlinuxdev> image.png https://media.discordapp.net/attachments/371759389889003532/995255422674018375/image.png
09:09:57FromDiscord<Elegantbeef> He is↵(@Prestige)
09:10:08FromDiscord<Elegantbeef> Turns out making GUI is a very very slow process
09:10:27FromDiscord<tylerlinuxdev> Yup
09:10:35FromDiscord<Prestige> Very tedious
09:10:36FromDiscord<tylerlinuxdev> If you can cheat or save time, use all of them
09:11:01FromDiscord<Elegantbeef> But i mean fidget/nimx are also both options
09:11:17FromDiscord<Elegantbeef> If we're still talking about a hypothetical nim matrix client
09:12:03FromDiscord<tylerlinuxdev> Yeah
09:12:28*ggsx quit (Ping timeout: 252 seconds)
09:13:01FromDiscord<Prestige> Yep
09:13:05FromDiscord<Elegantbeef> Fidget can hit a nice medium of good looking gui and sane render pipeline
09:13:06FromDiscord<Prestige> I'd much rather do it all in Nim
09:13:45madpropsi saw there's an orm now
09:13:59madpropshttps://github.com/moigagoo/norm
09:13:59FromDiscord<Elegantbeef> Say what you will about web tech but clients written in GTK/QT dont look great
09:15:19madpropsi made this in python using a tk library https://i.imgur.com/6G3HGYb.jpg
09:15:48madpropslibrary is very limited though
09:15:55madpropscan't add/remove widgets dynamically
09:16:03madpropsyou're supposed to redraw the whole thing again
09:16:08madpropsit's a known issue
09:17:50FromDiscord<tylerlinuxdev> sent a long message, see https://paste.rs/Vi6
09:18:10*hc0re quit (Ping timeout: 240 seconds)
09:18:12FromDiscord<tylerlinuxdev> What I try to differentiate on is doing it in vulkan
09:18:24FromDiscord<Elegantbeef> Yea and i mean fidget does tick some of those boxes
09:18:32FromDiscord<tylerlinuxdev> Yeah
09:20:02FromDiscord<tylerlinuxdev> Like "XDrawLine"
09:20:49FromDiscord<tylerlinuxdev> (GTK uses Cairo for rendering, similar, but better optimized than X11)
09:25:43FromDiscord<tylerlinuxdev> The problem with CPU based rendering is basically that CPU sucks at that kind of job by raising CPU utilization and thus more electricity/heat being generated. It limit the ability of GUI Toolkit to enable animation, that largely why Web Browsers like Chrome use Skia that utilize GPU.
09:27:10FromDiscord<tylerlinuxdev> sent a long message, see http://ix.io/421T
09:28:10FromDiscord<Elegantbeef> I mean Pixie was written in Nim but you can use it from python/C/... \:D
09:28:54FromDiscord<tylerlinuxdev> Interesting
09:29:06FromDiscord<tylerlinuxdev> Rely on OpenGL however
09:29:19FromDiscord<tylerlinuxdev> The problem falls into OpenGL territory where each driver can have different results in how it looks
09:29:34FromDiscord<tylerlinuxdev> That why I opted for Vulkan, so the looks is consistent across all platforms
09:29:53FromDiscord<Elegantbeef> Pixie is a skia like library
09:30:04FromDiscord<tylerlinuxdev> Pixie utilize Boxy which uses OpenGL
09:30:05FromDiscord<Elegantbeef> Pixie is a cpu drawing library
09:30:11FromDiscord<tylerlinuxdev> image.png https://media.discordapp.net/attachments/371759389889003532/995260566333571112/image.png
09:30:18FromDiscord<Elegantbeef> "on top of"
09:30:23FromDiscord<Elegantbeef> Reading before speaking is a virtue
09:30:33FromDiscord<Elegantbeef> Pixie is a standalone drawing library
09:30:35FromDiscord<tylerlinuxdev> I'm tired and it's literally 3\:32 AM here
09:30:41FromDiscord<Elegantbeef> No it's that time here
09:30:51FromDiscord<tylerlinuxdev> ?
09:30:57FromDiscord<Elegantbeef> We're in the same timezone
09:30:59FromDiscord<tylerlinuxdev> Ah
09:31:28FromDiscord<Elegantbeef> Fidget does use opengl though
09:31:40FromDiscord<Elegantbeef> But we were not talking about that there
09:35:15FromDiscord<Elegantbeef> Suffice to say there arent amazing GUI solutions in Native Nim or as libraries
09:35:34FromDiscord<tylerlinuxdev> Yeah, Fidget seems pretty bareback and looks to be a starting point
09:35:43FromDiscord<tylerlinuxdev> I'm looking over code
09:36:16FromDiscord<Elegantbeef> Well have fun i'm going to sleep
09:36:22FromDiscord<tylerlinuxdev> Good night
10:02:24*jmdaemon quit (Ping timeout: 276 seconds)
10:11:19*hc0re joined #nim
10:27:37*pro joined #nim
10:37:28*pro quit (Quit: pro)
10:45:42FromDiscord<Phil> In reply to @madprops "https://github.com/moigagoo/norm": It's alright. I use it in my project, though I have an abstraction layer on top of it since I don't fully agree with a design choice in there
10:45:54FromDiscord<Phil> I guess I should also disclaim that I contribute to it
10:46:09FromDiscord<Phil> (edit) "In reply to @madprops "https://github.com/moigagoo/norm": It's alright. I use it in my project, though I have an abstraction layer on top of it since I don't fully agree with a design choice in there ... " added "about how the API looks"
10:46:43FromDiscord<Phil> In reply to @Elegantbeef "Say what you will": I wonder in terms of effort which is easier to work with
10:47:30FromDiscord<Phil> Not even meant sarcastically, I hear that web is comparatively trivial, but I've got no experience to back that up
10:52:13FromDiscord<tylerlinuxdev> Probably QT if you're going for native rather than web, you could largely get away with it by using QT Designer program and design your GUI and then add some C-language declaration for getter/setter functions for various items in your GUI and then you route the events over a list of function pointers that C language side have to initialize GUI with by providing it's own list of functions that would process the events.
10:52:46FromDiscord<tylerlinuxdev> But yeah, as far as difficulty goes, web is still easier than doing it in GTK and QT which is why it remains popular on Linux
10:55:11FromDiscord<Phil> Given that the JS engine isn't even all that slow compared to native, I'm not surprised then
10:56:45madpropsi don't fully agree
10:56:59FromDiscord<dom96> I can only speak to GTK when I say: stay away. Honestly Electron/CEF is fast enough for 99% of people and if I were to ever create a GUI app I would use either of those.
10:57:01madpropsunless you have a js library with pre-made widgets ready to use
10:57:36madpropselectron is pretty bad though
10:57:37FromDiscord<dom96> Also the fact that React Native is a thing and is so popular speaks volumes for the web's versatility.
10:57:39FromDiscord<Phil> CEF?
10:57:42FromDiscord<Prestige> Really sad to hear because of how slow and resource heavy electron is
10:57:56FromDiscord<dom96> In reply to @Isofruit "CEF?": https://github.com/chromiumembedded/cef
10:58:36FromDiscord<Prestige> I thought react native actually uses native rendering
10:58:56FromDiscord<dom96> In reply to @Avahe "Really sad to hear": it's not too bad https://media.discordapp.net/attachments/371759389889003532/995282901455347753/unknown.png
10:59:12FromDiscord<Rika> That looks pretty bad given what discord does
10:59:28FromDiscord<Prestige> Agreed
10:59:59FromDiscord<dom96> and yet it's only 1.5% of my total RAM
11:00:01FromDiscord<Prestige> Slow programs and websites have become normalized, it's sad
11:00:19FromDiscord<dom96> In reply to @Avahe "I thought react native": depends what you mean by "native rendering"
11:00:40FromDiscord<Prestige> sent a code paste, see https://play.nim-lang.org/#ix=422e
11:00:48FromDiscord<dom96> there is still a JS engine in there
11:02:03FromDiscord<dom96> but yeah, I suppose at least it's not relying on webkit
11:02:42FromDiscord<Prestige> I think the rendering side of things is usually the problem when people complain about js
11:03:47FromDiscord<Prestige> My current company's code base has a ton of redundant/unnecessary things the code does, shit is slow. Makes using our web app a pain
11:04:12FromDiscord<Prestige> But that seems to have become the norm since we have so much RAM
11:04:36FromDiscord<Prestige> Nobody profiles js
11:05:47FromDiscord<dom96> That's not true
11:06:17FromDiscord<dom96> The majority likely doesn't care about performance so they don't profile
11:06:29FromDiscord<dom96> but JS has some of the best tools for profiling it too
11:06:58FromDiscord<enthus1ast> i profile by using old af hardware
11:07:19FromDiscord<Prestige> Yeah it has great tooling, my point is just that people don't usually bother profiling web apps
11:07:21FromDiscord<Phil> I can see the point of insisting on native. Even in the best cases, JS engines are still factor 2-3 slower than C (though significantly faster than python ironically)
11:07:33FromDiscord<Phil> And that translates into battery life, which users do care about
11:07:59FromDiscord<Phil> Particularly since most computation devices in use by end users are battery powered nowadays
11:08:23FromDiscord<Phil> But the fact that the tooling for using native is anywhere near as attractive in terms of productivity is... painful
11:09:07FromDiscord<dom96> I'd like to see some data on energy usage of a native app vs. Electron.
11:09:09FromDiscord<Prestige> Through profiling I found out our nodejs server spends more than half it's runtime calling a lodash function that translates snake case to camel case. Quite funny
11:09:26FromDiscord<dom96> Without data it's all speculation whether it's worth putting up with the pain of native
11:10:09FromDiscord<Prestige> You'd really have create two apps with the same design/features but yeah
11:10:30FromDiscord<Prestige> It the very least I think it's safe wo to assume ram usage would be lower
11:10:36FromDiscord<Prestige> (edit) removed "wo"
11:11:16FromDiscord<Prestige> Typing on touch screens is such a PITA
11:30:04*hc0re quit (Ping timeout: 244 seconds)
11:39:11FromDiscord<Rika> In reply to @Elegantbeef "This reminds me https://erikmcclure.com/blog/window": I was wondering why I recognised that name
11:39:53FromDiscord<Rika> He made that discord bot with the interesting anti spam (in the sense of actual ā€œspammingā€ and not unwanted messages)
12:03:14FromDiscord<Phil> > LLVM was built for Linux - or rather, it was built to work for Mac OSX, which is POSIX compliant and looks like a Linux system if you squint↵Beef did promise it was fun
12:03:41FromDiscord<Phil> Thanks for replying to that message Rika! I would have missed that article otherwise
12:07:34FromDiscord<Phil> > So this entire time I've been trying to replace Microsoft's malloc() with Microsoft's other malloc() because Microsoft's malloc() was too slow for Microsoft. ↵Hooo boy
12:07:53FromDiscord<Phil> I can't claim I understand 100%, but it most certainly is entertaining
12:26:23FromDiscord<retkid> so Channels are blocking and never returning
12:26:54FromDiscord<retkid> well, receiving
12:26:58FromDiscord<retkid> i forgot how to fix this
13:20:48FromDiscord<retkid> In reply to @Elegantbeef "This reminds me https://erikmcclure.com/blog/window": in recent news: ↵windows is bad↵up next:↵Most cats don't like baths
13:22:56FromDiscord<enthus1ast> Windows might be bad, but it's the best when you just want to get things working
13:23:41FromDiscord<retkid> when you're not programming for it
13:23:52FromDiscord<retkid> the "its just works" is built upon the backs of dead programmers
13:23:53FromDiscord<enthus1ast> How many hours did I fight linux when I want to get older (scientific) software working... its ridiculous
13:24:12FromDiscord<retkid> ha
13:24:16FromDiscord<retkid> yea
13:24:29FromDiscord<retkid> best solution is get a ubuntu from just before the last release
13:24:56FromDiscord<retkid> then strace it and find all the api calls
13:25:25FromDiscord<enthus1ast> Linux has a massive compatibility issue with their software
13:25:28FromDiscord<retkid> steal the libraries and package them together
13:25:53FromDiscord<retkid> the linux ethos currently assumes you either package your libs with the software or you are updating it
13:26:06FromDiscord<retkid> or people are keeping old functions
13:26:09FromDiscord<enthus1ast> Have a app that needs older tcl/tk? You basically fucked
13:26:40FromDiscord<retkid> good thing about nim is its pretty portable
13:26:52FromDiscord<retkid> static packaging of depends
13:27:18FromDiscord<enthus1ast> So Like windows does it? 😁
13:28:00FromDiscord<retkid> no
13:28:04FromDiscord<retkid> windows has dynamic libs
13:28:06FromDiscord<retkid> floating around
13:28:15FromDiscord<retkid> they also have issues
13:28:30FromDiscord<retkid> its just, it has a central authority to make sure things work
13:28:41FromDiscord<retkid> linux supposes "eh they're smart enough to figure it out"
13:37:35FromDiscord<TryAngle> what are good alternatives from Rust's Mutex and Arc for Nim?
13:37:54FromDiscord<TryAngle> just losing locks and DIY?
13:40:44FromDiscord<Josef> Is it possible to define offsets of fields of Nim type?
13:41:05FromDiscord<Josef> (edit) "Is it possible to define ... offsets" added "byte"
13:41:12FromDiscord<enthus1ast> Don't get me wrong I do not praise windows, but it's on top of my personal, "get things done, and do other stuff, like drinking" list↵(@retkid)
13:41:43FromDiscord<retkid> do both drinking and programming
13:41:53FromDiscord<retkid> its the only time im happy when i code
13:43:02FromDiscord<enthus1ast> 2. On this list is macos ( I hate it )↵3. A typewriter↵4...n\: bsd
13:44:18FromDiscord<enthus1ast> 3. Should be linux mhhh
13:45:04FromDiscord<retkid> >a typewriter\
13:45:04FromDiscord<retkid> (edit) "typewriter\" => "typewriter"
13:45:30FromDiscord<retkid> start writing your code on a typewriter and scan it in
13:53:40FromDiscord<enthus1ast> sent a long message, see http://ix.io/423a
13:55:09FromDiscord<enthus1ast> I should create an "enthus1ast daily rants" channel and not pollute the nim one
14:08:24FromDiscord<retkid> no i was just trying to remember what to n meant
14:08:29FromDiscord<retkid> i think its infinitum
14:10:11FromDiscord<retkid> do i need to stringify to write to a file with msgpack
14:10:47FromDiscord<retkid> i think its just pack as a var
14:11:00FromDiscord<retkid> yea
14:14:00FromDiscord<David> Hey is C2nim still the way to go for wrapping C code or is there a way to directly import C headers nowadays?
14:17:27FromDiscord<hotdog> In reply to @David "Hey is C2nim still": Check out futhark
14:17:48FromDiscord<hotdog> https://github.com/PMunch/futhark
14:19:06FromDiscord<David> Well this looks useful, thanks!
14:19:42FromDiscord<hotdog> No prob šŸ™‚
14:21:36FromDiscord<David> One more question, is there a commonly used library for making CLIs?
14:22:07FromDiscord<planetis> In reply to @TryAngle "what are good alternatives": std/locks and planetis-m/sync has some more
14:23:16FromDiscord<Yardanico> In reply to @David "One more question, is": cligen, argparse, docopt, etc
14:23:37FromDiscord<enthus1ast> Eg cligen , or tui like\: illwill
14:24:01FromDiscord<David> Thanks everyone!
14:24:07FromDiscord<planetis> In reply to @David "One more question, is": There are many but checkout illwill and nimwave
14:25:58FromDiscord<David> Hmm does discord support Threads like Matrix or Slack? I’m curious if the bots between the two support that functionality.
14:30:07*def- quit (Quit: -)
14:31:51FromDiscord<aru-hackZ> discord has threads yes
14:31:54FromDiscord<retkid> if I just... copy a variables memory and save it
14:32:04FromDiscord<retkid> can i cast it to that variable
14:33:23FromDiscord<retkid> or would i have to build a parser
14:35:40FromDiscord<hotdog> In reply to @retkid "can i cast it": If you mean cast to the type of the variable then yes
14:35:48FromDiscord<David> So if I start a thread in Matrix does it make a thread on your side?↵(@aru-hackZ)
14:36:34FromDiscord<retkid> In reply to @hotdog "If you mean cast": So i can be like "00FF00" (probably in character form) then just be like "Oh yea, thats an array" @hotdog
14:36:57FromDiscord<retkid> and if it checks out, it'll just do it
14:38:06FromDiscord<aru-hackZ> In reply to @David "So if I start": if the bridge supports it
14:38:18FromDiscord<hotdog> Pretty much as long as the format is correct else you’ll get errors when reading it back
14:38:26FromDiscord<hotdog> @retkid
14:38:32FromDiscord<hotdog> What are you trying to do?
14:38:39FromDiscord<retkid> then what is the function for this
14:38:40FromDiscord<aru-hackZ> also you need to have permissions to create a thread, which seems I don't have
14:39:03FromDiscord<retkid> In reply to @hotdog "What are you trying": trying to pack things quickly without care for file sizes
14:39:15FromDiscord<retkid> i just need more data throughput no matter the volume
14:39:38FromDiscord<retkid> while msgpack is pretty fast its just, still an extra 14 secs on a thread
14:39:54*arkurious joined #nim
14:40:03FromDiscord<Rika> In reply to @David "So if I start": the bridge doesnt support it
14:40:04FromDiscord<Rika> i believe
14:41:31FromDiscord<David> Hmm it most not, since I created a thread on my side and i can only guess it showed up as a normal message for you
14:44:23FromDiscord<aru-hackZ> not even that
14:47:47*def- joined #nim
15:01:00FromDiscord<TryAngle> In reply to @planetis "std/locks and planetis-m/sync has": RwLock looks good, can be used as a drop in replacement for mutexes right? I have no idea tbh
15:01:25FromDiscord<TryAngle> ah nvm mutex blocks on read too šŸ¤”
15:01:30FromDiscord<retkid> i probably cant do what i was imagineing
15:01:34FromDiscord<retkid> asd
15:01:38FromDiscord<retkid> (edit) "asd" => "sad"
15:02:12FromDiscord<planetis> In reply to @TryAngle "ah nvm mutex blocks": Mutex is just a lock
15:02:26FromDiscord<planetis> So use std/locks for that
15:02:34FromDiscord<retkid> maybe i can asm this
15:02:36FromDiscord<retkid> famous last words
15:02:48FromDiscord<TryAngle> In reply to @planetis "Mutex is just a": ah true šŸ¤” ↵but with lock u can implement Mutex and RwLock no?
15:03:17FromDiscord<planetis> Yeah
15:05:23FromDiscord<TryAngle> sent a code paste, see https://paste.rs/omk
15:07:04FromDiscord<TryAngle> idk tbh, I'm newbie to threading :c
15:07:17FromDiscord<Rika> arc isnt atomic
15:07:32FromDiscord<TryAngle> it's probably not needed in nim šŸ¤”
15:07:39FromDiscord<planetis> No that wouldn't work you need to share the counter
15:07:50FromDiscord<Rika> isnt that what nim does
15:08:43FromDiscord<planetis> there is threading/smartptrs
15:08:52FromDiscord<TryAngle> ah true count also has to be ref
15:08:55FromDiscord<planetis> Arc = SharedPte
15:09:01FromDiscord<planetis> (edit) "SharedPte" => "SharedPtr"
15:09:09FromDiscord<treeform> In reply to @ajusa "Has anyone used vmath's": I mainly added swizzling because GLSL has it. But now I use it all the time. 3d to 2d conversation, vec4 color conversations, normal to tangent, there are many uses.
15:16:09FromDiscord<Bloss> Is the current development version 1.8 or 2.0?
15:20:07FromDiscord<xflywind> The next big release is 2.0, 1.8 is probably skipped.
15:20:30FromDiscord<xflywind> (edit) "probably" => "most likely"
15:26:54FromDiscord<Bloss> Cool, there are some small fixes in the development branch that I might need, was just wondering if I should wait to use it, I'll just use it now
15:27:45FromDiscord<Prestige> Do we know if IC is planned for 2.0 still?
15:36:04FromDiscord<Bloss> I would assume so
15:37:47FromDiscord<Bloss> Normal big versions take upwards of 9 months to release, I would expect 2.0 to take even longer
15:39:01FromDiscord<ajusa> In reply to @treeform "I mainly added swizzling": Thanks for clarifying!
15:39:17FromDiscord<Bloss> 1.0 to 1.2 and 1.2 to 1.4 both took around 6 months, 1.4 to 1.6 took a full year
15:40:38FromDiscord<untoreh> is there a way to rewrite an iterator to use async functions inside it?
15:41:30FromDiscord<Rika> i dont understand what you intend
15:42:28FromDiscord<Luckayla> How big are the changes coming in 2.0?
15:42:39FromDiscord<Luckayla> Seems I entered the language at a weird time
15:43:06FromDiscord<untoreh> sent a code paste, see https://paste.rs/Mrp
15:45:21FromDiscord<Prestige> People have been discussing what they want to see come with 2.0 but I don't know what is actually planned
15:46:22FromDiscord<Rika> i dont think you can await in an iterator at all so
15:46:40FromDiscord<Rika> nim doesnt have async for
15:49:25FromDiscord<Prestige> Maybe you could rewrite it to use a template
15:50:46FromDiscord<xflywind> In reply to @Avahe "Do we know if": It is for 2.x or later
15:51:42FromDiscord<Prestige> Have been really looking forward to IC for better editor support
15:52:45FromDiscord<xflywind> In reply to @Luckayla "How big are the": defaults to threads, orc and improvements planned by https://github.com/nim-lang/RFCs/issues/437
15:56:18FromDiscord<laker31> sent a long message, see http://ix.io/423K
15:59:11FromDiscord<Prestige> I think you can set LD_LIBRARY_PATH to that directory
15:59:17FromDiscord<aru-hackZ> add this flags: `--dynlibOverride:SDL2 --passL:"/opt/homebrew/cellar/sdl2/2.0.22/lib"`
15:59:33FromDiscord<aru-hackZ> (edit) "--passL:"/opt/homebrew/cellar/sdl2/2.0.22/lib"`" => "--passL:"/opt/homebrew/cellar/sdl2/2.0.22/lib/libSDL2.dylib"`"
15:59:48FromDiscord<aru-hackZ> (edit) "this" => "these"
16:01:03FromDiscord<aru-hackZ> I also had a problem like that since I'm using NixOS and need to pass some library paths that way, works fine for me
16:02:33FromDiscord<aru-hackZ> https://nim-lang.org/docs/nimc.html#dynliboverride https://media.discordapp.net/attachments/371759389889003532/995359309250703442/unknown.png
16:12:14FromDiscord<laker31> Thanks! For some reason adding it to `LD_LIBRARY_PATH` does not work (and that env variable does not have any value to start with - is that normal?), but adding the `--dynlibOverride` flag did it!
16:32:19FromDiscord<aru-hackZ> yh I tried adding it to `LD_LIBRARY_PATH` and didn't work
16:36:27FromDiscord<Goel> sent a code paste, see https://play.nim-lang.org/#ix=423Y
17:52:14FromDiscord<Phil> I believe this might be because I haven't done much low level coding. So as I understand it you want to manipulate the array in a proc and have that change also apply to the array outside the proc? ↵↵I assume the actual array is very large which is why you don't want the array to be copied ?
17:53:06FromDiscord<Phil> (edit) "coding." => "coding, but I'm having troubles wrapping my head around this."
17:53:32FromDiscord<Phil> (edit) "I believe this might be because I haven't done much low level coding, but I'm having troubles wrapping my head around this. So as I understand it you want to manipulate the array in a proc and have that change also apply to the array outside the proc? ↵↵I assume the actual array is very large which is why you don't want the array to be copied ... ?" added "/ a manipulated version of the array to be returned by the proc"
18:04:40*krux02 quit (Remote host closed the connection)
18:23:35FromDiscord<Goel> Yes thats the reason i dont want/need to copy it. Anyway i can't came up with another alternative idea so i'll just use that way of using addr and then dereference
18:23:53FromDiscord<Goel> (edit) "thats" => "that's" | "reason i dont" => "reason. I don't"
18:24:31FromDiscord<huantian> You should use ref objects ondtrsd of address but you still need to deref
18:26:51*vicecea quit (Remote host closed the connection)
18:27:20*vicecea joined #nim
18:33:55*pro joined #nim
18:35:34FromDiscord<Phil> Can you actually do ref type arrays?
18:36:28FromDiscord<huantian> You should be able to
18:41:03FromDiscord<Goel> What do you mean "ref type arrays"? And how can i do it?
18:42:33FromDiscord<Phil> Ah, so are you aware of differences between ref types and value types?
18:44:03FromDiscord<fwsgonzo> I'm trying to figure out how to take in 2GB of [pointer, length] from C into Nim without copying data around
18:44:05FromDiscord<fwsgonzo> https://github.com/nim-lang/Nim/issues/8256
18:44:27FromDiscord<fwsgonzo> What is the status on this? Is the openArray approach realistic? does it give me access to the full language and standard library?
18:44:58FromDiscord<fwsgonzo> I basically need a std::span or std::string_view
18:49:16FromDiscord<Phil> In reply to @huantian "You should be able": So I figured out that "ref array" is a valid type. How to initialize that though is beyond me
18:58:25FromDiscord<huantian> `let something = new array[int, 4]` should work
18:58:52FromDiscord<huantian> (edit) "array[int, 4]`" => "array[4, int]`"
19:04:42FromDiscord<Phil> sent a code paste, see https://play.nim-lang.org/#ix=424s
19:05:04FromDiscord<Phil> In reply to @huantian "`let something = new": Yep, that did it. Swapped to a separate type though
19:22:14*pro quit (Quit: pro)
19:29:07FromDiscord<!Patitotective> sooo guys im trying to add asynchronous support for GET requests in downit (asynchronous downloads manager) but for some reason the response's body is incomplete↵https://github.com/Patitotective/downit/blob/devel/downit.nim#L180↵since `AsyncResponse.body` is of type `Future[string]` i have to check if that future is finishes as well, right?
19:29:42FromDiscord<!Patitotective> (run tests to see the problem https://github.com/Patitotective/downit/blob/devel/tests/test.nim)
19:31:04FromDiscord<huantian> uh are you using a different client for each asyncronous request?
19:31:12FromDiscord<!Patitotective> yes
19:31:51FromDiscord<Alea> Is there a guide to seriously optimizing nim programs?
19:32:09FromDiscord<!Patitotective> In reply to @huantian "uh are you using": is that dumb? should i use the same for all?
19:32:31FromDiscord<huantian> no don't use the same for all
19:34:23FromDiscord<!Patitotective> also i dont get why `AsyncResponse.body` is `Future[string]` instead of just `string`↵since you always get `Future[AsyncResponse]` shouldn't the request succeed as the body?
19:34:50FromDiscord<huantian> body is a string tho
19:34:55FromDiscord<huantian> https://media.discordapp.net/attachments/371759389889003532/995412756138311760/unknown.png
19:35:04FromDiscord<Alea> Oh I've seen this one before, they do it so you can get headers if something fails iirc?
19:35:25FromDiscord<!Patitotective> In reply to @huantian "": whaaat
19:35:27FromDiscord<dom96> the body is a stream so that you can read large bodies without putting it all into memory
19:35:46FromDiscord<huantian> well FutureStreams are string streams so aren't they all in memory anyways?
19:36:10FromDiscord<!Patitotective> In reply to @huantian "": someone updated↵last week it wasnt like that
19:36:21FromDiscord<dom96> @!Patitotective I would suggest writing a quick script to `getContent` the URL that's missing part of the body to rule out any httpclient bugs
19:37:47FromDiscord<dom96> In reply to @huantian "well FutureStreams are string": nope, the body is read in chunks and it should be possible for you to save it to a file in chunks for example
19:38:35FromDiscord<dom96> https://github.com/nim-lang/Nim/blob/version-1-6/lib/pure/httpclient.nim#L1280
19:38:41NimEventerNew post on r/nim by rotuami: Record type, see https://reddit.com/r/nim/comments/vv9c4g/record_type/
19:39:55FromDiscord<huantian> sent a code paste, see https://play.nim-lang.org/#ix=424z
19:41:06FromDiscord<!Patitotective> sent a code paste, see https://play.nim-lang.org/#ix=424A
19:41:44FromDiscord<dom96> In reply to @huantian "so if I do": yeah, it shouldn't. Though last time I used it there were bugs which meant that it did :)
19:41:53FromDiscord<!Patitotective> sent a code paste, see https://play.nim-lang.org/#ix=424B
19:42:23FromDiscord<huantian> In reply to @dom96 "yeah, it shouldn't. Though": why does http client use the weird stuff like setting client.bodyStream instead of reading the resp.bodyStream? is it because of said bugs?
19:42:26FromDiscord<!Patitotective> oh huan i just remembered↵`AsyncResponse.body` is not public so i gotta call the `body` proc that returns a future↵https://nim-lang.org/docs/httpclient.html#body%2CAsyncResponse
19:43:03FromDiscord<dom96> just `waitFor` it
19:43:35FromDiscord<!Patitotective> why does the response finishes earlier than the body? thats so weird
19:43:52FromDiscord<!Patitotective> oh, is it because it has to read the stream?
19:44:59FromDiscord<dom96> yep
19:45:31FromDiscord<dom96> In reply to @huantian "why does http client": not sure what you mean
19:45:55FromDiscord<Phil> ... I kinda wish we could use tauri in nim
19:46:19FromDiscord<Phil> playing around with it looks fun, but writing rust looks still painful
19:46:38FromDiscord<huantian> `httpclient.downloadFileEx`, isntead of simply doing what I sent, it seems to use `client.bodyStream` instead of `response.bodyStream`
19:46:39FromDiscord<!Patitotective> anyway dom↵im already checking if it finishes here https://github.com/Patitotective/downit/blob/devel/downit.nim#L180 (?)↵`data.requestFuture.read().body.finished`
19:47:44FromDiscord<dom96> In reply to @huantian "`httpclient.downloadFileEx`, isntead of simply": don't recall. Could just be a legacy thing
19:48:59FromDiscord<huantian> my thought was that it doesn't have to write the the response's stream, and can directly write to the file stream
19:49:20FromDiscord<huantian> but since you mentioned that there's no difference since it stays chunked anyways, I wasn't sure
19:50:00FromDiscord<dom96> In reply to @Patitotective "anyway dom im already": does doing it in a repro script get you the full body?
19:50:07FromDiscord<dom96> you still haven't answered that :)
19:51:01FromDiscord<!Patitotective> sent a code paste, see https://play.nim-lang.org/#ix=424E
19:54:32FromDiscord<dom96> hm, okay, so where do you actually read the body stream in your downit code?
19:55:10FromDiscord<!Patitotective> here https://github.com/Patitotective/downit/blob/devel/downit.nim#L105↵and im checking if it finished there as well
19:58:22FromDiscord<dom96> I don't see anything obviously wrong I'm afraid
19:58:52FromDiscord<!Patitotective> :/
19:59:21FromDiscord<dom96> Don't be afraid to insert `echo`'s into httpclient and see what's going on there
20:08:59FromDiscord<enthus1ast> Pdo as much as possible during compiletime, avoid allocations, avoid string split, branch as less as you could, compile with -d\:danger -d\:lto↵(@Alea)
20:09:35FromDiscord<enthus1ast> Benchmark with eg benchy
20:11:07FromDiscord<huantian> yes for string stuff you wanna use stuff like parseutils instead of splitting
20:33:34FromDiscord<kevin> @treeform got a question about `puppy`
20:33:59FromDiscord<kevin> It's very possible I just don't know what I'm doing but I submitted an issue on what I think is a bug in puppy
20:34:04FromDiscord<kevin> https://github.com/treeform/puppy/issues/76
20:44:49FromDiscord<treeform> In reply to @kevin "It's very possible I": It's not an issue we have run into. We will take a look.
20:45:11FromDiscord<treeform> Does this happen with arc?
20:45:42FromDiscord<kevin> I guess I have not tried alternate gc's. I am using whatever the default is (i think refc)
20:47:04FromDiscord<kevin> OK I just tried `--gc:arc` and it still has the same issue
21:10:12*hc0re joined #nim
21:11:39*hc0re quit (Remote host closed the connection)
21:18:32FromDiscord<treeform> ok
21:18:46FromDiscord<treeform> we will figure it out
21:40:32*ehmry quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
21:41:21*ehmry joined #nim
22:08:20*noeontheend joined #nim
23:12:20*jmdaemon joined #nim
23:28:10FromDiscord<ynfle> !eval echo 8 / 9
23:28:14NimBot0.8888888888888888
23:28:21FromDiscord<ynfle> Why doesn't it round?
23:28:38FromDiscord<Elegantbeef> What?
23:28:47FromDiscord<Elegantbeef> `8 / 9` is float division
23:28:57FromDiscord<Elegantbeef> `8 div 9` is euclidean division
23:44:43FromDiscord<ynfle> Shouldn't it be 0.8888888888888889?
23:46:27FromDiscord<Elegantbeef> Is it culling signfiicant digits or showing all digits inside the float?
23:47:17FromDiscord<huantian> I don't think when you do float math you round
23:47:18FromDiscord<huantian> always truncate
23:49:42FromDiscord<huantian> actually I have no idea how ieee 754 works I learn it then forget it a few seconds because it doesn't matter
23:49:52FromDiscord<ynfle> !eval echo 0.8888888888888888↵+ 0.00000000000000001
23:49:55NimBotCompile failed: /usercode/in.nim(1, 24) Error: invalid token: no whitespace between number and identifier
23:50:12FromDiscord<ynfle> !eval echo 0.8888888888888888↵+ 0.00000000000000001
23:50:14NimBotCompile failed: /usercode/in.nim(1, 24) Error: invalid token: no whitespace between number and identifier
23:50:33FromDiscord<ynfle> !eval echo 0.8888888888888888↵ + 0.00000000000000001
23:50:35NimBotCompile failed: /usercode/in.nim(1, 24) Error: invalid token: no whitespace between number and identifier
23:50:46FromDiscord<huantian> !eval echo 0.8888888888888888 + 0.00000000000000001
23:50:50NimBot0.8888888888888888
23:51:12FromDiscord<ynfle> In reply to @Elegantbeef "Is it culling signfiicant": Culling
23:51:29FromDiscord<huantian> In reply to @NimBot "0.8888888888888888": is this not to be expected?
23:51:59FromDiscord<ynfle> šŸ¤·ā€ā™‚ļø I'd assume not, but not sure
23:52:28FromDiscord<Elegantbeef> It's floats
23:53:00FromDiscord<Elegantbeef> https://play.nim-lang.org/#ix=42Dg
23:53:00FromDiscord<Elegantbeef> Turns out floating point impercision is real
23:53:08FromDiscord<Elegantbeef> If you care about the accuracy of numbers you dont use floats
23:53:52FromDiscord<ynfle> That's not what I did
23:53:59FromDiscord<ynfle> I added 1 on to the end
23:54:05FromDiscord<ynfle> Not to the last 8
23:54:26FromDiscord<huantian> maybe you should just use like <http://weitz.de/ieee/>
23:54:33FromDiscord<huantian> to visualize your calculations
23:55:06FromDiscord<ynfle> This has nothing to do with calculations, but with printing
23:55:54FromDiscord<Elegantbeef> Did you look at my code?
23:56:11FromDiscord<Elegantbeef> Your example doesnt exist as a floating point number
23:57:59FromDiscord<Elegantbeef> !eval echo 0.1f32 + 0.2f32
23:58:03NimBot0.300000011920929
23:58:25FromDiscord<Elegantbeef> Well shucks
23:58:43FromDiscord<Elegantbeef> Expect the printed float to be the value that is held and not the exact number you gave