00:11:31 | FromDiscord | <Elegantbeef> I think oddly it requires installing \nix overtop the windows partition 😛↵(@huantian) |
00:12:02 | FromDiscord | <huantian> oh yeah I compeltely forgot about that step |
00:31:00 | FromDiscord | <sOkam!> sent a code paste, see https://play.nim-lang.org/#ix=4tea |
00:31:24 | FromDiscord | <Elegantbeef> mangled you need to do `{.inject.}` or mark the block template as `{.dirty.}` |
00:32:26 | FromDiscord | <sOkam!> whats the difference between them? |
00:33:55 | FromDiscord | <huantian> inject only applies to one variable |
00:33:59 | FromDiscord | <huantian> dirty applies to all variables in the template |
00:34:47 | FromDiscord | <huantian> use inject normally, use dirty if you have a ton of variables and you want most of them to be injected |
00:35:20 | FromDiscord | <sOkam!> oh so inject goes in the variable, not the template |
00:35:24 | FromDiscord | <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:41 | FromDiscord | <Nerve> sent a long message, see http://ix.io/4tei |
01:10:08 | FromDiscord | <Nerve> (edit) "http://ix.io/4tei" => "http://ix.io/4tej" |
01:10:46 | FromDiscord | <Nerve> (edit) "http://ix.io/4tej" => "http://ix.io/4tek" |
01:11:51 | FromDiscord | <Nerve> (edit) "https://paste.rs/pVx" => "https://paste.rs/3f3" |
01:12:50 | FromDiscord | <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:15 | FromDiscord | <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:17 | FromDiscord | <Rika> uh oh he said the t word |
01:13:34 | FromDiscord | <Nerve> transpiled? |
01:13:42 | FromDiscord | <Rika> yah |
01:13:44 | FromDiscord | <Rika> (edit) "yah" => "yeah" |
01:14:13 | FromDiscord | <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:47 | FromDiscord | <Rika> well people say the argument is that transpiled implies the output is explicitly made to be readable |
01:15:01 | FromDiscord | <Nerve> That sounds like pedantic semantics |
01:15:25 | FromDiscord | <Rika> well we just want to avoid the negative impression the word gives |
01:15:29 | FromDiscord | <Rika> in reality, i mean |
01:15:53 | FromDiscord | <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:05 | FromDiscord | <Nerve> It quickly gets the compatibility point across |
01:17:06 | FromDiscord | <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:16 | FromDiscord | <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:40 | FromDiscord | <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:40 | FromDiscord | <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:24 | FromDiscord | <Nerve> (edit) "assembly." => ""assembly"." |
01:26:09 | FromDiscord | <Elegantbeef> transpile is a very unclear term |
01:26:13 | FromDiscord | <Elegantbeef> Most people have different definitions |
01:26:30 | FromDiscord | <Elegantbeef> Also michael i hate you, i further thought about a general solution to that multi method |
01:26:53 | FromDiscord | <Rika> lol |
01:26:53 | FromDiscord | <michaelb.eth> In reply to @Elegantbeef "Also michael i hate": 😢 |
01:26:58 | FromDiscord | <Rika> professional timewaster |
01:27:08 | FromDiscord | <Elegantbeef> Unpaid professional timewaster |
01:28:15 | FromDiscord | <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:32 | FromDiscord | <Elegantbeef> whoops `type(x)` should be `destType` |
01:28:48 | FromDiscord | <Elegantbeef> To be fair rika i only thought of it whilst cleaning dishes, i didnt implement it |
01:29:57 | FromDiscord | <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:16 | FromDiscord | <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:14 | FromDiscord | <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:39 | FromDiscord | <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:07 | FromDiscord | <michaelb.eth> (edit) "creating" => "generating" | "generatinga binary ... then" added "from source code" |
01:43:10 | FromDiscord | <michaelb.eth> Transpile on wikipedia redirects to this: https://en.wikipedia.org/wiki/Source-to-source_compiler |
01:45:08 | FromDiscord | <michaelb.eth> (edit) |
01:50:29 | FromDiscord | <Elegantbeef> I mostly find it an inane point but meh |
01:50:33 | FromDiscord | <Elegantbeef> Especially talking about nim |
01:51:41 | FromDiscord | <michaelb.eth> In reply to @Elegantbeef "I mostly find it": agreed, it's a nothing burger |
01:52:36 | FromDiscord | <Elegantbeef> Well i think there is some importance when the backend is lua or js |
01:52:36 | FromDiscord | <Elegantbeef> But the backend is C so ... |
01:54:30 | FromDiscord | <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:50 | FromDiscord | <michaelb.eth> e.g. in JS you can't open a native socket |
01:55:11 | FromDiscord | <michaelb.eth> (edit) "native socket" => "raw socket, that kind of thing?" |
02:01:12 | FromDiscord | <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:55 | FromDiscord | <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:38 | NimEventer | New Nimble package! webgeolocation - Bindings to the Webgeolocation Web API, see https://github.com/maleyva1/webgeoloaction |
04:35:08 | FromDiscord | <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:44 | FromDiscord | <Dudugz> PS: AST = Abstract Syntax Tree |
04:50:50 | * | nanxiao joined #nim |
05:00:23 | NimEventer | New 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:04 | FromDiscord | <HitBlast> sent a code paste, see https://play.nim-lang.org/#ix=4tf1 |
05:45:01 | FromDiscord | <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:02 | FromDiscord | <HitBlast> Could you give me an example of the structure? I'm not really familiar with config.nims at all. |
06:00:29 | FromDiscord | <Elegantbeef> create a config.nims at the root of your project and put in `--define:ssl` |
06:03:17 | FromDiscord | <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:28 | FromDiscord | <Elegantbeef> Probably |
06:03:47 | FromDiscord | <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:13 | FromDiscord | <ciwolsey> Ah... I just found the memory model section in the documentation, so I'll give that a read, thanks |
06:05:29 | FromDiscord | <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:41 | FromDiscord | <Elegantbeef> I like me macros |
06:07:55 | FromDiscord | <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:43 | FromDiscord | <Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=4tf4 |
06:10:57 | FromDiscord | <ciwolsey> Right yeah.. that's what I'm looking for |
06:12:43 | FromDiscord | <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:56 | FromDiscord | <HitBlast> or just the config.nims is gonna work |
06:13:13 | FromDiscord | <HitBlast> (edit) "or ... justfile" added "is" | "is" => "file" |
06:14:13 | FromDiscord | <Elegantbeef> `config.nims` will be loaded when built |
06:18:08 | FromDiscord | <Arathanis> sent a code paste, see https://paste.rs/497 |
06:18:18 | FromDiscord | <Arathanis> (edit) "https://play.nim-lang.org/#ix=4tf7" => "https://play.nim-lang.org/#ix=4tf6" |
06:18:44 | FromDiscord | <Elegantbeef> `--` is a template for that |
06:18:50 | FromDiscord | <Arathanis> brilliant |
06:18:54 | FromDiscord | <Arathanis> but also sneaky |
06:19:33 | FromDiscord | <Elegantbeef> Really makes reading configs nicer |
06:22:48 | FromDiscord | <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:49 | FromDiscord | <HitBlast> after building from GitHub Actions |
06:23:07 | FromDiscord | <Elegantbeef> You need to copy the perm files |
06:23:15 | FromDiscord | <Elegantbeef> pem ... whatever it is |
06:23:57 | FromDiscord | <HitBlast> ah well not sure how to do that since GitHub Actions is literally a headless environment |
06:24:11 | FromDiscord | <huantian> here's how i do it https://github.com/huantianad/levelsync/blob/2eadfc3a770cc6a493cd53c8ef7c544cc1dad8de/.github/workflows/main.yml#L13-L37 |
06:24:31 | FromDiscord | <huantian> In my over complicated action |
06:24:50 | FromDiscord | <Elegantbeef> One day i'll setup a github action for something |
06:28:03 | * | nanxiao quit (Quit: Client closed) |
06:33:57 | FromDiscord | <ShalokShalom> @Elegantbeef#0000 This day, the Nim community will lose it's biggest contributor |
06:34:08 | FromDiscord | <ShalokShalom> Rest in peace 🕊️ |
06:34:44 | FromDiscord | <Elegantbeef> Damn that's a threat and a half to someone |
06:34:46 | FromDiscord | <Elegantbeef> I'm not even overweight though |
06:35:00 | FromDiscord | <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:09 | FromDiscord | <ShalokShalom> (edit) "@Elegantbeef#0000" => "@ElegantBeef" |
06:35:25 | FromDiscord | <huantian> No idea |
06:35:35 | FromDiscord | <huantian> Maybe? |
06:35:45 | FromDiscord | <Elegantbeef> You know i get pinged on matrix if any one writes "beef" or "Elegantbeef" |
06:36:07 | FromDiscord | <huantian> Wait beef pings you? |
06:36:11 | FromDiscord | <Elegantbeef> Yes |
06:37:02 | FromDiscord | <huantian> That’s handy |
06:37:37 | FromDiscord | <Elegantbeef> Atleast with element you can set custom keywords to ping you |
06:37:52 | FromDiscord | <Elegantbeef> It's a crazy feat of 1990s engineering |
06:37:57 | FromDiscord | <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:17 | FromDiscord | <ShalokShalom> In reply to @Elegantbeef "It's a crazy feat": Yeah, that's something IRC clients can |
06:38:25 | FromDiscord | <Elegantbeef> Shalok is lost in the channels |
06:38:31 | FromDiscord | <Elegantbeef> Continuing offtopic in Nim |
06:38:49 | FromDiscord | <huantian> In reply to @ShalokShalom "PMunch And if you": I got a pi to turn on my pi! |
06:38:50 | FromDiscord | <ShalokShalom> In reply to @Elegantbeef "You know i get": I changed it because it looked so ugly 😛 |
06:39:03 | FromDiscord | <Elegantbeef> First you call me fat now you call me ugly |
06:39:04 | FromDiscord | <Elegantbeef> Next you |
06:39:06 | FromDiscord | <ShalokShalom> In reply to @Elegantbeef "Continuing offtopic in Nim": Yup. |
06:39:08 | FromDiscord | <Elegantbeef> 'll say you do not like me |
06:39:17 | FromDiscord | <huantian> Wait does that mean I need another pi to turn on the pi I use to turn on my pi |
06:39:34 | FromDiscord | <Elegantbeef> Wake on wan the bastards |
06:39:38 | FromDiscord | <ShalokShalom> I say the bots display of remote nicks is ugly |
06:39:55 | FromDiscord | <ShalokShalom> In reply to @Elegantbeef "'ll say you do": I love you |
06:40:08 | * | PMunch joined #nim |
06:40:14 | FromDiscord | <Elegantbeef> Jeez even my parents do not say that |
06:40:23 | FromDiscord | <Elegantbeef> "I tolerate you" |
06:40:57 | FromDiscord | <ShalokShalom> Haha |
06:41:01 | FromDiscord | <ShalokShalom> I can imagine 😅 |
06:41:38 | FromDiscord | <ShalokShalom> @huantian You can control shutdown/reboot, record video streams of the output, send keyboard and mice signals, etc |
06:42:08 | FromDiscord | <huantian> That’s pretty cool |
06:42:21 | FromDiscord | <huantian> I was just mostly poking fun of using a pi kvm on a pi |
06:43:23 | FromDiscord | <ShalokShalom> And I was wrong |
06:43:28 | FromDiscord | <ShalokShalom> Its not just for Pis |
06:43:33 | FromDiscord | <ShalokShalom> It's for all computers |
06:43:39 | FromDiscord | <Elegantbeef> I thought you knew |
06:44:04 | FromDiscord | <Elegantbeef> Allows you to control a computer even in it's ufei gui all the way from the moon |
06:44:30 | FromDiscord | <ShalokShalom> I love you to the moon and back |
06:45:01 | FromDiscord | <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:59 | PMunch | When do we think Nimble packages will start working properly again? |
08:14:50 | FromDiscord | <sOkam!> II want to create N number of `gcc some args` calls |
08:17:42 | madprops | does nim parseopt parse string arguments like " = " ? |
08:17:47 | madprops | i mean trims* |
08:17:57 | madprops | like the spaces around = |
08:18:14 | madprops | i want to make it keep the spaces |
08:18:44 | madprops | though it might be a bad on my end |
08:19:21 | FromDiscord | <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:18 | madprops | how can i sanitize the conf().query string for building a regex? let reg = re(&"(?i)({conf().query})") |
09:15:25 | madprops | using nre |
09:15:46 | madprops | ok there's escapeRe |
09:16:27 | madprops | yeah that works |
09:40:44 | * | derpydoo quit (Read error: Connection reset by peer) |
09:44:03 | FromDiscord | <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:34 | FromDiscord | <Phil> In reply to @PMunch "When do we think": ?!↵Wha? They aren't working properly? |
11:15:10 | FromDiscord | <ieltan> Hello, it is possible to get an item in a Table by index rather than by its key ? |
11:15:31 | FromDiscord | <ieltan> (edit) "an item" => "a value" |
11:15:40 | PMunch | If 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:52 | PMunch | @ieltan, what would the index be? |
11:19:07 | FromDiscord | <ieltan> In reply to @PMunch "<@256520101015060480>, what would the": It should always be a second element |
11:19:34 | PMunch | Huh? |
11:20:12 | PMunch | Wait, do you mean by the value? |
11:20:26 | FromDiscord | <ieltan> Sorry, basically i want to do this `myTable.values[2]` |
11:20:30 | FromDiscord | <ieltan> In reply to @PMunch "Wait, do you mean": yes |
11:21:02 | FromDiscord | <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:07 | PMunch | Uhm, you say "yes", but that example says something else |
11:21:12 | PMunch | It doesn't :P |
11:21:34 | PMunch | Do you mean the second value which was inserted? |
11:21:38 | * | Notxor quit (Quit: Leaving) |
11:21:57 | FromDiscord | <ieltan> Yes i suppose |
11:22:24 | FromDiscord | <ieltan> In reply to @PMunch "It doesn't :P": sorry im pretty bad at explaining myself |
11:22:25 | PMunch | There is an OrderedTable, but I don't think it exposes a way to get by index, just iteration |
11:22:58 | PMunch | What you could do is store all the keys in a separate seq |
11:23:08 | PMunch | And then grab the correct key from that seq by index |
11:23:24 | PMunch | Of course this would require removing keys if you remove them from the table as well |
11:24:24 | PMunch | One 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:14 | PMunch | Or 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:39 | PMunch | There are many ways to solve this, and it all really depends on which performance metrics (if any) are important to you |
11:26:32 | PMunch | But 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:22 | FromDiscord | <ieltan> Alright thanks you for guiding me to the right path |
11:28:01 | PMunch | As with anything, more context as to which problem you're trying to solve exactly might help |
11:33:58 | FromDiscord | <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:27 | FromDiscord | <ieltan> The discord cache allows you to get a guild channel object and you can access a Table of messages |
11:35:28 | FromDiscord | <System64 ~ Flandre Scarlet> So Nim supports bitpacking?? https://media.discordapp.net/attachments/371759389889003532/1095673539421544508/image.png |
11:36:05 | PMunch | @System64_~_Flandre_Scarlet, yes, it has for ages |
11:36:11 | PMunch | Not often used though |
11:36:28 | FromDiscord | <System64 ~ Flandre Scarlet> Oh alright |
11:36:55 | FromDiscord | <offbeat-stuff (offbeat-stuff)> hmm when was bitpacking added? |
11:37:02 | FromDiscord | <System64 ~ Flandre Scarlet> I just miss unions sometimes↵They are useful |
11:37:14 | PMunch | @System64_~_Flandre_Scarlet, Nim supports unions as well :P |
11:37:37 | PMunch | https://nim-lang.org/docs/manual.html#foreign-function-interface-union-pragma |
11:38:16 | PMunch | both of these are typically only used for C interop though |
11:38:21 | PMunch | Futhark generates them for example |
11:39:17 | FromDiscord | <System64 ~ Flandre Scarlet> Oh alright↵But you can't use GC I think |
11:41:53 | PMunch | offbeat-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:27 | PMunch | Well I guess it wouldn't have been added until v0.14.0, but still about 8 years ago |
11:42:42 | FromDiscord | <System64 ~ Flandre Scarlet> sent a code paste, see https://play.nim-lang.org/#ix=4tg2 |
11:42:55 | FromDiscord | <System64 ~ Flandre Scarlet> (edit) |
11:43:10 | PMunch | Yes, Nim can handle that |
11:43:29 | PMunch | Just pass it through Futhark and you'll see how :P |
11:44:07 | FromDiscord | <System64 ~ Flandre Scarlet> Gotta try it |
11:44:21 | FromDiscord | <System64 ~ Flandre Scarlet> It got updated recently? |
11:55:01 | * | jmdaemon quit (Ping timeout: 265 seconds) |
11:59:42 | * | rockcavera joined #nim |
12:15:48 | PMunch | What? Futhark? |
12:15:53 | PMunch | Pretty recently |
12:22:15 | FromDiscord | <Chronos [She/Her]> What do y'all recommend for MongoDB drivers? Looking for simplicity but it must also be async |
12:22:35 | FromDiscord | <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:16 | FromDiscord | <federico3> I'd recommend not using MongoDB |
12:46:00 | FromDiscord | <Chronos [She/Her]> Why not? |
12:46:02 | FromDiscord | <Andreas> In reply to @federico3 "I'd recommend not using": that for sure makes it easy finding a proper driver 😉 |
12:46:10 | FromDiscord | <Chronos [She/Her]> And what should I use instead? Since I need NoSQL |
12:46:21 | FromDiscord | <Rika> why do you need nosql |
12:46:31 | FromDiscord | <Chronos [She/Her]> (I don't need it, but it'd make my life much easier for migrations and such for example) |
12:46:51 | FromDiscord | <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:53 | FromDiscord | <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:01 | FromDiscord | <System64 ~ Flandre Scarlet> (edit) "forces" => "force" |
13:52:19 | * | PMunch quit (Quit: Leaving) |
13:56:49 | * | om3ga quit (Ping timeout: 265 seconds) |
14:01:44 | FromDiscord | <federico3> @Chronos [She/Her]\: what do you need the database for? BTW this could be discussed on #offtopic |
14:13:30 | FromDiscord | <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:57 | NimEventer | New 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:51 | madprops | does nim's parseopt require the = format, like -m=123 ? why the = ? |
15:27:00 | madprops | kinda breaks convention |
15:27:10 | madprops | or maybe im doing something wrong |
15:37:30 | madprops | i got used to it anyway |
15:37:32 | madprops | but wondering |
15:46:30 | Amun-Ra | madprops: no, it does break the convention |
15:47:26 | madprops | i have an argument parser that depends on it |
15:47:27 | Amun-Ra | I don't think it supports -- either |
15:47:42 | madprops | wondering if there's another core arg parser i could use |
15:47:45 | madprops | if i wanted to change that |
15:48:04 | madprops | to use as the core of my arg parser library |
15:48:28 | madprops | or i could just parse it myself i guess |
15:48:50 | madprops | or leave it as is |
15:49:00 | Amun-Ra | there are 3rd party modules |
15:49:15 | Amun-Ra | I'm in the process of writing my own, posix compliant |
15:49:43 | madprops | i wrote this some years ago https://github.com/madprops/nap |
15:49:51 | madprops | and i use it on several projects |
15:51:04 | Amun-Ra | nice |
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:07 | NimEventer | New 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:45 | FromDiscord | <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:21 | NimEventer | New 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:04 | FromDiscord | <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:07 | FromDiscord | <Dudugz> SDL alone doesn't do anything, you need to create the text fields, editing fields, image fields, layout containers etc... |
20:58:33 | FromDiscord | <Elegantbeef> I do not know of any |
20:58:36 | FromDiscord | <Elegantbeef> So they likely exist but they're not overly popular |
21:00:05 | FromDiscord | <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:27 | FromDiscord | <Elegantbeef> Well pixie + sdl2 ought to make something ok |
21:00:37 | FromDiscord | <Dudugz> Sure |
21:01:53 | FromDiscord | <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:13 | FromDiscord | <Dudugz> Nope, int is int22 |
21:02:19 | FromDiscord | <Dudugz> (edit) "int22" => "int32" |
21:02:26 | FromDiscord | <Yardanico> In reply to @Dudugz "Nope, int is int32*": not true either |
21:02:34 | FromDiscord | <Yardanico> int is architecture-dependent |
21:02:37 | FromDiscord | <Yardanico> in Nim |
21:02:43 | FromDiscord | <Dudugz> no? 🤔 I thought it was an alias |
21:02:46 | FromDiscord | <Elegantbeef> `int(...)` |
21:02:47 | FromDiscord | <Elegantbeef> Nope int is platform dependant |
21:02:48 | FromDiscord | <Dudugz> Got it |
21:02:51 | FromDiscord | <Elegantbeef> int on 64bit is 64bit and on 32bit it's 32bit |
21:02:53 | FromDiscord | <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:19 | FromDiscord | <Yardanico> @BobBBob what are you passing your int to? |
21:03:28 | FromDiscord | <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:32 | FromDiscord | <Elegantbeef> Yea i think what happens bob is when you go over int32 limit it assumes it's an `int64` |
21:03:39 | FromDiscord | <BobBBob> In reply to @Yardanico "<@279797428146929666> what are you": a function i wrote |
21:03:41 | FromDiscord | <Elegantbeef> just do `int 600851475143` |
21:04:17 | FromDiscord | <Elegantbeef> Yea i'm correct |
21:04:22 | FromDiscord | <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:26 | FromDiscord | <Elegantbeef> `2147483648` will not compile but `2147483647` does |
21:04:54 | FromDiscord | <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:13 | FromDiscord | <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:29 | FromDiscord | <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:12 | FromDiscord | <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:12 | FromDiscord | <Elegantbeef> 😄 |
21:06:15 | FromDiscord | <Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=4tin |
21:06:34 | FromDiscord | <Elegantbeef> If it's not supposed to be nil and never should be nil yes `assert x != nil` |
21:06:35 | FromDiscord | <Dudugz> (edit) "null" => "nil" |
21:06:45 | FromDiscord | <Dudugz> Thx^^ |
21:06:50 | FromDiscord | <Elegantbeef> or `doAssert x != nil` if you want it always to be compiled |
21:06:57 | FromDiscord | <Elegantbeef> Assertions are code documentation as much as sanity checks |
21:06:59 | FromDiscord | <Dudugz> Never should but can't trust user input imagine other devs lol |
21:07:48 | FromDiscord | <Dudugz> Ok, I'll use assert/doAssert for sanity checks ^^ |
22:05:35 | * | Notxor quit (Quit: Leaving) |
22:09:27 | FromDiscord | <jmgomez> Fun fact, IC compiles with mm:none |
22:14:41 | FromDiscord | <Elegantbeef> Lol |
22:14:43 | FromDiscord | <Elegantbeef> Leaky IC |
22:17:47 | FromDiscord | <jmgomez> I wonder if writing back the ORC hooks is all that needs |
22:18:27 | FromDiscord | <jmgomez> will stress it a bit with no memory to see where it breaks |
22:18:37 | FromDiscord | <Elegantbeef> Be the change! |
22:20:13 | FromDiscord | <jmgomez> That's too much for me |
22:20:52 | FromDiscord | <jmgomez> sent a code paste, see https://play.nim-lang.org/#ix=4tiA |
22:21:27 | FromDiscord | <jmgomez> Compiled with koch, results are:↵no ic: 8.5↵ic first pass: 13↵ic: 4.5 |
22:22:00 | FromDiscord | <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:29 | FromDiscord | <Elegantbeef> `--define:nimPreviewSlimSystem`? |
22:23:09 | FromDiscord | <jmgomez> I guess the more complicated the macro the bigger the gains, the file size is about 15Mb |
22:23:31 | FromDiscord | <Elegantbeef> Of course the more code the more likely IC will save time |
22:23:35 | FromDiscord | <zidsal> thanks @ElegantBeef , althought mummy doesn't seem to play nice within so guess I wont use it for now |
22:24:17 | FromDiscord | <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:12 | FromDiscord | <Elegantbeef> IC is no substitute for a well designed compiler |
22:30:24 | FromDiscord | <jmgomez> Numbers are significantly worst in a full compiled version |
22:30:57 | FromDiscord | <jmgomez> IC first pas 5.8 IC 3 No IC 0.6 |
22:32:11 | FromDiscord | <Elegantbeef> Perhaps there are optimisations that can be done for the IC that presently are not |
22:32:20 | FromDiscord | <Elegantbeef> "Make it work, then make it work fast" |
22:32:33 | FromDiscord | <Elegantbeef> Though rewriting the compiler to not use pointers likely would make it vastly faster |
22:35:02 | FromDiscord | <jmgomez> Yeah, trying to load the files async can be one |
22:35:50 | FromDiscord | <jmgomez> In reply to @Elegantbeef ""Make it work, then": what you mean? Like everything stack based? |
22:36:01 | FromDiscord | <Elegantbeef> Data oriented design |
22:36:11 | FromDiscord | <Elegantbeef> Instead of using pointers store everything in a contiguous sequence |
22:36:23 | FromDiscord | <jmgomez> gotcha |
22:38:03 | FromDiscord | <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:58 | FromDiscord | <jmgomez> make hack? |
23:14:13 | FromDiscord | <Elegantbeef> my hacked\ |
23:14:14 | FromDiscord | <Elegantbeef> 😄 |
23:14:24 | FromDiscord | <Elegantbeef> I was not right it errored again |
23:14:51 | FromDiscord | <jmgomez> which one? |
23:15:32 | FromDiscord | <jmgomez> btw oddly enough, the --headers are represented by another BModule named "system" in the compiler. Can it be more obfuscated? lol |
23:16:08 | FromDiscord | <Elegantbeef> I was trying a hack of preallocating `TNodes` in a sequence and casting them to a `PNode` |
23:16:40 | FromDiscord | <jmgomez> ohh to stress it out to check the perf diff? |
23:16:56 | FromDiscord | <Elegantbeef> Not to stress it out, but just to see if it was any faster |
23:19:32 | FromDiscord | <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 |