<< 12-04-2023 >>

00:11:31FromDiscord<Elegantbeef> I think oddly it requires installing \nix overtop the windows partition 😛↵(@huantian)
00:12:02FromDiscord<huantian> oh yeah I compeltely forgot about that step
00:31:00FromDiscord<sOkam!> sent a code paste, see https://play.nim-lang.org/#ix=4tea
00:31:24FromDiscord<Elegantbeef> mangled you need to do `{.inject.}` or mark the block template as `{.dirty.}`
00:32:26FromDiscord<sOkam!> whats the difference between them?
00:33:55FromDiscord<huantian> inject only applies to one variable
00:33:59FromDiscord<huantian> dirty applies to all variables in the template
00:34:47FromDiscord<huantian> use inject normally, use dirty if you have a ton of variables and you want most of them to be injected
00:35:20FromDiscord<sOkam!> oh so inject goes in the variable, not the template
00:35:24FromDiscord<sOkam!> kk ty
00:50:20*lumo_e quit (Quit: Quit)
01:03:34*lucasta quit (Remote host closed the connection)
01:05:19*rockcavera quit (Remote host closed the connection)
01:06:42*rockcavera joined #nim
01:06:42*rockcavera quit (Changing host)
01:06:42*rockcavera joined #nim
01:09:41FromDiscord<Nerve> sent a long message, see http://ix.io/4tei
01:10:08FromDiscord<Nerve> (edit) "http://ix.io/4tei" => "http://ix.io/4tej"
01:10:46FromDiscord<Nerve> (edit) "http://ix.io/4tej" => "http://ix.io/4tek"
01:11:51FromDiscord<Nerve> (edit) "https://paste.rs/pVx" => "https://paste.rs/3f3"
01:12:50FromDiscord<Nerve> So, in effect, those `cstring` parameters are being converted into `char`, and the `cint` type being returned is either an `int` or `long int` depending on the platform.
01:13:15FromDiscord<Nerve> (edit) "either an `int`" => "a `short`, `int`," | "a `short`, `int`,or `long int` depending on the platform. ... " added "There are other things they can be."
01:13:17FromDiscord<Rika> uh oh he said the t word
01:13:34FromDiscord<Nerve> transpiled?
01:13:42FromDiscord<Rika> yah
01:13:44FromDiscord<Rika> (edit) "yah" => "yeah"
01:14:13FromDiscord<Nerve> I mean...I've read the generated C sources of my programs myself. Do people have that big of an issue with it?
01:14:47FromDiscord<Rika> well people say the argument is that transpiled implies the output is explicitly made to be readable
01:15:01FromDiscord<Nerve> That sounds like pedantic semantics
01:15:25FromDiscord<Rika> well we just want to avoid the negative impression the word gives
01:15:29FromDiscord<Rika> in reality, i mean
01:15:53FromDiscord<Nerve> I dunno, "transpile to C" is kind of a selling point, especially for companies like mine where we're plugging into a lot of existing C sources
01:16:05FromDiscord<Nerve> It quickly gets the compatibility point across
01:17:06FromDiscord<Rika> i mean i get it and i personally dont really mind the use of the word HAD it not had the effect of pushing a few people away because of their experience or impression
01:17:16FromDiscord<michaelb.eth> In reply to @Rika "well people say the": might depend on the lang/community, e.g. Babel JS would (maybe still does) produce inscrutable code but was commonly referred to as a transpiler
01:18:35*jmdaemon quit (Ping timeout: 248 seconds)
01:18:40FromDiscord<michaelb.eth> trying to remember when I first became aware of the term... I think it was back when CoffeeScript was gaining wide popularity
01:19:40FromDiscord<Nerve> So I guess we'd need a new term for languages that use lower-level high-level languages as a machine-parsable assembly. Uh...good luck with that, I'm not doing it.
01:20:24FromDiscord<Nerve> (edit) "assembly." => ""assembly"."
01:26:09FromDiscord<Elegantbeef> transpile is a very unclear term
01:26:13FromDiscord<Elegantbeef> Most people have different definitions
01:26:30FromDiscord<Elegantbeef> Also michael i hate you, i further thought about a general solution to that multi method
01:26:53FromDiscord<Rika> lol
01:26:53FromDiscord<michaelb.eth> In reply to @Elegantbeef "Also michael i hate": 😢
01:26:58FromDiscord<Rika> professional timewaster
01:27:08FromDiscord<Elegantbeef> Unpaid professional timewaster
01:28:15FromDiscord<Elegantbeef> Assuming you seen my solution i realised we can actually emit a `if (myParam is type(x)) or isConvertible(myParam, destType) ....` chains
01:28:32FromDiscord<Elegantbeef> whoops `type(x)` should be `destType`
01:28:48FromDiscord<Elegantbeef> To be fair rika i only thought of it whilst cleaning dishes, i didnt implement it
01:29:57FromDiscord<Elegantbeef> So i can say for quite some certainty if you wanted pluggable multi procs in Nim the macro isnt actually that complicated
01:33:16FromDiscord<michaelb.eth> In reply to @Elegantbeef "Assuming you seen my": very cool, I will take a look, just had a lot going on today and went to bed last night right after writing about multimethods
01:34:14FromDiscord<Elegantbeef> As i said lastnight the code i wrote was very specialised but the stuff i thought of today is actually quite general
01:36:28*jmdaemon joined #nim
01:39:39FromDiscord<michaelb.eth> In reply to @Elegantbeef "Most people have different": very true; back when I knew a lot less about software development, the way I explained the difference to myself was the "transpilation" meant you're generating source code in lang Y from source code in lang X, whereas if you're creating a binary then that's "compilation"↵↵but I met others who disagreed with that definition (even very strongly), and eventually stopped using
01:41:07FromDiscord<michaelb.eth> (edit) "creating" => "generating" | "generatinga binary ... then" added "from source code"
01:43:10FromDiscord<michaelb.eth> Transpile on wikipedia redirects to this: https://en.wikipedia.org/wiki/Source-to-source_compiler
01:45:08FromDiscord<michaelb.eth> (edit)
01:50:29FromDiscord<Elegantbeef> I mostly find it an inane point but meh
01:50:33FromDiscord<Elegantbeef> Especially talking about nim
01:51:41FromDiscord<michaelb.eth> In reply to @Elegantbeef "I mostly find it": agreed, it's a nothing burger
01:52:36FromDiscord<Elegantbeef> Well i think there is some importance when the backend is lua or js
01:52:36FromDiscord<Elegantbeef> But the backend is C so ...
01:54:30FromDiscord<michaelb.eth> In reply to @Elegantbeef "Well i think there": because there's a significant difference in what the target lang can/'t do?
01:54:50FromDiscord<michaelb.eth> e.g. in JS you can't open a native socket
01:55:11FromDiscord<michaelb.eth> (edit) "native socket" => "raw socket, that kind of thing?"
02:01:12FromDiscord<Elegantbeef> One can argue the same about C though so perhaps it's just cause of my disdain from non statically typed languages
02:10:55FromDiscord<Elegantbeef> It's quite odd though i've seen people act like transpilation means the language is a toy, as if compiling to LLVM IR is any less toyish 😄
02:46:57*arkurious quit (Quit: Leaving)
02:59:37*rockcavera quit (Read error: Connection reset by peer)
03:00:01*rockcavera joined #nim
03:42:56*nanxiao joined #nim
04:01:33*nanxiao quit (Quit: Client closed)
04:07:38NimEventerNew Nimble package! webgeolocation - Bindings to the Webgeolocation Web API, see https://github.com/maleyva1/webgeoloaction
04:35:08FromDiscord<Dudugz> For me transpiling is something like TypeScript does. You generate the AST of a language, transform it into the AST of the target language, and convert the AST back into code to execute. TypeScript is basically pure JS full of boilerplate.
04:36:44FromDiscord<Dudugz> PS: AST = Abstract Syntax Tree
04:50:50*nanxiao joined #nim
05:00:23NimEventerNew thread by andyroyes: Tcp buffer reuse for lower memory use, see https://forum.nim-lang.org/t/10092
05:19:19*cm_ joined #nim
05:19:22*cm quit (Ping timeout: 276 seconds)
05:19:41*cm_ is now known as cm
05:44:04FromDiscord<HitBlast> sent a code paste, see https://play.nim-lang.org/#ix=4tf1
05:45:01FromDiscord<Elegantbeef> make a config.nims with `-d:ssl`
05:49:57*kenran joined #nim
05:54:13*cm quit (Ping timeout: 250 seconds)
05:55:10*cm joined #nim
06:00:02FromDiscord<HitBlast> Could you give me an example of the structure? I'm not really familiar with config.nims at all.
06:00:29FromDiscord<Elegantbeef> create a config.nims at the root of your project and put in `--define:ssl`
06:03:17FromDiscord<ciwolsey> Would nim make a good alternative to Rust for when you dont want to deal with its borrow checker? Looking for something with a nice type system like Rust, but I don't always need to worry about allocations and such
06:03:28FromDiscord<Elegantbeef> Probably
06:03:47FromDiscord<Elegantbeef> Nim's Orc is pretty much RAII + a cycle collector so it's pretty much Rust+
06:05:06*rockcavera quit (Remote host closed the connection)
06:05:13FromDiscord<ciwolsey> Ah... I just found the memory model section in the documentation, so I'll give that a read, thanks
06:05:29FromDiscord<Elegantbeef> I'd argue Nim's macro and compile time evaluation is better than rust's, but I've only really heard about Rust's
06:05:41FromDiscord<Elegantbeef> I like me macros
06:07:55FromDiscord<Elegantbeef> Will say unlike Rust, you can just write data types and use them without any real regard to the underlying memory, unless you're really concerned about it
06:08:43FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=4tf4
06:10:57FromDiscord<ciwolsey> Right yeah.. that's what I'm looking for
06:12:43FromDiscord<HitBlast> In reply to @Elegantbeef "create a config.nims at": okay so then would I need to also flag it separately in the command line?
06:12:56FromDiscord<HitBlast> or just the config.nims is gonna work
06:13:13FromDiscord<HitBlast> (edit) "or ... justfile" added "is" | "is" => "file"
06:14:13FromDiscord<Elegantbeef> `config.nims` will be loaded when built
06:18:08FromDiscord<Arathanis> sent a code paste, see https://paste.rs/497
06:18:18FromDiscord<Arathanis> (edit) "https://play.nim-lang.org/#ix=4tf7" => "https://play.nim-lang.org/#ix=4tf6"
06:18:44FromDiscord<Elegantbeef> `--` is a template for that
06:18:50FromDiscord<Arathanis> brilliant
06:18:54FromDiscord<Arathanis> but also sneaky
06:19:33FromDiscord<Elegantbeef> Really makes reading configs nicer
06:22:48FromDiscord<HitBlast> well now it says this https://media.discordapp.net/attachments/371759389889003532/1095594849446670407/Screenshot_2023-04-12_at_12.22.26_PM.png
06:22:49FromDiscord<HitBlast> after building from GitHub Actions
06:23:07FromDiscord<Elegantbeef> You need to copy the perm files
06:23:15FromDiscord<Elegantbeef> pem ... whatever it is
06:23:57FromDiscord<HitBlast> ah well not sure how to do that since GitHub Actions is literally a headless environment
06:24:11FromDiscord<huantian> here's how i do it https://github.com/huantianad/levelsync/blob/2eadfc3a770cc6a493cd53c8ef7c544cc1dad8de/.github/workflows/main.yml#L13-L37
06:24:31FromDiscord<huantian> In my over complicated action
06:24:50FromDiscord<Elegantbeef> One day i'll setup a github action for something
06:28:03*nanxiao quit (Quit: Client closed)
06:33:57FromDiscord<ShalokShalom> @Elegantbeef#0000 This day, the Nim community will lose it's biggest contributor
06:34:08FromDiscord<ShalokShalom> Rest in peace 🕊️
06:34:44FromDiscord<Elegantbeef> Damn that's a threat and a half to someone
06:34:46FromDiscord<Elegantbeef> I'm not even overweight though
06:35:00FromDiscord<HitBlast> In reply to @huantian "here's how i do": Would it work if I add the `.pem` file to openssl using `openssl s_client -CAfile filename` then execute the build command?
06:35:09FromDiscord<ShalokShalom> (edit) "@Elegantbeef#0000" => "@ElegantBeef"
06:35:25FromDiscord<huantian> No idea
06:35:35FromDiscord<huantian> Maybe?
06:35:45FromDiscord<Elegantbeef> You know i get pinged on matrix if any one writes "beef" or "Elegantbeef"
06:36:07FromDiscord<huantian> Wait beef pings you?
06:36:11FromDiscord<Elegantbeef> Yes
06:37:02FromDiscord<huantian> That’s handy
06:37:37FromDiscord<Elegantbeef> Atleast with element you can set custom keywords to ping you
06:37:52FromDiscord<Elegantbeef> It's a crazy feat of 1990s engineering
06:37:57FromDiscord<ShalokShalom> PMunch And if you are getting a Pi to work for this, you might be interested about firing it up remotely↵↵https://www.kickstarter.com/projects/mdevaev/pikvm-v4
06:38:17FromDiscord<ShalokShalom> In reply to @Elegantbeef "It's a crazy feat": Yeah, that's something IRC clients can
06:38:25FromDiscord<Elegantbeef> Shalok is lost in the channels
06:38:31FromDiscord<Elegantbeef> Continuing offtopic in Nim
06:38:49FromDiscord<huantian> In reply to @ShalokShalom "PMunch And if you": I got a pi to turn on my pi!
06:38:50FromDiscord<ShalokShalom> In reply to @Elegantbeef "You know i get": I changed it because it looked so ugly 😛
06:39:03FromDiscord<Elegantbeef> First you call me fat now you call me ugly
06:39:04FromDiscord<Elegantbeef> Next you
06:39:06FromDiscord<ShalokShalom> In reply to @Elegantbeef "Continuing offtopic in Nim": Yup.
06:39:08FromDiscord<Elegantbeef> 'll say you do not like me
06:39:17FromDiscord<huantian> Wait does that mean I need another pi to turn on the pi I use to turn on my pi
06:39:34FromDiscord<Elegantbeef> Wake on wan the bastards
06:39:38FromDiscord<ShalokShalom> I say the bots display of remote nicks is ugly
06:39:55FromDiscord<ShalokShalom> In reply to @Elegantbeef "'ll say you do": I love you
06:40:08*PMunch joined #nim
06:40:14FromDiscord<Elegantbeef> Jeez even my parents do not say that
06:40:23FromDiscord<Elegantbeef> "I tolerate you"
06:40:57FromDiscord<ShalokShalom> Haha
06:41:01FromDiscord<ShalokShalom> I can imagine 😅
06:41:38FromDiscord<ShalokShalom> @huantian You can control shutdown/reboot, record video streams of the output, send keyboard and mice signals, etc
06:42:08FromDiscord<huantian> That’s pretty cool
06:42:21FromDiscord<huantian> I was just mostly poking fun of using a pi kvm on a pi
06:43:23FromDiscord<ShalokShalom> And I was wrong
06:43:28FromDiscord<ShalokShalom> Its not just for Pis
06:43:33FromDiscord<ShalokShalom> It's for all computers
06:43:39FromDiscord<Elegantbeef> I thought you knew
06:44:04FromDiscord<Elegantbeef> Allows you to control a computer even in it's ufei gui all the way from the moon
06:44:30FromDiscord<ShalokShalom> I love you to the moon and back
06:45:01FromDiscord<Elegantbeef> Given that i'm surprised you havent commented on my fungus
06:48:52*nanxiao joined #nim
07:43:13*PMunch quit (*.net *.split)
07:43:13*Lord_Nightmare quit (*.net *.split)
07:43:14*anddam quit (*.net *.split)
07:43:14*adium quit (*.net *.split)
07:43:14*gshumway_ quit (*.net *.split)
07:43:14*attah quit (*.net *.split)
07:43:14*mal`` quit (*.net *.split)
07:43:14*Amun-Ra quit (*.net *.split)
07:43:14*via__ quit (*.net *.split)
07:43:14*ttkap quit (*.net *.split)
07:43:14*oisota quit (*.net *.split)
07:43:43*oisota joined #nim
07:43:45*anddam joined #nim
07:43:51*Amun-Ra joined #nim
07:44:16*anddam quit (Changing host)
07:44:16*anddam joined #nim
07:44:24*gshumway joined #nim
07:44:34*via_ joined #nim
07:44:51*PMunch joined #nim
07:45:30*mal`` joined #nim
07:46:13*Lord_Nightmare joined #nim
07:46:37*attah joined #nim
07:46:56*adium joined #nim
07:56:59PMunchWhen do we think Nimble packages will start working properly again?
08:14:50FromDiscord<sOkam!> II want to create N number of `gcc some args` calls
08:17:42madpropsdoes nim parseopt parse string arguments like " = " ?
08:17:47madpropsi mean trims*
08:17:57madpropslike the spaces around =
08:18:14madpropsi want to make it keep the spaces
08:18:44madpropsthough it might be a bad on my end
08:19:21FromDiscord<sOkam!> sent a long message, see http://ix.io/4tfr
08:27:37*nanxiao quit (Quit: Client closed)
08:34:08*derpydoo quit (Quit: derpydoo)
08:38:25*derpydoo joined #nim
08:45:36*nanxiao joined #nim
09:03:38*azimut_ quit (Ping timeout: 255 seconds)
09:05:05*antranigv quit (Quit: ZNC 1.8.2 - https://znc.in)
09:05:13*Notxor joined #nim
09:05:26*antranigv joined #nim
09:13:13*om3ga joined #nim
09:15:18madpropshow can i sanitize the conf().query string for building a regex? let reg = re(&"(?i)({conf().query})")
09:15:25madpropsusing nre
09:15:46madpropsok there's escapeRe
09:16:27madpropsyeah that works
09:40:44*derpydoo quit (Read error: Connection reset by peer)
09:44:03FromDiscord<sOkam!> In reply to @sOkam! "I'm creating a simple": I just found `execProcesses`, that does exactly this↵What is the difference between `execProcess` and `execShellCmd`?↵I know one uses a shell and the other doesn't, but what does that mean in practical terms? When is a shell required vs not?
09:56:29*nanxiao quit (Quit: Client closed)
10:54:22*lucasta joined #nim
11:14:34FromDiscord<Phil> In reply to @PMunch "When do we think": ?!↵Wha? They aren't working properly?
11:15:10FromDiscord<ieltan> Hello, it is possible to get an item in a Table by index rather than by its key ?
11:15:31FromDiscord<ieltan> (edit) "an item" => "a value"
11:15:40PMunchIf you `nimble install` a package on the 2.0 branch and then try to use it Nim can't find it. You basically have to use Nimble to build to use installed packages
11:16:52PMunch@ieltan, what would the index be?
11:19:07FromDiscord<ieltan> In reply to @PMunch "<@256520101015060480>, what would the": It should always be a second element
11:19:34PMunchHuh?
11:20:12PMunchWait, do you mean by the value?
11:20:26FromDiscord<ieltan> Sorry, basically i want to do this `myTable.values[2]`
11:20:30FromDiscord<ieltan> In reply to @PMunch "Wait, do you mean": yes
11:21:02FromDiscord<ieltan> i just want to get the value not by its key but by an index, the second value in the table, idk if that make sense
11:21:07PMunchUhm, you say "yes", but that example says something else
11:21:12PMunchIt doesn't :P
11:21:34PMunchDo you mean the second value which was inserted?
11:21:38*Notxor quit (Quit: Leaving)
11:21:57FromDiscord<ieltan> Yes i suppose
11:22:24FromDiscord<ieltan> In reply to @PMunch "It doesn't :P": sorry im pretty bad at explaining myself
11:22:25PMunchThere is an OrderedTable, but I don't think it exposes a way to get by index, just iteration
11:22:58PMunchWhat you could do is store all the keys in a separate seq
11:23:08PMunchAnd then grab the correct key from that seq by index
11:23:24PMunchOf course this would require removing keys if you remove them from the table as well
11:24:24PMunchOne way to solve it would be to use a linked list, then have a table which just holds a secondary reference to each node
11:25:14PMunchOr you could use a "special key" system where you insert something at your key, but also at "index-2" for example (just make sure to use ref objects so you don't copy your data)
11:25:39PMunchThere are many ways to solve this, and it all really depends on which performance metrics (if any) are important to you
11:26:32PMunchBut short answer is: "no, there is no way using the tables module to get by index (apart from storing the index as a separate key, or looping through the iterator and stopping at the right value)"
11:27:22FromDiscord<ieltan> Alright thanks you for guiding me to the right path
11:28:01PMunchAs with anything, more context as to which problem you're trying to solve exactly might help
11:33:58FromDiscord<ieltan> In reply to @PMunch "As with anything, more": I'm making a discord bot that would eventually caption images like esmBot. esmBot has some logic that allows it to check the next to last message for any attachments if the last one does not contain any (such a scenario happens when you post an image and then execute the command instead of doing it at the same time)
11:35:27FromDiscord<ieltan> The discord cache allows you to get a guild channel object and you can access a Table of messages
11:35:28FromDiscord<System64 ~ Flandre Scarlet> So Nim supports bitpacking?? https://media.discordapp.net/attachments/371759389889003532/1095673539421544508/image.png
11:36:05PMunch@System64_~_Flandre_Scarlet, yes, it has for ages
11:36:11PMunchNot often used though
11:36:28FromDiscord<System64 ~ Flandre Scarlet> Oh alright
11:36:55FromDiscord<offbeat-stuff (offbeat-stuff)> hmm when was bitpacking added?
11:37:02FromDiscord<System64 ~ Flandre Scarlet> I just miss unions sometimes↵They are useful
11:37:14PMunch@System64_~_Flandre_Scarlet, Nim supports unions as well :P
11:37:37PMunchhttps://nim-lang.org/docs/manual.html#foreign-function-interface-union-pragma
11:38:16PMunchboth of these are typically only used for C interop though
11:38:21PMunchFuthark generates them for example
11:39:17FromDiscord<System64 ~ Flandre Scarlet> Oh alright↵But you can't use GC I think
11:41:53PMunchoffbeat-stuff_(offbeat-stuff), seems to have been added about 8 years ago in v0.12.0: https://github.com/nim-lang/Nim/commit/8c8646773024ea740c4c9f090619ddaf61bc16f0
11:42:27PMunchWell I guess it wouldn't have been added until v0.14.0, but still about 8 years ago
11:42:42FromDiscord<System64 ~ Flandre Scarlet> sent a code paste, see https://play.nim-lang.org/#ix=4tg2
11:42:55FromDiscord<System64 ~ Flandre Scarlet> (edit)
11:43:10PMunchYes, Nim can handle that
11:43:29PMunchJust pass it through Futhark and you'll see how :P
11:44:07FromDiscord<System64 ~ Flandre Scarlet> Gotta try it
11:44:21FromDiscord<System64 ~ Flandre Scarlet> It got updated recently?
11:55:01*jmdaemon quit (Ping timeout: 265 seconds)
11:59:42*rockcavera joined #nim
12:15:48PMunchWhat? Futhark?
12:15:53PMunchPretty recently
12:22:15FromDiscord<Chronos [She/Her]> What do y'all recommend for MongoDB drivers? Looking for simplicity but it must also be async
12:22:35FromDiscord<Chronos [She/Her]> I looked at anonimongo but it failed to compile on Nim devel
12:31:33*kenran quit (Ping timeout: 255 seconds)
12:36:16FromDiscord<federico3> I'd recommend not using MongoDB
12:46:00FromDiscord<Chronos [She/Her]> Why not?
12:46:02FromDiscord<Andreas> In reply to @federico3 "I'd recommend not using": that for sure makes it easy finding a proper driver 😉
12:46:10FromDiscord<Chronos [She/Her]> And what should I use instead? Since I need NoSQL
12:46:21FromDiscord<Rika> why do you need nosql
12:46:31FromDiscord<Chronos [She/Her]> (I don't need it, but it'd make my life much easier for migrations and such for example)
12:46:51FromDiscord<Chronos [She/Her]> Since I have no experience with databases and PyMongo (for example) was very simple to learn
12:52:30*progranner joined #nim
12:53:36*progranner quit (Client Quit)
12:56:07*progranner joined #nim
13:26:57*Notxor joined #nim
13:37:58*kenran joined #nim
13:44:39*rockcavera quit (Remote host closed the connection)
13:45:01*rockcavera joined #nim
13:45:01*rockcavera quit (Changing host)
13:45:01*rockcavera joined #nim
13:50:53FromDiscord<System64 ~ Flandre Scarlet> I thought Nim forcing manual conversion was annoying↵But I was wrong... Automatic conversions is baaaaad! So, good things Nim forces conversions
13:51:01FromDiscord<System64 ~ Flandre Scarlet> (edit) "forces" => "force"
13:52:19*PMunch quit (Quit: Leaving)
13:56:49*om3ga quit (Ping timeout: 265 seconds)
14:01:44FromDiscord<federico3> @Chronos [She/Her]\: what do you need the database for? BTW this could be discussed on #offtopic
14:13:30FromDiscord<Chronos [She/Her]> In reply to @federico3 "<@909883978717204561>\: what do you": Alright I'll head there now
14:21:30*Notxor quit (Quit: Leaving)
14:36:48*rockcavera quit (Read error: Connection reset by peer)
14:37:07*rockcavera joined #nim
14:37:07*rockcavera quit (Changing host)
14:37:07*rockcavera joined #nim
14:58:14*azimut joined #nim
15:01:56*rockcavera quit (Remote host closed the connection)
15:02:15*rockcavera joined #nim
15:02:15*rockcavera quit (Changing host)
15:02:15*rockcavera joined #nim
15:06:57NimEventerNew thread by FabienPRI: Noob question exception and await, see https://forum.nim-lang.org/t/10093
15:21:15*attah quit (Ping timeout: 260 seconds)
15:23:12*kenran quit (Ping timeout: 248 seconds)
15:26:51madpropsdoes nim's parseopt require the = format, like -m=123 ? why the = ?
15:27:00madpropskinda breaks convention
15:27:10madpropsor maybe im doing something wrong
15:37:30madpropsi got used to it anyway
15:37:32madpropsbut wondering
15:46:30Amun-Ramadprops: no, it does break the convention
15:47:26madpropsi have an argument parser that depends on it
15:47:27Amun-RaI don't think it supports -- either
15:47:42madpropswondering if there's another core arg parser i could use
15:47:45madpropsif i wanted to change that
15:48:04madpropsto use as the core of my arg parser library
15:48:28madpropsor i could just parse it myself i guess
15:48:50madpropsor leave it as is
15:49:00Amun-Rathere are 3rd party modules
15:49:15Amun-RaI'm in the process of writing my own, posix compliant
15:49:43madpropsi wrote this some years ago https://github.com/madprops/nap
15:49:51madpropsand i use it on several projects
15:51:04Amun-Ranice
15:53:30*Notxor joined #nim
15:59:44*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
16:00:40*progranner joined #nim
16:08:54*ehmry quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
16:10:30*ehmry joined #nim
16:13:35*attah joined #nim
16:18:49*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
16:21:44*progranner joined #nim
16:43:42*lucasta quit (Remote host closed the connection)
17:00:58*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
17:16:44*hochata joined #nim
17:17:29*hochata` joined #nim
17:18:25*hochata` quit (Client Quit)
17:18:41*hochata quit (Client Quit)
17:18:55*hochata joined #nim
17:24:41*progranner joined #nim
17:25:04*progranner quit (Client Quit)
17:32:32*Notxor quit (Remote host closed the connection)
18:03:25*arkurious joined #nim
18:04:06*progranner joined #nim
18:14:56*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
18:19:03*progranner joined #nim
18:21:55*Notxor joined #nim
18:29:10*dv^_^ quit (Quit: dv^_^)
18:30:07NimEventerNew thread by alexeypetrushin: Why sec copied as ref?, see https://forum.nim-lang.org/t/10094
18:31:00*dv^_^ joined #nim
18:31:36*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
18:48:38*progranner joined #nim
19:01:15*om3ga joined #nim
19:02:29*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
19:40:12*progranner joined #nim
19:55:16*rockcavera quit (Read error: Connection reset by peer)
19:56:35*rockcavera joined #nim
19:56:35*rockcavera quit (Changing host)
19:56:35*rockcavera joined #nim
20:19:57*jmdaemon joined #nim
20:22:43*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
20:25:31*luis_ joined #nim
20:25:47*ehmry quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
20:26:20*ehmry joined #nim
20:28:45FromDiscord<zidsal> I remember when nim 1.6 came out Araq gave suggestions on what you should enable on the nim.cfg (e.g orc, strictEffects e.t.c) has anyone made 1 of these for the 2.0 nightlys?
20:33:53*ehmry quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
20:34:29*ehmry joined #nim
20:44:21NimEventerNew thread by mildred: Nim v2 and gcsafe, see https://forum.nim-lang.org/t/10095
20:48:47*rockcavera quit (Read error: Connection reset by peer)
20:51:06*rockcavera joined #nim
20:51:06*rockcavera quit (Changing host)
20:51:06*rockcavera joined #nim
20:54:04FromDiscord<Dudugz> Are there any UI libs made with SDL? In this case, when I refer to a UI (User Interface) lib, I say that it contains widgets such as InputBox, Containers, etc...↵↵PS: I'm specifying this because for some reason, talking about UI people think of graphic rendering when it's a more specific niche
20:55:07FromDiscord<Dudugz> SDL alone doesn't do anything, you need to create the text fields, editing fields, image fields, layout containers etc...
20:58:33FromDiscord<Elegantbeef> I do not know of any
20:58:36FromDiscord<Elegantbeef> So they likely exist but they're not overly popular
21:00:05FromDiscord<Dudugz> Got it, I'll research if I don't find anything interesting I'll make my own. In the past I had done one in python with pygame but I didn't take it seriously.
21:00:27FromDiscord<Elegantbeef> Well pixie + sdl2 ought to make something ok
21:00:37FromDiscord<Dudugz> Sure
21:01:53FromDiscord<BobBBob> Ive got an error like↵ required type for n: int↵ but expression '600851475143'i64' is of type: int64↵I though int was 64 bit? (and im not putting the 'i64 there but it seems to automatically make it i64 since its too big)
21:02:13FromDiscord<Dudugz> Nope, int is int22
21:02:19FromDiscord<Dudugz> (edit) "int22" => "int32"
21:02:26FromDiscord<Yardanico> In reply to @Dudugz "Nope, int is int32*": not true either
21:02:34FromDiscord<Yardanico> int is architecture-dependent
21:02:37FromDiscord<Yardanico> in Nim
21:02:43FromDiscord<Dudugz> no? 🤔 I thought it was an alias
21:02:46FromDiscord<Elegantbeef> `int(...)`
21:02:47FromDiscord<Elegantbeef> Nope int is platform dependant
21:02:48FromDiscord<Dudugz> Got it
21:02:51FromDiscord<Elegantbeef> int on 64bit is 64bit and on 32bit it's 32bit
21:02:53FromDiscord<Yardanico> so it's int32 on 32-bit arch, int64 on 64-bit arch. If you need to be specific, use `int32` or `int64`
21:03:19FromDiscord<Yardanico> @BobBBob what are you passing your int to?
21:03:28FromDiscord<BobBBob> well I tried changing all my functions to use int64 but apparently chant do that because toFloat only works with int which makes no sense
21:03:32FromDiscord<Elegantbeef> Yea i think what happens bob is when you go over int32 limit it assumes it's an `int64`
21:03:39FromDiscord<BobBBob> In reply to @Yardanico "<@279797428146929666> what are you": a function i wrote
21:03:41FromDiscord<Elegantbeef> just do `int 600851475143`
21:04:17FromDiscord<Elegantbeef> Yea i'm correct
21:04:22FromDiscord<Yardanico> In reply to @BobBBob "well I tried changing": you can just do float(x) too if you know the conversion will never fail, no need for toFloat
21:04:26FromDiscord<Elegantbeef> `2147483648` will not compile but `2147483647` does
21:04:54FromDiscord<Elegantbeef> So when you go out of the range of an int32 the compiler correctly assumes it's an int64 cause that's the only crossplatform safe type
21:05:13FromDiscord<BobBBob> In reply to @Elegantbeef "just do `int 600851475143`": that seems to work, I tried 600851475143'int but that's not a thing haha
21:05:29FromDiscord<Dudugz> By the way, if I'm writing a library and at some point I need to issue a error to the developer, should I use ``raise`` or just issue a console alert?
21:06:12FromDiscord<Dudugz> Say I get an instance in a function but in reality the dev passed null and I want to alert the dev that it passed nil, should I raise a defect?
21:06:12FromDiscord<Elegantbeef> 😄
21:06:15FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=4tin
21:06:34FromDiscord<Elegantbeef> If it's not supposed to be nil and never should be nil yes `assert x != nil`
21:06:35FromDiscord<Dudugz> (edit) "null" => "nil"
21:06:45FromDiscord<Dudugz> Thx^^
21:06:50FromDiscord<Elegantbeef> or `doAssert x != nil` if you want it always to be compiled
21:06:57FromDiscord<Elegantbeef> Assertions are code documentation as much as sanity checks
21:06:59FromDiscord<Dudugz> Never should but can't trust user input imagine other devs lol
21:07:48FromDiscord<Dudugz> Ok, I'll use assert/doAssert for sanity checks ^^
22:05:35*Notxor quit (Quit: Leaving)
22:09:27FromDiscord<jmgomez> Fun fact, IC compiles with mm:none
22:14:41FromDiscord<Elegantbeef> Lol
22:14:43FromDiscord<Elegantbeef> Leaky IC
22:17:47FromDiscord<jmgomez> I wonder if writing back the ORC hooks is all that needs
22:18:27FromDiscord<jmgomez> will stress it a bit with no memory to see where it breaks
22:18:37FromDiscord<Elegantbeef> Be the change!
22:20:13FromDiscord<jmgomez> That's too much for me
22:20:52FromDiscord<jmgomez> sent a code paste, see https://play.nim-lang.org/#ix=4tiA
22:21:27FromDiscord<jmgomez> Compiled with koch, results are:↵no ic: 8.5↵ic first pass: 13↵ic: 4.5
22:22:00FromDiscord<zidsal> am I going insane with my nim.cfg?↵↵I have an entry of `--nimPreviewSlimSystem` on nim 1.9.3 however nim says its an invalid commandline option
22:22:29FromDiscord<Elegantbeef> `--define:nimPreviewSlimSystem`?
22:23:09FromDiscord<jmgomez> I guess the more complicated the macro the bigger the gains, the file size is about 15Mb
22:23:31FromDiscord<Elegantbeef> Of course the more code the more likely IC will save time
22:23:35FromDiscord<zidsal> thanks @ElegantBeef , althought mummy doesn't seem to play nice within so guess I wont use it for now
22:24:17FromDiscord<jmgomez> In reply to @Elegantbeef "Of course the more": I mean, it's like a trade off between the expansion vs the calculation that the compiler has to do. Because at some point IO will take longer than just processing the file
22:25:12FromDiscord<Elegantbeef> IC is no substitute for a well designed compiler
22:30:24FromDiscord<jmgomez> Numbers are significantly worst in a full compiled version
22:30:57FromDiscord<jmgomez> IC first pas 5.8 IC 3 No IC 0.6
22:32:11FromDiscord<Elegantbeef> Perhaps there are optimisations that can be done for the IC that presently are not
22:32:20FromDiscord<Elegantbeef> "Make it work, then make it work fast"
22:32:33FromDiscord<Elegantbeef> Though rewriting the compiler to not use pointers likely would make it vastly faster
22:35:02FromDiscord<jmgomez> Yeah, trying to load the files async can be one
22:35:50FromDiscord<jmgomez> In reply to @Elegantbeef ""Make it work, then": what you mean? Like everything stack based?
22:36:01FromDiscord<Elegantbeef> Data oriented design
22:36:11FromDiscord<Elegantbeef> Instead of using pointers store everything in a contiguous sequence
22:36:23FromDiscord<jmgomez> gotcha
22:38:03FromDiscord<Elegantbeef> Shit i just realised why make hack errored, so hmmm gotta try that now 😄
22:46:25*lucasta joined #nim
22:51:15*rockcavera quit (Read error: Connection reset by peer)
22:52:00*rockcavera joined #nim
22:52:00*rockcavera quit (Changing host)
22:52:00*rockcavera joined #nim
23:03:19*ehmry quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
23:03:52*ehmry joined #nim
23:13:58FromDiscord<jmgomez> make hack?
23:14:13FromDiscord<Elegantbeef> my hacked\
23:14:14FromDiscord<Elegantbeef> 😄
23:14:24FromDiscord<Elegantbeef> I was not right it errored again
23:14:51FromDiscord<jmgomez> which one?
23:15:32FromDiscord<jmgomez> btw oddly enough, the --headers are represented by another BModule named "system" in the compiler. Can it be more obfuscated? lol
23:16:08FromDiscord<Elegantbeef> I was trying a hack of preallocating `TNodes` in a sequence and casting them to a `PNode`
23:16:40FromDiscord<jmgomez> ohh to stress it out to check the perf diff?
23:16:56FromDiscord<Elegantbeef> Not to stress it out, but just to see if it was any faster
23:19:32FromDiscord<SpiderDave> anyone know how to use flags like dotall/s with regex findAll?
23:48:16*rockcavera quit (Read error: Connection reset by peer)
23:49:41*rockcavera joined #nim
23:49:41*rockcavera quit (Changing host)
23:49:41*rockcavera joined #nim
23:55:44*cm_ joined #nim
23:56:27*cm quit (Ping timeout: 255 seconds)
23:56:28*cm_ is now known as cm