00:03:28 | FromDiscord | <ElegantBeef> @treeform one thing i noticed is that stack tracing seems to take forever on linux if the program is super fast, `10_000` for the iterator seems to be too many, maybe default to like 100 and have a `-sc 10000` or something |
00:04:41 | FromDiscord | <treeform> on windows stack tracing takes a long time, but it does not impact the speed of the running program that much. |
00:04:56 | FromDiscord | <treeform> Usually on windows I can only do 100 samples per second with stack tracing |
00:05:25 | FromDiscord | <treeform> program being examine runs at the same speed as it does without hottie |
00:05:32 | FromDiscord | <treeform> (edit) "examine" => "examined" |
00:07:06 | FromDiscord | <ElegantBeef> Have to test more programs, but we'll see |
00:09:00 | FromDiscord | <ElegantBeef> Yea seems 10000 is way too much for linux |
00:09:07 | FromDiscord | <ElegantBeef> Or my cpu |
00:09:08 | FromDiscord | <ElegantBeef> One of the two |
00:12:08 | * | daemonkeeper joined #nim |
00:12:35 | * | daemonkeeper quit (Remote host closed the connection) |
00:32:26 | * | ryanhowe joined #nim |
00:32:29 | * | koltrast_ joined #nim |
00:39:31 | * | krux02 quit (*.net *.split) |
00:39:31 | * | Saemsays[m] quit (*.net *.split) |
00:39:31 | * | asdflkj quit (*.net *.split) |
00:39:31 | * | vegai quit (*.net *.split) |
00:39:31 | * | Jjp137 quit (*.net *.split) |
00:39:31 | * | Edoardo[m]11 quit (*.net *.split) |
00:39:31 | * | Zoom[m]1 quit (*.net *.split) |
00:39:31 | * | customer[m]1 quit (*.net *.split) |
00:39:31 | * | stisa1 quit (*.net *.split) |
00:39:31 | * | Benjamin[m]121 quit (*.net *.split) |
00:39:31 | * | fbpyr[m]1 quit (*.net *.split) |
00:39:31 | * | nxnl[m]1 quit (*.net *.split) |
00:39:31 | * | dithpri[m]1 quit (*.net *.split) |
00:39:31 | * | spiderstew_ quit (*.net *.split) |
00:39:31 | * | stefantalpalaru quit (*.net *.split) |
00:39:31 | * | Gustavo6046 quit (*.net *.split) |
00:39:31 | * | mjsir911 quit (*.net *.split) |
00:39:31 | * | termer quit (*.net *.split) |
00:39:31 | * | Fish-Face quit (*.net *.split) |
00:39:31 | * | crem quit (*.net *.split) |
00:39:31 | * | zuckerberg[m] quit (*.net *.split) |
00:39:31 | * | Gambit[m] quit (*.net *.split) |
00:39:31 | * | Sappy[m] quit (*.net *.split) |
00:39:31 | * | Hasnep[m] quit (*.net *.split) |
00:39:31 | * | BusterBlue[m] quit (*.net *.split) |
00:39:31 | * | bfgcoding[m] quit (*.net *.split) |
00:39:31 | * | k0mpjut0r quit (*.net *.split) |
00:39:31 | * | Avahe[m] quit (*.net *.split) |
00:39:31 | * | Clonkk[m] quit (*.net *.split) |
00:39:31 | * | Avatarfighter[m] quit (*.net *.split) |
00:39:31 | * | leorize[m] quit (*.net *.split) |
00:39:31 | * | reversem3 quit (*.net *.split) |
00:39:31 | * | lnxw37d4 quit (*.net *.split) |
00:39:31 | * | koltrast quit (*.net *.split) |
00:39:31 | * | sacredfrog quit (*.net *.split) |
00:39:31 | * | Prestige quit (*.net *.split) |
00:39:31 | * | FromGitter quit (*.net *.split) |
00:46:15 | * | lericson joined #nim |
00:46:53 | * | lericson quit (Remote host closed the connection) |
00:46:59 | * | Jjp137 joined #nim |
00:47:46 | * | ranzpirat joined #nim |
00:47:55 | * | ranzpirat quit (Read error: Connection reset by peer) |
00:49:17 | FromDiscord | <brainproxy> sent a code paste, see https://play.nim-lang.org/#ix=3pSM |
00:50:00 | FromDiscord | <brainproxy> Is there some way relatively easy way around it. I'm going to try a game with `cast` but that always feels a little dodgy unless there's not another way. |
00:50:16 | FromDiscord | <brainproxy> (edit) "not" => "no" |
01:00:52 | * | theelous3_ quit (Read error: Connection reset by peer) |
01:07:46 | * | afics joined #nim |
01:08:03 | * | afics is now known as Guest81137 |
01:08:31 | * | Guest81137 quit (Remote host closed the connection) |
01:19:08 | * | vitimiti joined #nim |
01:19:32 | * | vitimiti quit (Remote host closed the connection) |
01:33:33 | * | arkurious quit (Quit: Leaving) |
01:37:06 | * | Netboy3 joined #nim |
01:37:45 | * | Netboy3 quit (Remote host closed the connection) |
01:39:48 | * | coolman_bg84 joined #nim |
01:40:16 | * | coolman_bg84 quit (Remote host closed the connection) |
01:45:30 | * | fowl joined #nim |
01:54:36 | * | grknight joined #nim |
01:54:50 | * | grknight is now known as Guest314 |
01:55:19 | * | Guest314 quit (Remote host closed the connection) |
01:59:57 | FromDiscord | <brainproxy> sent a code paste, see https://play.nim-lang.org/#ix=3pT3 |
02:01:20 | * | Saemsays[m] joined #nim |
02:01:20 | * | asdflkj joined #nim |
02:01:20 | * | vegai joined #nim |
02:01:20 | * | Edoardo[m]11 joined #nim |
02:01:20 | * | Zoom[m]1 joined #nim |
02:01:20 | * | customer[m]1 joined #nim |
02:01:20 | * | stisa1 joined #nim |
02:01:20 | * | Benjamin[m]121 joined #nim |
02:01:20 | * | dithpri[m]1 joined #nim |
02:01:20 | * | nxnl[m]1 joined #nim |
02:01:20 | * | fbpyr[m]1 joined #nim |
02:01:20 | * | spiderstew_ joined #nim |
02:01:20 | * | stefantalpalaru joined #nim |
02:01:20 | * | Gustavo6046 joined #nim |
02:01:20 | * | mjsir911 joined #nim |
02:01:20 | * | termer joined #nim |
02:01:20 | * | Fish-Face joined #nim |
02:01:20 | * | crem joined #nim |
02:01:20 | * | Gambit[m] joined #nim |
02:01:20 | * | zuckerberg[m] joined #nim |
02:01:20 | * | Hasnep[m] joined #nim |
02:01:20 | * | Sappy[m] joined #nim |
02:01:20 | * | bfgcoding[m] joined #nim |
02:01:20 | * | BusterBlue[m] joined #nim |
02:01:20 | * | Clonkk[m] joined #nim |
02:01:20 | * | reversem3 joined #nim |
02:01:20 | * | k0mpjut0r joined #nim |
02:01:20 | * | lnxw37d4 joined #nim |
02:01:20 | * | leorize[m] joined #nim |
02:01:20 | * | Avatarfighter[m] joined #nim |
02:01:20 | * | Avahe[m] joined #nim |
02:01:20 | * | Prestige joined #nim |
02:01:20 | * | FromGitter joined #nim |
02:07:07 | * | rockcavera joined #nim |
02:30:44 | * | lejocelyn joined #nim |
02:30:52 | * | lejocelyn quit (Remote host closed the connection) |
02:38:04 | FromDiscord | <treeform> In reply to @ElegantBeef "Yea seems 10000 is": I think some where 100-1000 is probably a good number |
02:46:07 | * | kanzure joined #nim |
02:46:39 | * | kanzure quit (Remote host closed the connection) |
02:57:55 | * | rockcavera quit (Remote host closed the connection) |
03:38:49 | * | noway96 joined #nim |
03:39:35 | * | noway96 quit (Remote host closed the connection) |
03:42:51 | * | spiderstew joined #nim |
03:42:57 | * | spiderstew_ quit (Ping timeout: 245 seconds) |
04:05:38 | FromDiscord | <aleclarson> has anyone written Node.js bindings with Nim? |
04:05:51 | FromDiscord | <aleclarson> (edit) "has anyone written Node.js bindings with Nim? ... " added "some example code would be very useful" |
04:08:14 | * | meinside joined #nim |
04:08:42 | * | meinside quit (Remote host closed the connection) |
04:08:47 | * | ldlework joined #nim |
04:09:46 | FromDiscord | <aleclarson> oh this looks useful https://github.com/AjBreidenbach/napibindings |
04:10:37 | FromDiscord | <lamersc.com> What’s the difference |
04:10:48 | FromDiscord | <lamersc.com> Between the impure sqlite and the wrapper |
04:10:56 | FromDiscord | <lamersc.com> https://nim-lang.org/docs/lib.html |
04:11:44 | FromDiscord | <lamersc.com> Actually never mind, I’m a dumbass 😅 literally says in the description |
04:11:53 | FromDiscord | <lamersc.com> (edit) "Between" => "~~Between" | "wrapper" => "wrapper~~" |
04:11:57 | FromDiscord | <Hi02Hi> https://github.com/juancarlospaco/nodejs |
04:11:57 | FromDiscord | <lamersc.com> (edit) "What’s" => "~~What’s" | "difference" => "difference~~" |
04:16:13 | * | thePiGrepper9 joined #nim |
04:16:48 | * | SergeyBlack-t21 joined #nim |
04:16:53 | * | thePiGrepper9 quit (Remote host closed the connection) |
04:17:00 | * | SergeyBlack-t21 quit (Remote host closed the connection) |
05:08:48 | * | scubasteve joined #nim |
05:09:06 | * | scubasteve quit (Remote host closed the connection) |
05:14:12 | * | malaphus1 joined #nim |
05:14:34 | * | malaphus1 quit (Remote host closed the connection) |
05:20:22 | * | ldlework quit (Ping timeout: 240 seconds) |
05:20:51 | * | nkaminski[m] joined #nim |
05:21:04 | * | nkaminski[m] quit (Remote host closed the connection) |
05:35:28 | FromDiscord | <ElegantBeef> @treeform ah just hit an issue with hottie, if your program has cli parameters you cannot pass them it it seems |
05:35:56 | FromDiscord | <treeform> oh yeah that would happen. Probably needs a custom CLI priser |
05:39:14 | * | Cthalupa- quit (Excess Flood) |
05:39:29 | FromDiscord | <haxscramper> sent a code paste, see https://play.nim-lang.org/#ix=3pTF |
05:40:08 | * | Cthalupa joined #nim |
05:42:03 | * | shahki joined #nim |
05:42:12 | * | shahki quit (Read error: Connection reset by peer) |
05:42:28 | FromDiscord | <ElegantBeef> That's some nice conversion |
05:44:24 | * | Vladar joined #nim |
05:44:47 | FromDiscord | <ElegantBeef> I do wonder if there is any implication of making `-no-pie` default 😄 |
05:45:25 | FromDiscord | <ElegantBeef> Was thinking about dropping it into my config but wondering if there is any unknown to me side effect |
05:47:19 | * | Saemsays[m] quit (*.net *.split) |
05:47:19 | * | asdflkj quit (*.net *.split) |
05:47:19 | * | vegai quit (*.net *.split) |
05:47:19 | * | Edoardo[m]11 quit (*.net *.split) |
05:47:19 | * | Zoom[m]1 quit (*.net *.split) |
05:47:19 | * | customer[m]1 quit (*.net *.split) |
05:47:19 | * | stisa1 quit (*.net *.split) |
05:47:19 | * | Benjamin[m]121 quit (*.net *.split) |
05:47:19 | * | dithpri[m]1 quit (*.net *.split) |
05:47:19 | * | nxnl[m]1 quit (*.net *.split) |
05:47:19 | * | fbpyr[m]1 quit (*.net *.split) |
05:47:19 | * | stefantalpalaru quit (*.net *.split) |
05:47:19 | * | Gustavo6046 quit (*.net *.split) |
05:47:19 | * | mjsir911 quit (*.net *.split) |
05:47:19 | * | termer quit (*.net *.split) |
05:47:19 | * | Fish-Face quit (*.net *.split) |
05:47:19 | * | crem quit (*.net *.split) |
05:47:19 | * | zuckerberg[m] quit (*.net *.split) |
05:47:19 | * | Gambit[m] quit (*.net *.split) |
05:47:19 | * | Hasnep[m] quit (*.net *.split) |
05:47:19 | * | Sappy[m] quit (*.net *.split) |
05:47:19 | * | BusterBlue[m] quit (*.net *.split) |
05:47:19 | * | bfgcoding[m] quit (*.net *.split) |
05:47:19 | * | k0mpjut0r quit (*.net *.split) |
05:47:19 | * | Avahe[m] quit (*.net *.split) |
05:47:19 | * | Clonkk[m] quit (*.net *.split) |
05:47:19 | * | Avatarfighter[m] quit (*.net *.split) |
05:47:19 | * | leorize[m] quit (*.net *.split) |
05:47:19 | * | reversem3 quit (*.net *.split) |
05:47:19 | * | lnxw37d4 quit (*.net *.split) |
05:47:19 | * | Prestige quit (*.net *.split) |
05:47:19 | * | FromGitter quit (*.net *.split) |
05:48:33 | * | Saemsays[m] joined #nim |
05:48:33 | * | asdflkj joined #nim |
05:48:33 | * | vegai joined #nim |
05:48:33 | * | Edoardo[m]11 joined #nim |
05:48:33 | * | Zoom[m]1 joined #nim |
05:48:33 | * | customer[m]1 joined #nim |
05:48:33 | * | stisa1 joined #nim |
05:48:33 | * | Benjamin[m]121 joined #nim |
05:48:33 | * | dithpri[m]1 joined #nim |
05:48:33 | * | nxnl[m]1 joined #nim |
05:48:33 | * | fbpyr[m]1 joined #nim |
05:48:33 | * | stefantalpalaru joined #nim |
05:48:33 | * | Gustavo6046 joined #nim |
05:48:33 | * | mjsir911 joined #nim |
05:48:33 | * | termer joined #nim |
05:48:33 | * | Fish-Face joined #nim |
05:48:33 | * | crem joined #nim |
05:48:33 | * | Gambit[m] joined #nim |
05:48:33 | * | zuckerberg[m] joined #nim |
05:48:33 | * | Hasnep[m] joined #nim |
05:48:33 | * | Sappy[m] joined #nim |
05:48:33 | * | bfgcoding[m] joined #nim |
05:48:33 | * | BusterBlue[m] joined #nim |
05:48:33 | * | Clonkk[m] joined #nim |
05:48:33 | * | reversem3 joined #nim |
05:48:33 | * | k0mpjut0r joined #nim |
05:48:33 | * | lnxw37d4 joined #nim |
05:48:33 | * | leorize[m] joined #nim |
05:48:33 | * | Avatarfighter[m] joined #nim |
05:48:33 | * | Avahe[m] joined #nim |
05:48:33 | * | Prestige joined #nim |
05:48:33 | * | FromGitter joined #nim |
05:48:48 | FromDiscord | <ElegantBeef> Suppose it makes sense to turn it on when `--debugger:native` |
05:54:25 | * | cel[m] joined #nim |
05:54:40 | * | tamara joined #nim |
05:54:41 | * | cel[m] quit (Remote host closed the connection) |
05:55:24 | * | tamara quit (Remote host closed the connection) |
06:08:23 | * | noc0lour_ joined #nim |
06:08:36 | * | noc0lour_ quit (Remote host closed the connection) |
06:25:41 | * | DEKSSAMYRAI-t16 joined #nim |
06:26:14 | * | DEKSSAMYRAI-t16 quit (Remote host closed the connection) |
06:37:08 | * | redgloboli joined #nim |
06:37:15 | * | redgloboli quit (Remote host closed the connection) |
06:43:02 | * | Culator joined #nim |
06:43:29 | * | Culator quit (Remote host closed the connection) |
06:50:05 | * | aleixPetitCartro joined #nim |
06:50:15 | * | aleixPetitCartro quit (Remote host closed the connection) |
07:08:37 | * | ghost[m]2 joined #nim |
07:09:00 | * | ghost[m]2 quit (Remote host closed the connection) |
07:13:22 | * | inaeth joined #nim |
07:13:32 | * | inaeth quit (Remote host closed the connection) |
07:26:52 | * | Aaeriele joined #nim |
07:26:54 | * | Aaeriele quit (Read error: Connection reset by peer) |
07:27:33 | * | cb18 joined #nim |
07:27:54 | * | cb18 quit (Remote host closed the connection) |
07:36:28 | * | Guest48976 joined #nim |
07:36:49 | * | Guest48976 quit (Remote host closed the connection) |
07:37:45 | * | lynxis joined #nim |
07:37:55 | * | lynxis quit (Remote host closed the connection) |
08:00:30 | * | DarkFeather24 joined #nim |
08:01:07 | * | DarkFeather24 quit (Remote host closed the connection) |
08:09:21 | * | ck[m]1 joined #nim |
08:09:44 | * | ck[m]1 quit (Read error: Connection reset by peer) |
08:11:21 | * | stianlj joined #nim |
08:11:24 | * | stianlj quit (Remote host closed the connection) |
08:12:01 | * | zyeri- joined #nim |
08:12:32 | * | zyeri- quit (Remote host closed the connection) |
08:33:14 | * | Splinter joined #nim |
08:33:43 | * | Splinter quit (Remote host closed the connection) |
08:41:54 | * | sqz2 joined #nim |
08:42:20 | * | sqz2 quit (Remote host closed the connection) |
08:54:10 | * | Vladar quit (Quit: Leaving) |
08:56:07 | * | Vladar joined #nim |
09:01:37 | * | WARBIRD199 joined #nim |
09:02:06 | * | WARBIRD199 quit (Remote host closed the connection) |
09:10:07 | * | zleap-fosdem[m] joined #nim |
09:10:27 | * | zleap-fosdem[m] quit (Remote host closed the connection) |
09:11:35 | * | Sparkie13 joined #nim |
09:11:39 | * | Sparkie13 quit (Remote host closed the connection) |
09:13:44 | * | krux02 joined #nim |
09:14:56 | * | mybalzitch joined #nim |
09:15:39 | * | mybalzitch quit (Remote host closed the connection) |
09:24:39 | * | Dherder joined #nim |
09:25:08 | * | Dherder quit (Remote host closed the connection) |
09:25:32 | * | Artur3-t joined #nim |
09:25:47 | * | Artur3-t quit (Remote host closed the connection) |
09:28:48 | FromDiscord | <Goel> sent a code paste, see https://play.nim-lang.org/#ix=3pUQ |
09:29:17 | FromDiscord | <ElegantBeef> `walkDir("res/")` |
09:29:33 | FromDiscord | <ElegantBeef> Probably dont need the `/` 😄 |
09:30:18 | FromDiscord | <Goel> don't work |
09:30:44 | FromDiscord | <Goel> (edit) "work" => "work. I mean, doesn't give me an error, but doesn't give me as return what i am expecting" |
09:30:57 | FromDiscord | <haxscramper> First - you are confusing it with `walkPattern` https://nim-lang.org/docs/os.html#walkPattern.i%2Cstring |
09:31:49 | FromDiscord | <Goel> Yeah sorry, i mistyped it, in the example, i meant `walkFiles` |
09:33:14 | FromDiscord | <ElegantBeef> Do you want all files in that folder recursively, or just at root level? |
09:33:44 | FromDiscord | <haxscramper> https://media.discordapp.net/attachments/371759389889003532/853930195576815617/unknown.png |
09:34:13 | FromDiscord | <ElegantBeef> Well as it says the walking pattern maybe os dependant |
09:34:27 | FromDiscord | <Goel> recursively |
09:34:28 | FromDiscord | <haxscramper> `but at least the ".ext" notation is supported.` |
09:34:45 | FromDiscord | <haxscramper> For recursive you need to use https://nim-lang.org/docs/os.html#walkDirRec.i%2Cstring |
09:35:00 | FromDiscord | <ElegantBeef> does `tmp/` count as `.ext`? 😄 |
09:35:08 | FromDiscord | <ElegantBeef> I took it as you could do `.png` |
09:35:30 | FromDiscord | <haxscramper> Need to find someone to test it on windows, since linux supports all patterns |
09:35:40 | FromDiscord | <haxscramper> @Goel what OS are you on? |
09:36:05 | FromDiscord | <ElegantBeef> Well wine takes all of .2 seconds to run |
09:39:51 | FromDiscord | <Goel> The binary i launch is : documents/myproject/ # here is the binary .nim↵If i use walkDirs("") here it shows the file i want. Now inside this folder there is another dir called "res" I want to iterate over that folder, so i tried with walkDirs("res") and walkDirs("res/") but probably i need to use the other way you mentionted (recursive). And im on Linux |
09:40:12 | * | p8m2 joined #nim |
09:40:50 | * | p8m2 quit (Remote host closed the connection) |
09:41:37 | * | dserodio joined #nim |
09:41:48 | * | dserodio quit (Remote host closed the connection) |
09:45:06 | * | kinghat joined #nim |
09:45:39 | * | kinghat quit (Remote host closed the connection) |
09:48:40 | * | NimBot joined #nim |
09:56:43 | FromDiscord | <Goel> @ElegantBeef It works with walkDirRec, but what is supposed to do the "checkDir = false" in that proc? Because by default is set to false, and in fact i only want to iterate over the Files into that folder, not also into the Dirs and their respective Files. But turning it true or false doesn't change it, so probably "checkDir" means something else |
10:01:16 | * | Radnor joined #nim |
10:01:23 | * | Radnor quit (Read error: Connection reset by peer) |
10:02:00 | * | SeepingN_ joined #nim |
10:02:00 | * | SeepingN_ is now known as Guest89211 |
10:02:21 | * | Guest89211 quit (Remote host closed the connection) |
10:02:37 | * | ozzz quit (Ping timeout: 240 seconds) |
10:05:48 | * | tuu joined #nim |
10:06:14 | * | tuu quit (Remote host closed the connection) |
10:12:54 | FromDiscord | <System64 ~ Flandre Scarlet> this code take a path to a 16-bits wav as argument + a resolution (here, 4 or 8) and outputs a 4 or 8 bits wav depending of the selected resolution https://media.discordapp.net/attachments/371759389889003532/853940049837424680/message.nim |
10:13:03 | FromDiscord | <System64 ~ Flandre Scarlet> Can I improve something? |
10:14:57 | FromDiscord | <Rika> improve in what way |
10:15:09 | FromDiscord | <haxscramper> There is a built-in `clamp` implementation https://nim-lang.org/docs/system.html#clamp%2CT%2CT%2CT |
10:15:34 | FromDiscord | <System64 ~ Flandre Scarlet> In reply to @Rika "improve in what way": Making the code better |
10:15:48 | FromDiscord | <Rika> better how |
10:16:16 | FromDiscord | <haxscramper> If there are only two quantization modes I would put things in enum |
10:16:16 | FromDiscord | <System64 ~ Flandre Scarlet> Optimisation and cleanup |
10:16:33 | FromDiscord | <System64 ~ Flandre Scarlet> It will have 8 |
10:16:38 | FromDiscord | <System64 ~ Flandre Scarlet> 1 to 8 bits |
10:16:42 | FromDiscord | <haxscramper> Instead of adding magic constants, and use `case-of` for `quantize` |
10:17:07 | FromDiscord | <System64 ~ Flandre Scarlet> case of instead of if? |
10:17:10 | FromDiscord | <haxscramper> yes |
10:17:17 | FromDiscord | <System64 ~ Flandre Scarlet> Oh alright |
10:17:33 | FromDiscord | <haxscramper> Also make quanitzation proc more generic instead of writing it eight times over |
10:17:55 | FromDiscord | <System64 ~ Flandre Scarlet> with a case of? |
10:18:52 | FromDiscord | <haxscramper> sent a code paste, see https://play.nim-lang.org/#ix=3pV9 |
10:19:13 | FromDiscord | <haxscramper> In reply to @System64 "with a case of?": No, I mean to generalize over magic constants in copy-pasted implementation |
10:19:54 | FromDiscord | <System64 ~ Flandre Scarlet> ah yeah I see |
10:20:12 | FromDiscord | <System64 ~ Flandre Scarlet> and QuantMode is an int or enum? |
10:20:20 | FromDiscord | <haxscramper> I would use enum |
10:20:36 | FromDiscord | <haxscramper> Though `range[1..8]` is also a thing |
10:20:47 | FromDiscord | <System64 ~ Flandre Scarlet> yeah |
10:21:29 | FromDiscord | <System64 ~ Flandre Scarlet> also, the div proc, does it round to the inferior int or superior? |
10:21:46 | FromDiscord | <System64 ~ Flandre Scarlet> for exemple if I 3.7, does it round to 3 or to 4? |
10:22:03 | FromDiscord | <haxscramper> div does not round anything |
10:22:21 | FromDiscord | <System64 ~ Flandre Scarlet> ah it justs remove the decimals so? |
10:22:45 | FromDiscord | <haxscramper> yes, https://nim-lang.org/docs/system.html#div%2Cint%2Cint |
10:22:52 | * | ZoomZoomZoom joined #nim |
10:23:48 | FromDiscord | <System64 ~ Flandre Scarlet> Ah I see |
10:29:10 | FromDiscord | <System64 ~ Flandre Scarlet> I have a question↵I try to quantize to 1-bit↵But what should I do if the result is 0.5? return 255 or return 0? |
10:30:34 | FromDiscord | <Rika> you need to take a different approach when quantising to 1 bit |
10:31:10 | FromDiscord | <Rika> https://en.wikipedia.org/wiki/Pulse-density_modulation |
10:31:13 | FromDiscord | <Rika> maybe |
10:32:28 | FromDiscord | <Rika> i dont remember if pdm is supported in wav |
10:32:34 | FromDiscord | <System64 ~ Flandre Scarlet> Ah yeah the algorithm seems more complex |
10:32:38 | FromDiscord | <Rika> but 1 bit quantisation doesnt make sense without using pdm anyway |
10:33:24 | FromDiscord | <System64 ~ Flandre Scarlet> and for quantizing to 4-bits for exemple? My method works? |
10:33:53 | FromDiscord | <System64 ~ Flandre Scarlet> sent a code paste, see https://play.nim-lang.org/#ix=3pVh |
10:34:46 | FromDiscord | <System64 ~ Flandre Scarlet> (edit) "https://play.nim-lang.org/#ix=3pVh" => "https://play.nim-lang.org/#ix=3pVi" |
10:38:05 | * | tolt joined #nim |
10:38:30 | * | tolt quit (Remote host closed the connection) |
10:39:04 | FromDiscord | <System64 ~ Flandre Scarlet> sent a code paste, see https://play.nim-lang.org/#ix=3pVl |
10:41:40 | FromDiscord | <Rika> yes but again i dont know if pdm is supported in wav |
10:42:43 | FromDiscord | <System64 ~ Flandre Scarlet> isn't it called pwm? |
10:42:56 | FromDiscord | <Rika> what do you mean? |
10:43:12 | FromDiscord | <System64 ~ Flandre Scarlet> Isn't it also called Pulse Width Modulation? |
10:43:14 | FromDiscord | <Rika> no |
10:43:18 | FromDiscord | <Rika> that is different |
10:43:25 | FromDiscord | <Rika> pdm, pwm, pcm |
10:43:46 | * | ldlework joined #nim |
10:44:17 | Zevv | pwm is pdm, tho |
10:44:23 | Zevv | but pdm is not pwm |
10:44:54 | FromDiscord | <System64 ~ Flandre Scarlet> By 1-bit I mean something like ZX Spectrum for exemple |
10:57:26 | * | laudecay0 joined #nim |
10:57:28 | * | laudecay0 quit (Remote host closed the connection) |
11:02:35 | * | appledash joined #nim |
11:03:20 | * | appledash quit (Remote host closed the connection) |
11:18:17 | * | ZoomZoomZoom quit (Ping timeout: 240 seconds) |
11:25:50 | * | joast quit (Ping timeout: 268 seconds) |
11:26:24 | * | joast joined #nim |
11:26:33 | * | BruceS_5 joined #nim |
11:26:39 | * | BruceS_5 quit (Remote host closed the connection) |
11:29:04 | * | untitaker joined #nim |
11:29:34 | * | untitaker quit (Remote host closed the connection) |
11:34:00 | * | tjm15 joined #nim |
11:34:30 | * | tjm15 quit (Remote host closed the connection) |
11:37:50 | * | ZoomZoomZoom joined #nim |
11:43:31 | * | Peppard joined #nim |
11:43:39 | * | Peppard quit (Remote host closed the connection) |
11:48:23 | * | arkurious joined #nim |
11:52:13 | * | leth joined #nim |
11:53:31 | leth | Is there a nifty way to get a stringvalue from nimtypekind that represents the name of the type? |
11:57:17 | FromDiscord | <haxscramper> `$typeof(YourType)` |
11:59:11 | leth | doesn't work on numtypekind. |
11:59:19 | leth | nimtypekind |
12:00:20 | leth | nimnodekind sorry |
12:02:24 | * | dkozel_ joined #nim |
12:02:35 | * | dkozel_ quit (Remote host closed the connection) |
12:04:00 | leth | I already know it's a NimNodeKind, I want to know which one it is, and not the value of the enum but a textual representation. |
12:04:41 | FromDiscord | <Bung> parseEnum ? |
12:06:36 | FromDiscord | <Bung> sorry I dont understand question. |
12:07:01 | * | abm joined #nim |
12:07:36 | leth | hmm doesn't work. |
12:08:28 | FromDiscord | <haxscramper> You need to convert enum to string? Or string to enum? |
12:08:30 | leth | well I have a NimNodeKind, and I would like a textuall representation of which one it is. Like just an integer doesn't help much in error messages. |
12:08:41 | FromDiscord | <haxscramper> $node.kind |
12:09:10 | FromDiscord | <haxscramper> Will give you a textual representation of the node kind, like nkStrLit |
12:11:22 | leth | yes, but is $ not deprecated? |
12:13:18 | FromDiscord | <haxscramper> No, of course not |
12:14:21 | leth | Hmm, the manual I'm reading says it is. |
12:16:24 | FromDiscord | <haxscramper> Can you link to the specific part of the manual where it says it? |
12:16:36 | leth | https://nim-lang.org/docs/macros.html#$,NimIdent |
12:18:04 | planetis[m] | that's for NimIdent |
12:18:17 | planetis[m] | NimIdent is deprecated allong with its "methods" |
12:20:56 | * | disruptivenl joined #nim |
12:21:03 | * | disruptivenl quit (Remote host closed the connection) |
12:21:27 | * | leth quit (Ping timeout: 260 seconds) |
12:22:43 | * | syrius joined #nim |
12:22:58 | * | syrius quit (Remote host closed the connection) |
12:29:05 | ForumUpdaterBot | New thread by IvanS: NiGui - thread issue - what am I doing wrong ?, see https://forum.nim-lang.org/t/8113 |
12:43:53 | * | DarkTrick6 joined #nim |
12:44:00 | * | DarkTrick6 quit (Remote host closed the connection) |
12:46:12 | * | arza29 joined #nim |
12:46:28 | * | arza29 quit (Remote host closed the connection) |
12:48:52 | * | helo1 joined #nim |
12:49:24 | FromDiscord | <Zachary Carter> I'm using `--gc:orc` and attempting to pass a Nim string to some C code which is doing a strcopy on it. The string is actually being allocated in another DLL (that's being compiled using `--gc:orc`).↵↵Either way what I'd like to have happen is for this string to not be collected. I can of course use cstring and just copy the memory myself but I was hoping for a simpler solution. I don't think `GC_ref` or `GC_unref` will work wi |
12:49:25 | * | helo1 quit (Remote host closed the connection) |
12:50:14 | FromDiscord | <Zachary Carter> oh and of course the Nim string will be mapped to a cstring before being passed to the C code |
12:50:27 | FromDiscord | <Zachary Carter> but this is automatic |
12:56:26 | FromDiscord | <clyybber> @Zachary Carter Yeah GC_ref/unref won't work. Did you try making the cstring param a sink param? |
12:58:12 | FromDiscord | <Zachary Carter> I didn't, I can try that though. Really what I'm doing is passing this config object to a function pointer loaded from this DLL, it's assigning a string value to some property in that object and then the host program is filling out another struct and copying values from this config object. |
12:59:10 | * | NimBot joined #nim |
12:59:52 | * | capn joined #nim |
12:59:58 | * | capn quit (Read error: Connection reset by peer) |
13:00:03 | FromDiscord | <Zachary Carter> probably just using cstrings and copymem for all this would be easier 😅 |
13:07:15 | FromDiscord | <clyybber> heh, maybe :D @Zachary Carter does sink param work? |
13:08:21 | FromDiscord | <clyybber> ah nevermind, that won't work either I think |
13:08:21 | FromDiscord | <Zachary Carter> well it prevents the crash but nothing gets copied so far as I can tell |
13:08:24 | FromDiscord | <Zachary Carter> yeah |
13:08:30 | FromDiscord | <clyybber> oh yeah it won't copy, because it can move |
13:09:30 | FromDiscord | <clyybber> hmm, no it's safe to use sink actually |
13:11:02 | FromDiscord | <clyybber> @Zachary Carter you can adding another call using the string after the call to your C function and then you should see that it will copy |
13:11:09 | FromDiscord | <clyybber> (edit) "adding" => "add" |
13:12:25 | FromDiscord | <clyybber> ah damn, no it won't sorry, because cstring has different copy semantics |
13:12:49 | FromDiscord | <clyybber> it would if you were just passing a string, but the conversion to cstring means it will get reference semantics |
13:12:55 | FromDiscord | <Zachary Carter> yeah :/ |
13:13:04 | FromDiscord | <Zachary Carter> that's what I'm finding too haha |
13:13:11 | FromDiscord | <Zachary Carter> and understanding from reading |
13:14:10 | FromDiscord | <clyybber> IMO if you want no copy to happen for efficiency reasons you should use a sink param, and then `move` the string explicitly too, to make sure that really no copy will happen |
13:15:06 | FromDiscord | <clyybber> but if you don't care too much if it copies or not, just copyMem the cstring |
13:15:45 | FromDiscord | <Zachary Carter> Okay thanks clyybber! I'll play around with this and see if I can get it working with the move and sink |
13:15:46 | * | xace quit (Ping timeout: 272 seconds) |
13:15:50 | FromDiscord | <Zachary Carter> and if not resort to the copymem |
13:17:30 | * | xace joined #nim |
13:20:06 | * | TubbyTommy joined #nim |
13:20:42 | * | TubbyTommy quit (Remote host closed the connection) |
13:36:29 | * | arecaceae quit (Remote host closed the connection) |
13:40:13 | * | ilmari25 joined #nim |
13:40:21 | * | arecaceae joined #nim |
13:40:59 | * | ilmari25 quit (Remote host closed the connection) |
13:46:49 | * | rockcavera joined #nim |
14:01:43 | * | SpaceManiac23 joined #nim |
14:02:03 | * | SpaceManiac23 quit (Remote host closed the connection) |
14:11:21 | * | revere quit (*.net *.split) |
14:11:21 | * | Zevv quit (*.net *.split) |
14:11:21 | * | idxu quit (*.net *.split) |
14:11:21 | * | jken quit (*.net *.split) |
14:11:21 | * | ldlework quit (*.net *.split) |
14:11:21 | * | Araq quit (*.net *.split) |
14:11:21 | * | snowolf quit (*.net *.split) |
14:11:21 | * | so quit (*.net *.split) |
14:11:21 | * | mahlon quit (*.net *.split) |
14:11:22 | * | Northstrider[m] quit (*.net *.split) |
14:11:22 | * | zopsi quit (*.net *.split) |
14:11:22 | * | JStoker quit (*.net *.split) |
14:11:22 | * | beatmox quit (*.net *.split) |
14:11:22 | * | fredsted quit (*.net *.split) |
14:11:22 | * | Amun_Ra quit (*.net *.split) |
14:11:22 | * | ebb quit (*.net *.split) |
14:11:22 | * | skelett quit (*.net *.split) |
14:11:22 | * | Yardanico quit (*.net *.split) |
14:11:22 | * | fantis quit (*.net *.split) |
14:11:22 | * | motersen_ quit (*.net *.split) |
14:11:22 | * | grobe0ba quit (*.net *.split) |
14:11:22 | * | ForumUpdaterBot quit (*.net *.split) |
14:11:22 | * | literal quit (*.net *.split) |
14:14:51 | * | fowl quit (Ping timeout: 248 seconds) |
14:15:04 | * | azed joined #nim |
14:17:15 | * | acidfu joined #nim |
14:17:19 | * | acidfu quit (Remote host closed the connection) |
14:20:11 | * | fowl joined #nim |
14:40:57 | * | gen_ale_drinker joined #nim |
14:41:08 | * | gen_ale_drinker quit (Remote host closed the connection) |
14:43:12 | * | ldlework joined #nim |
14:43:12 | * | fantis joined #nim |
14:43:12 | * | Northstrider[m] joined #nim |
14:43:12 | * | jken joined #nim |
14:43:12 | * | idxu joined #nim |
14:43:12 | * | Zevv joined #nim |
14:43:12 | * | revere joined #nim |
14:43:12 | * | Yardanico joined #nim |
14:43:12 | * | skelett joined #nim |
14:43:12 | * | motersen_ joined #nim |
14:43:12 | * | Araq joined #nim |
14:43:12 | * | literal joined #nim |
14:43:12 | * | ebb joined #nim |
14:43:12 | * | fredsted joined #nim |
14:43:12 | * | Amun_Ra joined #nim |
14:43:12 | * | beatmox joined #nim |
14:43:12 | * | ForumUpdaterBot joined #nim |
14:43:12 | * | grobe0ba joined #nim |
14:43:12 | * | JStoker joined #nim |
14:43:12 | * | zopsi joined #nim |
14:43:12 | * | mahlon joined #nim |
14:43:12 | * | snowolf joined #nim |
14:43:12 | * | so joined #nim |
14:47:23 | * | ldlework quit (Ping timeout: 240 seconds) |
14:53:03 | * | coolbry9519 joined #nim |
14:53:25 | * | azed quit (Quit: WeeChat 3.2) |
14:53:44 | * | coolbry9519 quit (Remote host closed the connection) |
14:55:10 | FromDiscord | <mlokis> if i pass gced mem to thread upon creation, it will move it to local heap? |
14:55:26 | FromDiscord | <mlokis> (edit) "if i pass gced mem to thread upon creation, it will move it to ... local" added "thread" |
15:04:00 | * | ldlework joined #nim |
15:04:23 | * | ldlework quit (Changing host) |
15:04:23 | * | ldlework joined #nim |
15:05:37 | FromGitter | <BracketMaster> https://vlang.io/compare#nim |
15:05:47 | FromGitter | <BracketMaster> oops wrong chat |
15:05:51 | FromGitter | <BracketMaster> sry |
15:08:52 | * | moniker--27 joined #nim |
15:09:27 | * | moniker--27 quit (Remote host closed the connection) |
15:20:19 | FromDiscord | <Rika> 👀 |
15:23:21 | FromDiscord | <Rika> okay legitimately ive never understood why explicit imports are better |
15:25:13 | * | scgtrp joined #nim |
15:25:50 | * | scgtrp quit (Remote host closed the connection) |
15:29:24 | Prestige | how explicit are we talking, like import foo/bar? |
15:29:40 | * | Mechanismus0 joined #nim |
15:29:52 | * | Mechanismus0 quit (Remote host closed the connection) |
15:30:01 | FromDiscord | <Rika> math.sqrt |
15:30:02 | FromDiscord | <Rika> () |
15:31:39 | Prestige | you mean the import or the invocation? |
15:32:49 | * | krux02 quit (Remote host closed the connection) |
15:33:37 | * | krux02 joined #nim |
15:34:03 | * | tane joined #nim |
15:34:28 | FromDiscord | <Rika> explicit module name before functions |
15:35:18 | Prestige | I think it helps clarify where the functions are defined, or used to avoid conflicts with function names. But that's about it |
15:35:34 | FromDiscord | <Rika> function name conflicts are extremely rare due to overloading |
15:35:35 | FromDiscord | <exelotl> sometimes I like to use explicit imports when I'm importing a huge module only to use 1 or 2 symbols from it |
15:35:47 | FromDiscord | <Rika> clarification of where functions is? sure yeah |
15:35:57 | FromDiscord | <exelotl> yep |
15:36:38 | FromDiscord | <Rika> but then if your language has methods then that's an invalid argument, since you can say that methods dont have the explicit module name |
15:36:54 | FromDiscord | <NIM> https://media.discordapp.net/attachments/371759389889003532/854021588474134578/Screenshot_2021-06-14-18-20-16-327_com.android.chrome.jpg |
15:37:02 | FromDiscord | <NIM> sent a code paste, see https://play.nim-lang.org/#ix=3pWJ |
15:37:03 | FromDiscord | <Rika> man whatever, i cannot take vlang seriously |
15:37:33 | FromDiscord | <Zachary Carter> In reply to @mlokis "if i pass gced": what GC are you using? |
15:37:43 | FromDiscord | <Rika> In reply to @NIM "Bello! Have big string": what is the error precisely? |
15:37:58 | FromDiscord | <mlokis> In reply to @Zachary Carter "what GC are you": i guess a default one |
15:38:08 | ForumUpdaterBot | New Nimble package! slim - nim package manager, see https://github.com/bung87/slim |
15:38:12 | FromDiscord | <NIM> @Rika There is no error like error. Files just not creating :( |
15:38:40 | FromDiscord | <exelotl> "only 1 way to do things" is such a misguided philosophy lol |
15:38:53 | FromDiscord | <Zachary Carter> mlokis no the memory will not be moved |
15:38:59 | FromDiscord | <System64 ~ Flandre Scarlet> I have a question, I'm doing operations on files and I want to do something like "program.exe C:\.wav", how can I achieve that please? |
15:39:08 | FromDiscord | <Rika> In reply to @exelotl ""only 1 way to": mm i like to use my hammer for everything |
15:39:15 | FromDiscord | <Zachary Carter> I'd suggest checking out `--gc:arc` |
15:39:18 | FromDiscord | <Rika> screwing in fasteners? hammer |
15:39:28 | FromDiscord | <Rika> tightening bolts? hammer |
15:39:35 | FromDiscord | <Zachary Carter> if you want to use the default gc, you can look into channels |
15:39:40 | FromDiscord | <Rika> painting? hammer |
15:39:55 | FromDiscord | <Zachary Carter> or you can allocate memory on the shared heap |
15:40:02 | FromDiscord | <Zachary Carter> and pass pointers to threads |
15:40:04 | FromDiscord | <haxscramper> In reply to @System64 "I have a question,": https://nim-lang.org/docs/osproc.html#execProcess%2Cstring%2Cstring%2CopenArray%5Bstring%5D%2CStringTableRef%2Cset%5BProcessOption%5D execute shell process/program |
15:40:08 | FromDiscord | <Zachary Carter> and use synchronization primitives |
15:40:37 | FromDiscord | <Zachary Carter> with the default memory model, every thread has its own local heap and GC |
15:40:41 | FromDiscord | <Zachary Carter> err sorry local heap |
15:40:46 | FromDiscord | <Zachary Carter> each ni mprogram will have its own gc |
15:40:50 | FromDiscord | <Zachary Carter> (edit) "ni mprogram" => "nim program" |
15:40:51 | FromDiscord | <System64 ~ Flandre Scarlet> Oh seems complex |
15:41:02 | FromDiscord | <Zachary Carter> (edit) removed "and GC" |
15:41:25 | FromDiscord | <haxscramper> In reply to @System64 "Oh seems complex": `execProcess("program.exe", args=["C:.wav"])` |
15:41:36 | FromDiscord | <Zachary Carter> so you just have to be aware of these things |
15:41:46 | FromDiscord | <System64 ~ Flandre Scarlet> yes but no↵My code is the program |
15:41:48 | FromDiscord | <haxscramper> But windows does not support proper globbing in shell IIRC, so you might need to collect all files manually |
15:42:05 | FromDiscord | <System64 ~ Flandre Scarlet> and Linux does? |
15:42:31 | FromDiscord | <haxscramper> Yes, but I would not rely on it either way |
15:42:32 | * | tane quit (Quit: Leaving) |
15:43:07 | FromDiscord | <haxscramper> In reply to @System64 "yes but no My": You want to launch `program.exe` from your code or to support `program.exe C:.wav` in your code? |
15:43:32 | FromDiscord | <System64 ~ Flandre Scarlet> What I want to do is collecting all wav files in a folder and store the paths in an seq https://media.discordapp.net/attachments/371759389889003532/854023259766128660/message.nim |
15:43:39 | FromDiscord | <System64 ~ Flandre Scarlet> second |
15:43:45 | FromDiscord | <System64 ~ Flandre Scarlet> the second one |
15:45:00 | FromDiscord | <haxscramper> I don't really know how globbing works in windows shell - if it natively supports `C:.wav` then your program will just get many arguments instead of single `c:` |
15:46:23 | FromDiscord | <haxscramper> If windows does not support globbing you might want to use https://nim-lang.org/docs/os.html#walkPattern.i%2Cstring (also windows-specific) or some external glob package like https://haxscramper.github.io/hmisc/src/hmisc/algo/hseq_distance.html#accept%2Cseq%5BGitGlob%5D%2Cstring (git-style globs, pure nim) or https://github.com/citycide/glob (regular globs, compiles to regex) |
15:46:46 | FromDiscord | <gerwy> Did anyone tried to make the game of Nim in Nim? |
15:47:15 | FromDiscord | <haxscramper> Actually latter one seems to support git-style globs as well https://glob.bolingen.me/latest/glob.html#syntax |
15:48:01 | FromDiscord | <mlokis> In reply to @Zachary Carter "I'd suggest checking out": is that thread safe? i mean i eliminated need of initialization with gced memory but i still have to send socket trough channel. Is that safe? |
15:48:57 | FromDiscord | <Zachary Carter> you shouldn't need to use channels if you use `--gc:arc` |
15:49:08 | FromDiscord | <Zachary Carter> you can read about it here: https://nim-lang.org/blog/2020/10/15/introduction-to-arc-orc-in-nim.html |
15:50:16 | FromDiscord | <System64 ~ Flandre Scarlet> In reply to @haxscramper "I don't really know": I think Windows supports that |
15:50:28 | FromDiscord | <System64 ~ Flandre Scarlet> del command supports that for exemple |
15:55:11 | FromDiscord | <gerwy> how to delete object? Like remove it from memory |
15:55:21 | FromDiscord | <gerwy> the same as deleting pointers? |
15:56:10 | FromDiscord | <haxscramper> you are using `--gc:none`? |
15:56:17 | FromDiscord | <Rika> depends on if you mean a ref object |
15:56:39 | FromDiscord | <haxscramper> Unless you are using `gc:none` you don't need to manually remove objects from the memory, it is done automatically by the GC |
15:57:07 | FromDiscord | <gerwy> yeah but like, i need to get rid of a minion when it dies |
15:57:08 | FromDiscord | <gerwy> what do? |
15:57:22 | FromDiscord | <Rika> uh hide it |
15:57:30 | FromDiscord | <Rika> remove references to it |
15:57:37 | FromDiscord | <Rika> after that, you dont need to care about it |
15:57:46 | FromDiscord | <haxscramper> When all references are removed, object is automatically destroyed |
15:57:56 | FromDiscord | <gerwy> my game can without any issues handle over 11k of minions at the same time, but to move it to invisible place or make it invisible it will be ugly solution |
15:58:16 | FromDiscord | <gerwy> okay so how to remove reference? My only way to do it now is to delete it from sequence |
15:58:36 | FromDiscord | <haxscramper> Well, yes, that is the way to do this |
15:59:09 | FromDiscord | <gerwy> oh okay |
15:59:16 | FromDiscord | <haxscramper> Though if you often need to add/remove minons and you don't care about their storage order you can use `HashSet[Minon]` |
15:59:26 | FromDiscord | <haxscramper> Removing would be a `O(1)` operation |
15:59:54 | FromDiscord | <haxscramper> Any other solution would be worse since you would need to manually clean up all the references anyway |
16:01:18 | FromDiscord | <gerwy> there is `del` function for sequence and its also O(1) |
16:01:36 | FromDiscord | <gerwy> instead of `delete` which is O(n) |
16:02:01 | FromDiscord | <mlokis> In reply to @Zachary Carter "you shouldn't need to": thank you so match, this can actually fix my issue with multithreading in general. I made a little scheduler but as it was functional it had access to memory from different threads and that makes program very unstable and unusable. From what i understand ARC can tolerate cross thread allocations. Right? |
16:03:10 | FromDiscord | <gerwy> and also i kinda don't care about order, but at the same time, i know that minion that is the oldest will be killed always (it will be at front so of course its gonna be targeted) so i don't even need to know the index because i will just delete the first minion in index |
16:03:41 | * | crem quit (Quit: WeeChat 3.0) |
16:03:50 | FromDiscord | <Rika> In reply to @Life Sucks "there is `del` function": yes but it does not preserve sequence order |
16:03:56 | * | crem joined #nim |
16:04:07 | FromDiscord | <Rika> oh i missed last msg |
16:04:08 | FromDiscord | <zetashift> Anybody else able to generate docs for https://github.com/status-im/nim-chronos ? |
16:05:55 | FromDiscord | <haxscramper> In reply to @Life Sucks "there is `del` function": It is constant if you already know index of a minion |
16:06:07 | * | bpalmer22 joined #nim |
16:06:15 | FromDiscord | <haxscramper> If you also account for finding a minion by reference it would be linear |
16:06:47 | * | bpalmer22 quit (Remote host closed the connection) |
16:07:55 | * | ZoomZoomZoom quit (Remote host closed the connection) |
16:11:33 | * | Gana-t joined #nim |
16:11:53 | * | Gana-t quit (Remote host closed the connection) |
16:13:17 | * | overholts joined #nim |
16:13:33 | FromDiscord | <gerwy> okay so i encountered another problem hah |
16:13:50 | * | overholts quit (Remote host closed the connection) |
16:13:56 | FromDiscord | <gerwy> im deleting minion right |
16:14:05 | * | abm quit (Read error: Connection reset by peer) |
16:14:23 | FromDiscord | <gerwy> but when i do that, the size of sequence changes, and that breaks out of the loop as exception |
16:14:28 | * | abm joined #nim |
16:15:39 | FromDiscord | <gerwy> hmm i could make temporal array for minions that died this frame and loop through it at the end of frame so that it doesn't interrupt looping through seq |
16:16:05 | FromDiscord | <gerwy> its just my temporal solution but yeah sounds okay for now |
16:16:38 | FromDiscord | <haxscramper> You can't change container while iterating over the same container, so this solution is as good as you can get I think |
16:16:48 | FromDiscord | <System64 ~ Flandre Scarlet> Alright glob is very easy to use! |
16:17:38 | FromDiscord | <gerwy> In reply to @haxscramper "You can't change container": yeah, i will use pointers to minions to make it faster, i don't want to loop through the same arrays three times hah |
16:17:44 | FromDiscord | <gerwy> i need to use pointers more |
16:17:56 | FromDiscord | <System64 ~ Flandre Scarlet> sent a code paste, see https://play.nim-lang.org/#ix=3pWU |
16:18:24 | FromDiscord | <haxscramper> In reply to @Life Sucks "i need to use": are you sure? |
16:18:31 | FromDiscord | <gerwy> why not? |
16:18:54 | FromDiscord | <haxscramper> In reply to @Life Sucks "yeah, i will use": Maybe iterate once and collect all the necessary information (like died minions etc) |
16:19:04 | FromDiscord | <gerwy> yeah i know |
16:19:31 | FromDiscord | <haxscramper> In reply to @Life Sucks "why not?": Because `ref` made to reduce potential footguns, and you would have to loop though the same array using pointers anyway |
16:20:32 | FromDiscord | <gerwy> but i need to iterate through array to ↵- Make AI of minion check conditions and do something↵- Render them all |
16:20:35 | FromDiscord | <System64 ~ Flandre Scarlet> does Linux allows "" in the file names? |
16:20:57 | FromDiscord | <gerwy> idk if i could do that at the same time, kinda sounds dangerous when GPU is active and it waits for Minion to think what to do |
16:21:34 | FromDiscord | <haxscramper> In reply to @System64 "does Linux allows "*"": Yes. IIRC linux allows anything that is not a null-terminator or `/` |
16:21:57 | FromDiscord | <haxscramper> Though if you are sane you stick to `a .. z _ .` |
16:22:36 | FromDiscord | <System64 ~ Flandre Scarlet> ah yeah that's more complex so |
16:22:45 | FromDiscord | <System64 ~ Flandre Scarlet> especially for globbing |
16:25:02 | FromDiscord | <haxscramper> no, that is not more complex |
16:25:28 | FromDiscord | <haxscramper> `` will match `".txt"` just as easily as it would `"a.txt"` |
16:26:41 | FromDiscord | <System64 ~ Flandre Scarlet> and if my file is called ".txt" ? |
16:27:26 | FromDiscord | <mlokis> why would you call your file that |
16:27:45 | FromDiscord | <gerwy> oh im getting SIGSEGV |
16:27:49 | FromDiscord | <gerwy> :> |
16:28:01 | FromDiscord | <haxscramper> As I just said, file named `".????txt\n"` is perfectly valid is no different from `.saneExtension"` |
16:28:13 | FromDiscord | <haxscramper> (edit) "`.saneExtension"`" => "`saneName.saneExtension"`" |
16:28:19 | FromDiscord | <haxscramper> (edit) "`saneName.saneExtension"`" => "`"saneName.saneExtension"`" |
16:28:24 | FromDiscord | <System64 ~ Flandre Scarlet> Oh I see |
16:29:35 | FromDiscord | <haxscramper> https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_271 |
16:29:41 | FromDiscord | <mlokis> use ||regex|| |
16:31:12 | FromDiscord | <mlokis> once you learn the power of ||regex|| you will use any time possible. Simple for you, fast for everyone. |
16:31:36 | FromDiscord | <System64 ~ Flandre Scarlet> I already used regex on JS, that's useful! |
16:32:15 | FromDiscord | <mlokis> i love how nim just binds good regex libs |
16:32:38 | FromDiscord | <haxscramper> Most sensible approach |
16:33:10 | FromDiscord | <mlokis> and you can just compile regex with your program, beautiful. |
16:33:14 | FromDiscord | <System64 ~ Flandre Scarlet> I really like the scripting approach |
16:33:21 | FromDiscord | <System64 ~ Flandre Scarlet> like Python |
16:34:46 | FromDiscord | <mlokis> i em little out of context, what approach. ||i also realize that telling me is waste of time so you don't have to|| |
16:40:22 | FromDiscord | <gerwy> okay so i guess my temporal solution will be to just teleport minion far away from the map and... idk what next, i will think about it later if it will really do something to performence |
16:40:47 | FromDiscord | <gerwy> game uses only 30MB of memory, it isn't small, but it isn't also a lot so it should be fine |
16:40:55 | * | letto quit (Quit: Konversation terminated!) |
16:41:35 | * | letto joined #nim |
16:42:17 | FromDiscord | <gerwy> for some reason i can't dealloc minion ,because it gives me SIGBUS |
16:43:44 | FromDiscord | <mlokis> In reply to @Life Sucks "okay so i guess": can i see your game? |
16:45:18 | FromDiscord | <gerwy> like show a screenshot? |
16:50:43 | FromDiscord | <mlokis> In reply to @Life Sucks "like show a screenshot?": the code is enough |
16:50:58 | FromDiscord | <mlokis> i want to see how other ppl do it |
16:52:36 | FromDiscord | <mlokis> sent a code paste, see https://play.nim-lang.org/#ix=3pXc |
16:53:23 | * | ldlework quit (Ping timeout: 240 seconds) |
16:56:25 | * | ldlework joined #nim |
17:14:54 | FromDiscord | <gerwy> well the code is a mess, i don't have anything to show off |
17:33:00 | * | jken[m] joined #nim |
17:38:15 | * | sugaar4 joined #nim |
17:38:18 | * | sugaar4 quit (Remote host closed the connection) |
17:49:13 | FromDiscord | <System64 ~ Flandre Scarlet> I don't understand, I indicate [path]\\.wav as argument but it doesn't do anything in the loop https://media.discordapp.net/attachments/371759389889003532/854054886420512840/message.nim |
17:52:06 | FromDiscord | <codic> I'm curious, why is my program using 4kb more of memory when compiled with --gc:arc? (using --opt:speed and -d:danger) doesn't matter honestly i'm just curious |
17:59:18 | * | twanny796 joined #nim |
17:59:23 | * | ajeet joined #nim |
17:59:25 | * | twanny796 quit (Killed (Sigyn (Spam is off topic on freenode.))) |
17:59:43 | ajeet | hi i am new to programming and vscode. |
17:59:44 | FromDiscord | <System64 ~ Flandre Scarlet> Maybe the GC uses more RAM? |
18:00:02 | ajeet | but finished setting up nim and vscode |
18:00:51 | FromDiscord | <codic> arc doesn't have any runtime overhead iirc |
18:01:31 | ajeet | i just have a small question when i create a hello.nim program with just echo "Hello world" and press f5 i get a program in bin folder with hello.exe which is 1.6mb |
18:01:57 | ajeet | but wheni press f6 i get another hello.exe with 170kb |
18:02:06 | ajeet | so which is my program |
18:02:34 | ajeet | any help please |
18:02:46 | Prestige | What does F6 do? (I don't use vscode) |
18:03:30 | ajeet | it runs the program without any errors but gives a 160kb file |
18:04:17 | Prestige | maybe f5 builds but f6 creates a release build? |
18:05:10 | ajeet | but the same using f5 uses this debuuger method https://marketplace.visualstudio.com/items?itemName=nimsaem.nimvscode |
18:05:34 | ajeet | what is build and release build |
18:06:21 | FromGitter | <BracketMaster> can I have a function t hat returns an array, the length of which is not known at compile time? |
18:06:24 | ajeet | i just tried in cmd with nim c hello.nim |
18:06:36 | Prestige | release builds are more optimized ajeet |
18:06:37 | ajeet | and it outputed the 160kb file |
18:06:43 | Prestige | hmm not sure then |
18:06:53 | FromDiscord | <haxscramper> In reply to @BracketMaster "can I have a": return `seq` |
18:07:59 | ajeet | ok prestige so should i use f6 or use "start debugging f5" for the future |
18:08:00 | FromGitter | <BracketMaster> seq isn't quite right for my use case |
18:08:07 | FromGitter | <BracketMaster> I mean seq will work technically |
18:08:23 | Prestige | sounds like f6 is fine unless you're debugging |
18:08:36 | FromDiscord | <haxscramper> array == fixed size known at compile-time, period |
18:08:42 | ajeet | ok then thx |
18:09:02 | FromDiscord | <haxscramper> You either use array or you use seq, there is built-in in-between container (in the stdlib) |
18:09:03 | ajeet | sorry to ask such stupid questions but am new |
18:09:24 | ajeet | anyway thanks prestige |
18:09:25 | FromDiscord | <haxscramper> (edit) "You either use array or you use seq, there is ... built-in" added "no" |
18:09:26 | FromGitter | <BracketMaster> in the stdlib? |
18:09:33 | FromDiscord | <System64 ~ Flandre Scarlet> Do you know why my glob doesn't work please? |
18:09:34 | FromGitter | <BracketMaster> oh |
18:09:36 | Prestige | no worries ajeet |
18:10:06 | FromDiscord | <haxscramper> In reply to @BracketMaster "in the stdlib?": Why do you need anyway and why `seq` would work only "technically"? |
18:10:06 | ajeet | qiut |
18:10:12 | ajeet | quit |
18:10:17 | ajeet | exit |
18:10:22 | Prestige | try /quit |
18:10:32 | * | ajeet quit (Quit: ajeet) |
18:10:36 | FromDiscord | <konsumlamm> In reply to @codic "arc doesn't have any": ARC uses ref-counting, which has some overhead |
18:10:49 | FromGitter | <BracketMaster> ``myseq[someindex] = 3`` |
18:10:55 | FromGitter | <BracketMaster> doesn't work |
18:11:09 | FromGitter | <BracketMaster> ``myarr[someindex] = 4`` does work |
18:11:22 | FromGitter | <BracketMaster> I'm writing a POWERPC simulator in Nim |
18:11:23 | FromDiscord | <konsumlamm> did you declare your seq as `var`? |
18:11:29 | FromGitter | <BracketMaster> and I have a ram |
18:11:40 | FromGitter | <BracketMaster> yes, the seq is var |
18:11:51 | FromGitter | <BracketMaster> you have to use seq.del and seq.insert |
18:11:54 | FromGitter | <BracketMaster> which take a while |
18:12:00 | FromDiscord | <konsumlamm> and what exactly do you mean by "doesn't work"? |
18:12:09 | FromGitter | <BracketMaster> this slowdown is noticeable when you have a simulated ram |
18:12:14 | FromDiscord | <konsumlamm> oh, i think i know what you mean |
18:12:28 | FromDiscord | <konsumlamm> your array is initialized to zero elements |
18:12:45 | FromDiscord | <konsumlamm> (elements that are zero, not zero elements) |
18:12:52 | FromGitter | <BracketMaster> I have the user pass ram_size as a CLI |
18:13:00 | FromGitter | <BracketMaster> So ram is techinally created at runtime |
18:13:00 | FromDiscord | <haxscramper> "the length of which is not known at compile time" basically means you will suffer from additional indirection costs |
18:13:09 | FromDiscord | <konsumlamm> but your probably didn't set the capacity of the seq or initialize it somehow |
18:13:32 | FromDiscord | <konsumlamm> usually, RAM size isn't dynamic though |
18:13:41 | FromGitter | <BracketMaster> to create the seq, I use seq.add(0) until seq.len == ram_size |
18:13:43 | FromDiscord | <haxscramper> `var ram = neqSeqWith(<size>, <init-value for each element>)` |
18:13:59 | FromDiscord | <shirleyquirk> newSeqWith |
18:14:05 | FromGitter | <BracketMaster> yes - ram size never changes after simulator starts running |
18:14:07 | FromDiscord | <haxscramper> In reply to @BracketMaster "to create the seq,": This causes `log(ram_size)` reallocations IIRC |
18:14:34 | FromGitter | <BracketMaster> but I'd like to specify ram size at the CLE |
18:14:35 | FromDiscord | <haxscramper> Each one being `2^N` larger than previous one. I don't remember exact constants for nim `seq` though |
18:14:39 | FromGitter | <BracketMaster> **CLI |
18:14:51 | FromDiscord | <haxscramper> So? `newSeq...` is a runtime solution |
18:15:16 | FromDiscord | <haxscramper> But it allocates the sequence in one go instead of this `.add()` solution that causes tons of reallocations |
18:15:45 | FromDiscord | <konsumlamm> which means you don't have to use `insert` and `delete`, since the elements are already allocated |
18:15:46 | FromGitter | <BracketMaster> the manner in which I use ``var ram``is almost very nearly known at compile time |
18:15:54 | FromDiscord | <haxscramper> sent a code paste, see https://play.nim-lang.org/#ix=3pXx |
18:16:03 | FromGitter | <BracketMaster> I wish I could perhpas have a simulator config file that gets read at compile time |
18:16:14 | FromDiscord | <haxscramper> you can do this as well |
18:16:38 | FromDiscord | <haxscramper> Also you can switch at runtime between different set of fixed-sized ram configurations |
18:16:56 | FromDiscord | <mlokis> if i understand this correctly, even if i use arc normal memory safety rules that apply on default gc will apply? |
18:16:57 | FromDiscord | <haxscramper> Like you can't have arbitrary sizes, but only `32, 256, 4096kb` etc |
18:17:26 | FromGitter | <BracketMaster> right |
18:17:36 | FromGitter | <BracketMaster> how can I have a config file read at compile time? |
18:17:41 | FromGitter | <BracketMaster> I think this is the best solution |
18:17:54 | FromDiscord | <haxscramper> `let text = staticRead("config.json").parseJson()` |
18:17:55 | FromGitter | <BracketMaster> can I do this with config.nims? |
18:18:03 | FromGitter | <BracketMaster> oh |
18:18:17 | FromDiscord | <konsumlamm> In reply to @mlokis "if i understand this": ye, the only thing that might happen is a memory leak, if you have reference cycles |
18:18:34 | FromDiscord | <haxscramper> `nim.cfg` cannot be parsed at runtime because stdlib parser relies on `std/streams` that are not available at runtime |
18:18:49 | FromDiscord | <haxscramper> Maybe toml parser would work at compile-time as well, but I havent tested |
18:19:00 | FromGitter | <BracketMaster> OK - well json is fine |
18:19:01 | FromGitter | <BracketMaster> thx |
18:19:05 | FromDiscord | <mlokis> In reply to @konsumlamm "ye, the only thing": no i mean compiler is still complaining about thread unsafe code but arc is thread safe |
18:19:38 | FromDiscord | <shirleyquirk> arc ref-counting isn't atomic, if that's what you mean |
18:19:39 | FromDiscord | <konsumlamm> that's probably independent of the GC |
18:20:43 | FromDiscord | <mlokis> sent a code paste, see https://play.nim-lang.org/#ix=3pXy |
18:21:05 | FromDiscord | <konsumlamm> yes |
18:21:12 | FromDiscord | <mlokis> i em passing closure to thread |
18:21:15 | * | willyboar joined #nim |
18:21:26 | FromDiscord | <mlokis> so that is unsafe even with arc? |
18:22:19 | * | ldlework quit (Changing host) |
18:22:19 | * | ldlework joined #nim |
18:22:26 | FromDiscord | <mlokis> sent a code paste, see https://play.nim-lang.org/#ix=3pXA |
18:22:37 | FromDiscord | <treeform> @ElegantBeef it appears ptrace works on mac: https://developer.apple.com/library/archive/documentation/System/Conceptual/ManPages_iPhoneOS/man2/ptrace.2.html It compiles and runs, but its always returns 0s for me. |
18:24:58 | FromDiscord | <treeform> Also for some reason objdump format is all different and harder to parse |
18:28:45 | * | willyboar quit (Remote host closed the connection) |
18:29:18 | * | willyboar joined #nim |
18:32:26 | * | koltrast_ quit (Quit: ZNC - http://znc.in) |
18:34:11 | * | Paparaciz11 joined #nim |
18:34:21 | * | Paparaciz11 quit (Remote host closed the connection) |
18:34:23 | FromDiscord | <shirleyquirk> @mlokis not enough info to know whats going on from that snippet but anytime you use `cast` that's unsafe |
18:35:15 | FromDiscord | <mlokis> In reply to @shirleyquirk "<@343028072095809536> not enough info": yes the cast is there to prevent compiler from complaining, though i though that arc can solve this |
18:36:16 | FromDiscord | <shirleyquirk> arc allows passing gc objects between threads but im not yet sure what you're doing there, link to a longer snippet? |
18:36:54 | FromDiscord | <mlokis> important thing is that i em calling closure that can allocate memory witch should be accessible from all threads |
18:38:03 | FromDiscord | <mlokis> In reply to @shirleyquirk "arc allows passing gc": for example closure will capture a seq and thread will extend it |
18:38:30 | * | tucan joined #nim |
18:38:32 | * | tucan quit (Killed (Sigyn (Spam is off topic on freenode.))) |
18:38:39 | FromDiscord | <mlokis> if arc removes concept of thread local heap, it should be fine |
18:41:11 | FromDiscord | <shirleyquirk> everything you're saying sounds fine in theory, you're spot on re: thread-local heap, yet you're getting an error message, and that error message calling `task` a global makes me think something else is going on. |
18:42:14 | FromDiscord | <mlokis> hmm |
18:44:06 | FromDiscord | <mlokis> In reply to @shirleyquirk "everything you're saying sounds": why would be task global though, i em sending it from channel and variable exists inside a scope, i don't get it. |
18:46:22 | FromDiscord | <mlokis> sent a code paste, see https://play.nim-lang.org/#ix=3pXH |
18:46:41 | FromDiscord | <shirleyquirk> no it's not |
18:46:52 | FromDiscord | <shirleyquirk> oooohhhh |
18:46:54 | FromDiscord | <shirleyquirk> i seeeee |
18:47:23 | FromDiscord | <shirleyquirk> ok, confusing naming. but i got there eventually |
18:48:09 | FromDiscord | <mlokis> i can send full code its like 100 lines |
18:48:24 | FromDiscord | <shirleyquirk> do it on playground or something |
18:48:28 | FromDiscord | <mlokis> ok |
18:51:55 | FromDiscord | <mlokis> @shirleyquirk https://play.nim-lang.org/#ix=3pXM |
18:56:06 | FromGitter | <BracketMaster> haxscramper: I'm not sure I'm doing this right |
18:56:07 | FromGitter | <BracketMaster> https://play.nim-lang.org/#ix=3pXO |
18:56:13 | FromGitter | <BracketMaster> It complains about compile time context |
18:57:27 | FromDiscord | <haxscramper> `const config = staticRead("config.json").parseJson()` |
18:57:28 | planetis[m] | i use objdump --no-show-raw-insn -dlS but its still hard to parse, perf annotate is better |
18:59:52 | FromDiscord | <System64 ~ Flandre Scarlet> sent a code paste, see https://play.nim-lang.org/#ix=3pXP |
19:00:02 | planetis[m] | (it has the arrows and the jump that help) |
19:00:31 | FromGitter | <BracketMaster> haxscramper: ``Error: invalid type: 'JsonNode' for const`` |
19:01:08 | FromDiscord | <haxscramper> Then read config to `const string` and then parse it at runtime |
19:01:44 | FromGitter | <BracketMaster> well heh, I'm trying to create an array at compiletime, who's length is specified in config.json |
19:02:32 | FromDiscord | <haxscramper> sent a code paste, see https://play.nim-lang.org/#ix=3pXS |
19:03:13 | FromDiscord | <carpal> `nim a.nim -o a.c -nohints`? |
19:03:19 | FromDiscord | <carpal> right command? |
19:03:26 | FromDiscord | <carpal> --hints:off |
19:03:27 | FromDiscord | <carpal> (edit) "--hints:off" => "--hints:off?" |
19:03:35 | FromDiscord | <carpal> -c to generate c |
19:03:43 | FromDiscord | <carpal> but it generates c into a cache path |
19:03:59 | FromDiscord | <carpal> I need to have it in the local folder, without any other command |
19:04:53 | FromDiscord | <System64 ~ Flandre Scarlet> In reply to @haxscramper "Can you print `args[0]`": it prints ``C:\Users\user\Music\samples\SNES Samples - Copie\.wav`` |
19:05:49 | FromDiscord | <haxscramper> idk then, try to debug it in parts |
19:07:13 | FromDiscord | <System64 ~ Flandre Scarlet> does glob only works with const? |
19:09:56 | * | zsoltiv joined #nim |
19:09:57 | * | zsoltiv quit (Client Quit) |
19:10:15 | * | zsoltiv joined #nim |
19:15:55 | * | ZoomZoomZoom joined #nim |
19:16:19 | ZoomZoomZoom | Could anyone confirm this? https://github.com/nim-lang/Nim/issues/18210 |
19:17:05 | ZoomZoomZoom | Had some idea I wanted to explore and bumped into this like in the first 3 minutes :( |
19:19:35 | * | willyboa_ joined #nim |
19:21:42 | * | willyboar quit (Ping timeout: 245 seconds) |
19:23:38 | FromGitter | <BracketMaster> haxscramper: I'm assuming you weren't responding to me? : https://play.nim-lang.org/#ix=3pXS |
19:23:41 | FromDiscord | <System64 ~ Flandre Scarlet> In reply to @haxscramper "idk then, try to": Okay I found the problem and I think I should report this bug↵glob don't like the ``\`` character |
19:27:56 | FromDiscord | <System64 ~ Flandre Scarlet> https://github.com/citycide/glob/issues/57↵Reported |
19:29:05 | * | willyboa_ quit () |
19:29:12 | FromDiscord | <haxscramper> In reply to @System64 "https://github.com/citycide/glob/issues/57 Reported": It would be nice to also provide reproducible code sample with expected/got comparison instead of leaving library author to figure out what was wrong in your code |
19:30:14 | FromDiscord | <haxscramper> And "doesn't work properly" is so vague anyway ..., like define "properly" and "works fine" at least (again got/expected) |
19:30:23 | FromDiscord | <haxscramper> (edit) "And "doesn't work properly" is so vague anyway ..., like ... define" added "at least" |
19:35:12 | FromGitter | <BracketMaster> are you allowed to have procs on generic arrays? |
19:35:13 | FromGitter | <BracketMaster> https://play.nim-lang.org/#ix=3pY0 |
19:37:44 | FromDiscord | <shirleyquirk> @mlokis the problem was the compiler wasn't correctly inferring the safety of the task closure. something something phase ordering something something ask Araq. |
19:38:21 | FromDiscord | <mlokis> hmmmm |
19:38:26 | FromGitter | <BracketMaster> oh - you have to use openarray |
19:38:39 | FromDiscord | <shirleyquirk> the happy news is, annotate `Task` as {.closure,gcsafe.} and all's well |
19:38:53 | FromDiscord | <shirleyquirk> i.e. it compiles. |
19:41:14 | FromDiscord | <brainproxy> sent a long message, see http://ix.io/3pY2 |
19:41:36 | FromDiscord | <shirleyquirk> but this has the same effect whether or not you use gc:arc. |
19:41:37 | FromDiscord | <brainproxy> so it seems somehow the threadvar setup is affecting the ability to check `isNil` on the field |
19:42:05 | FromDiscord | <brainproxy> (edit) "http://ix.io/3pY2" => "http://ix.io/3pY4" |
19:43:47 | FromDiscord | <konsumlamm> In reply to @BracketMaster "are you allowed to": you are, you have to use `[N: static int]` instead of `[T]` (using N instead of T makes the intent clearer), so that the parameter is a (statically known) int, instead of a type |
19:43:54 | FromDiscord | <shirleyquirk> @mlokis https://play.nim-lang.org/#ix=3pY5 |
19:43:54 | FromDiscord | <konsumlamm> but `openArray` also works |
19:45:14 | FromDiscord | <System64 ~ Flandre Scarlet> I want to read something at a precise offset of a file, how can I do that please? |
19:48:10 | FromDiscord | <haxscramper> In reply to @System64 "How can I read": . |
19:48:24 | FromDiscord | <haxscramper> You've asked literally the same question already |
19:48:33 | FromDiscord | <System64 ~ Flandre Scarlet> ah yeah sorry |
19:48:44 | * | rockcavera quit (Read error: Connection reset by peer) |
19:49:51 | * | rockcavera joined #nim |
19:51:56 | FromDiscord | <mlokis> In reply to @shirleyquirk "<@!343028072095809536> https://play.nim-lang.org/#i": thanx |
19:52:34 | FromDiscord | <shirleyquirk> pleasure. |
19:56:17 | * | rockcavera quit (Read error: Connection reset by peer) |
19:57:35 | * | rockcavera joined #nim |
20:02:48 | * | zsoltiv quit (Quit: zsoltiv) |
20:08:46 | FromDiscord | <ElegantBeef> In reply to @treeform "<@!145405730571288577> it appears ptrace": The default user may not be allowed to ptrace programs so may need to run hottie as sudo(or equivlent) |
20:13:16 | FromDiscord | <gerwy> okay i fixed my bug with that sequence, now when minion is dead, it gets teleported and after that it gets deleted from seq :3 |
20:13:23 | FromDiscord | <ElegantBeef> Grats |
20:13:39 | FromDiscord | <gerwy> CC: https://media.discordapp.net/attachments/371759389889003532/854091232824655872/Nagranie_z_ekranu_2021-06-14_o_22.08.50.mov |
20:13:49 | FromDiscord | <gerwy> there are only 10 days left and i have so little.... |
20:14:13 | FromDiscord | <ElegantBeef> I havent touched my project in days so ya 😄 |
20:18:22 | FromDiscord | <gerwy> well i have no music no sound effect and no sprites, only this bones so yeaah, need to work on UI a little too, good that i managed to fix some stuff |
20:22:41 | FromDiscord | <codic> https://github.com/nim-lang/Nim/issues/18130 should I work around this manually by putting in =destroy myself ? |
20:22:52 | FromDiscord | <codic> (edit) "?" => "if I cast?" |
20:24:45 | * | willyboar joined #nim |
20:25:29 | FromDiscord | <ElegantBeef> I dont get why you'd cast one to the other, but if you must probably |
20:25:37 | planetis[m] | thats a nasty one, can you maybe use openarrays in your code instead? |
20:26:14 | planetis[m] | there is toOpenArrayByte for example |
20:26:26 | FromDiscord | <ElegantBeef> I'd like to see what you're casting/why |
20:26:31 | planetis[m] | but not toOpenarrayChar for some reason |
20:28:12 | * | willyboar quit (Client Quit) |
20:31:17 | * | Vladar quit (Ping timeout: 258 seconds) |
20:48:16 | FromDiscord | <treeform> In reply to @ElegantBeef "The default user may": Tried `sudo`, same results i only get 1 sample and its all zeros. |
20:49:10 | FromDiscord | <ElegantBeef> Maybe attach is different on mac |
20:49:32 | FromDiscord | <ElegantBeef> Rather bsd i guess |
20:51:01 | FromDiscord | <ElegantBeef> If attaching fails it doesnt fetch register properly, so that could be an issue |
20:57:37 | FromDiscord | <ElegantBeef> @treeform looking around it seems that freebsd uses a different register struct aswell, https://gitweb.dragonflybsd.org/dragonfly.git/blob/master:/sys/cpu/x86_64/include/reg.h |
21:00:49 | FromDiscord | <ElegantBeef> If the FreeBSD source is any indication seems that it uses `16` for the ptrace attach https://github.com/freebsd/freebsd-src/blob/373ffc62c158e52cde86a5b934ab4a51307f9f2e/sys/amd64/linux/linux_ptrace.c#L66 |
21:01:05 | FromDiscord | <ElegantBeef> Whereas 64bit linux uses 12 |
21:02:18 | FromDiscord | <ElegantBeef> So i'd try doing `echo ptrace(16, pid, 0, nil)` and seeing what you get |
21:08:10 | FromDiscord | <treeform> In reply to @ElegantBeef "<@!107140179025735680> looking around it": I can't look into ti right now. But I will look into it later. |
21:18:45 | Prestige | I'm using a switch("import", "./testutils") for my test config.nims but it complains about that import being unused in every module. Is there a better way to have this import just in the test file I'm running? |
21:29:58 | FromDiscord | <codic> sent a code paste, see https://play.nim-lang.org/#ix=3pYs |
21:30:28 | FromDiscord | <codic> probably all my casts will be with C apis that dont have any =destroy otehr than the default anyways |
21:37:09 | * | revere quit (*.net *.split) |
21:37:09 | * | Zevv quit (*.net *.split) |
21:37:09 | * | idxu quit (*.net *.split) |
21:37:09 | * | jken quit (*.net *.split) |
21:37:09 | * | ldlework quit (*.net *.split) |
21:37:09 | * | Araq quit (*.net *.split) |
21:37:09 | * | snowolf quit (*.net *.split) |
21:37:09 | * | so quit (*.net *.split) |
21:37:09 | * | mahlon quit (*.net *.split) |
21:37:09 | * | Northstrider[m] quit (*.net *.split) |
21:37:09 | * | zopsi quit (*.net *.split) |
21:37:09 | * | JStoker quit (*.net *.split) |
21:37:09 | * | beatmox quit (*.net *.split) |
21:37:09 | * | fredsted quit (*.net *.split) |
21:37:09 | * | Amun_Ra quit (*.net *.split) |
21:37:09 | * | ebb quit (*.net *.split) |
21:37:09 | * | skelett quit (*.net *.split) |
21:37:09 | * | Yardanico quit (*.net *.split) |
21:37:09 | * | fantis quit (*.net *.split) |
21:37:09 | * | motersen_ quit (*.net *.split) |
21:37:09 | * | grobe0ba quit (*.net *.split) |
21:37:09 | * | ForumUpdaterBot quit (*.net *.split) |
21:37:09 | * | literal quit (*.net *.split) |
21:38:30 | * | NicolasCARPi[m]1 joined #nim |
21:39:04 | * | NicolasCARPi[m]1 quit (Remote host closed the connection) |
21:41:15 | * | fowl quit (Ping timeout: 248 seconds) |
21:44:06 | * | Jjp137 quit (Read error: Connection reset by peer) |
21:44:10 | FromDiscord | <ElegantBeef> Yea no point unless there is a custom destroy or it's managed it seems |
21:47:28 | * | fowl joined #nim |
21:49:18 | * | Jjp137 joined #nim |
21:55:42 | FromGitter | <BracketMaster> ``map`` in sequtils is nice. I wonder if there is a way to observe the index of the seq/array element being mapped? |
21:56:15 | FromDiscord | <ElegantBeef> You could use collect for that |
22:07:27 | FromGitter | <BracketMaster> thx. collect does the trick |
22:16:57 | * | pevik__26 joined #nim |
22:17:29 | * | pevik__26 quit (Remote host closed the connection) |
22:19:13 | * | easycream11 joined #nim |
22:19:33 | * | easycream11 quit (Remote host closed the connection) |
22:48:24 | * | datasmurf joined #nim |
22:48:57 | * | datasmurf quit (Remote host closed the connection) |
22:56:13 | * | ultima-phone joined #nim |
22:56:43 | * | ultima-phone quit (Remote host closed the connection) |
22:57:13 | * | voltist3 joined #nim |
23:00:04 | * | Jjp137 quit (*.net *.split) |
23:00:04 | * | jken[m] quit (*.net *.split) |
23:00:04 | * | krux02 quit (*.net *.split) |
23:00:04 | * | Saemsays[m] quit (*.net *.split) |
23:00:05 | * | asdflkj quit (*.net *.split) |
23:00:05 | * | vegai quit (*.net *.split) |
23:00:05 | * | Edoardo[m]11 quit (*.net *.split) |
23:00:05 | * | Zoom[m]1 quit (*.net *.split) |
23:00:05 | * | customer[m]1 quit (*.net *.split) |
23:00:05 | * | stisa1 quit (*.net *.split) |
23:00:05 | * | Benjamin[m]121 quit (*.net *.split) |
23:00:05 | * | dithpri[m]1 quit (*.net *.split) |
23:00:05 | * | nxnl[m]1 quit (*.net *.split) |
23:00:05 | * | fbpyr[m]1 quit (*.net *.split) |
23:00:05 | * | stefantalpalaru quit (*.net *.split) |
23:00:05 | * | Gustavo6046 quit (*.net *.split) |
23:00:05 | * | mjsir911 quit (*.net *.split) |
23:00:05 | * | termer quit (*.net *.split) |
23:00:05 | * | Fish-Face quit (*.net *.split) |
23:00:05 | * | zuckerberg[m] quit (*.net *.split) |
23:00:05 | * | Gambit[m] quit (*.net *.split) |
23:00:05 | * | Hasnep[m] quit (*.net *.split) |
23:00:05 | * | Sappy[m] quit (*.net *.split) |
23:00:05 | * | BusterBlue[m] quit (*.net *.split) |
23:00:05 | * | bfgcoding[m] quit (*.net *.split) |
23:00:05 | * | k0mpjut0r quit (*.net *.split) |
23:00:05 | * | Avahe[m] quit (*.net *.split) |
23:00:05 | * | Clonkk[m] quit (*.net *.split) |
23:00:05 | * | Avatarfighter[m] quit (*.net *.split) |
23:00:05 | * | leorize[m] quit (*.net *.split) |
23:00:05 | * | reversem3 quit (*.net *.split) |
23:00:05 | * | lnxw37d4 quit (*.net *.split) |
23:00:05 | * | Prestige quit (*.net *.split) |
23:00:05 | * | FromGitter quit (*.net *.split) |
23:00:42 | * | hyiltiz_ joined #nim |
23:01:28 | * | hyiltiz quit (Ping timeout: 252 seconds) |
23:01:28 | * | casaca quit (Ping timeout: 252 seconds) |
23:01:28 | * | voltist quit (Ping timeout: 252 seconds) |
23:01:29 | * | voltist3 is now known as voltist |
23:02:19 | * | fowl quit (Ping timeout: 248 seconds) |
23:11:05 | * | NimBot joined #nim |
23:11:14 | * | ee7[m] joined #nim |
23:11:52 | * | crem quit (Ping timeout: 260 seconds) |
23:12:20 | * | fowl joined #nim |
23:12:26 | * | crem joined #nim |
23:12:50 | * | ee7[m] quit (Changing host) |
23:12:50 | * | ee7[m] joined #nim |
23:13:05 | * | a_b_m joined #nim |
23:13:06 | * | a_b_m quit (Remote host closed the connection) |
23:16:24 | * | abm quit (Ping timeout: 240 seconds) |
23:17:29 | * | spiderstew quit (*.net *.split) |
23:17:29 | * | Q-Master quit (*.net *.split) |
23:17:29 | * | FromDiscord quit (*.net *.split) |
23:17:29 | * | lain quit (*.net *.split) |
23:17:29 | * | dom96 quit (*.net *.split) |
23:17:29 | * | cornfeedhobo quit (*.net *.split) |
23:17:36 | * | Q-Master joined #nim |
23:17:39 | * | spiderstew joined #nim |
23:17:42 | * | dom96 joined #nim |
23:17:45 | * | dom96 quit (Changing host) |
23:17:45 | * | dom96 joined #nim |
23:17:49 | * | FromDiscord joined #nim |
23:18:01 | * | lain joined #nim |
23:20:16 | * | gearnode joined #nim |
23:20:24 | * | gearnode quit (Remote host closed the connection) |
23:22:35 | * | fowl quit (*.net *.split) |
23:25:48 | * | cornfeedhobo joined #nim |
23:38:04 | * | lain quit (*.net *.split) |
23:38:04 | * | dom96 quit (*.net *.split) |
23:38:04 | * | Q-Master quit (*.net *.split) |
23:38:04 | * | ryanhowe quit (*.net *.split) |
23:38:04 | * | SunDwarf quit (*.net *.split) |
23:38:17 | * | SunDwarf joined #nim |
23:38:19 | * | Q-Master joined #nim |
23:38:21 | * | sacredfrog joined #nim |
23:38:32 | * | lain joined #nim |
23:40:24 | * | lain quit (*.net *.split) |
23:40:24 | * | sacredfrog quit (*.net *.split) |
23:40:24 | * | xace quit (*.net *.split) |
23:40:24 | * | hpyc9 quit (*.net *.split) |
23:40:24 | * | SteveMarathon[m] quit (*.net *.split) |
23:40:24 | * | gemath[m] quit (*.net *.split) |
23:40:24 | * | konradmb[m] quit (*.net *.split) |
23:40:24 | * | CodeBitCookie[m] quit (*.net *.split) |
23:40:24 | * | bluemax[m] quit (*.net *.split) |
23:40:24 | * | asrp[m] quit (*.net *.split) |
23:40:24 | * | npham[m] quit (*.net *.split) |
23:40:25 | * | planetis[m] quit (*.net *.split) |
23:40:25 | * | MTRNord quit (*.net *.split) |
23:40:25 | * | Guest007[m] quit (*.net *.split) |
23:40:25 | * | goblinslayer[m] quit (*.net *.split) |
23:40:35 | * | hpyc9 joined #nim |
23:40:37 | * | asrp[m] joined #nim |
23:40:41 | * | xace joined #nim |
23:40:42 | * | sacredfrog joined #nim |
23:40:44 | * | bluemax[m] joined #nim |
23:40:44 | * | gemath[m] joined #nim |
23:40:51 | * | CodeBitCookie[m] joined #nim |
23:40:53 | * | lain joined #nim |
23:41:00 | * | SteveMarathon[m] joined #nim |
23:41:33 | * | goblinslayer[m] joined #nim |
23:41:49 | * | konradmb[m] joined #nim |
23:41:51 | * | Guest007[m] joined #nim |
23:42:17 | * | MTRNord joined #nim |
23:42:49 | * | planetis[m] joined #nim |
23:44:20 | * | dom96 joined #nim |
23:44:20 | * | dom96 quit (Changing host) |
23:44:20 | * | dom96 joined #nim |
23:44:42 | * | npham[m] joined #nim |
23:47:04 | * | hut joined #nim |
23:47:30 | * | hut quit (Remote host closed the connection) |