00:14:24 | * | xet7 joined #nim |
00:14:59 | * | bcksl joined #nim |
00:41:17 | * | bcksl quit (Quit: \) |
00:45:01 | * | bcksl joined #nim |
00:45:49 | * | bcksl quit (Remote host closed the connection) |
00:46:31 | FromDiscord | <girvo> Anyone doing UDP multicast in Nim? Seems the IPv4 versions of the membership structs and such are missing (as well as IP_ADD_MEMBERSHIP et al) in terms of the std/net and std/posix bindings? |
00:49:32 | * | bcksl joined #nim |
01:17:40 | * | xet7 quit (Remote host closed the connection) |
01:36:31 | * | adigitoleo quit (*.net *.split) |
01:38:23 | * | adigitoleo joined #nim |
01:38:28 | * | adigitoleo quit (*.net *.split) |
01:38:37 | * | adigitoleo joined #nim |
01:38:41 | * | adigitoleo quit (Max SendQ exceeded) |
01:38:52 | * | adigitoleo joined #nim |
03:05:59 | * | edr quit (Quit: Leaving) |
04:06:39 | * | derpydoo quit (Read error: Connection reset by peer) |
05:03:27 | * | rockcavera quit (Remote host closed the connection) |
05:06:12 | * | tinystoat quit (Server closed connection) |
05:06:21 | * | tinystoat joined #nim |
05:40:34 | * | jmdaemon joined #nim |
06:07:12 | FromDiscord | <odexine> In reply to @chronos.vitaqua "> If much less": How much memory do you have available? |
06:10:46 | FromDiscord | <nnsee> In reply to @chronos.vitaqua "I can't change the": as someone who contributes to owasp, trust me when I say that the recommendations there are embarrassingly low and need to be revisited |
06:26:20 | FromDiscord | <Chronos [She/Her]> Fair :p |
06:26:37 | FromDiscord | <Chronos [She/Her]> In reply to @odexine "How much memory do": 26 GB but this is for testing |
07:05:35 | * | PMunch joined #nim |
07:18:23 | * | redj quit (Remote host closed the connection) |
07:19:45 | * | redj joined #nim |
08:27:53 | * | redj quit (Quit: No Ping reply in 180 seconds.) |
08:29:25 | * | redj joined #nim |
11:15:02 | * | computerquip quit (Server closed connection) |
11:15:18 | * | computerquip joined #nim |
12:41:21 | * | edr joined #nim |
12:46:16 | arkanoid | by reading nim code of vscode extension from saem, I see that importc and importcpp con be used also when targeting js. What use is this? https://github.com/saem/vscode-nim/blob/main/src/platform/vscodeApi.nim |
12:46:43 | * | dtomato joined #nim |
13:00:42 | FromDiscord | <ringabout> It is just used for interfacing JS types and functions. Though, `{.importjs` should be preferred when interfacing with JS functions. |
13:03:18 | arkanoid | yeah I see it from https://github.com/juancarlospaco/nodejs/blob/main/src/nodejs/jscore.nim |
13:35:24 | arkanoid | I don't understand how js ffi works in this context. How this type def uses {.importc.} with no specific name, but the real name is different? https://github.com/saem/vscode-nim/blob/d77dc7cfad68cecbd4fcf2b8dfd85f1927065c8b/src/platform/vscodeApi.nim#L10 https://github.com/DefinitelyTyped/DefinitelyTyped/blob/df8b6b7613a23ed5fa3aac8c9a8db35d9b87462e/types/vscode/index.d.ts#L2938 |
13:36:10 | arkanoid | I mean "VscodeMarkdownStringObj {.importc.} = object of JsObject" VS "export class MarkdownString { ... }" |
13:39:14 | FromDiscord | <jmgomez> It doesnt seem to make a difference in types |
13:39:59 | arkanoid | but the name is different |
13:41:21 | arkanoid | I understand that the required field does match, and interpretation could run correctly, but then why the {.importc.} |
13:42:08 | FromDiscord | <jmgomez> it does make a difference in `proc` it adds the `infix` flag to it |
13:43:15 | FromDiscord | <jmgomez> so yes, I guess it should be `importjs` everywhere as ringabout pointed out |
13:59:47 | * | gooba_ quit (Quit: Leaving) |
14:00:02 | * | gooba joined #nim |
14:05:11 | * | gooba quit (Remote host closed the connection) |
14:05:33 | * | gooba joined #nim |
14:28:15 | * | PMunch_ joined #nim |
14:31:07 | * | PMunch quit (Ping timeout: 264 seconds) |
15:01:01 | FromDiscord | <taperfade> Guys |
15:01:04 | FromDiscord | <taperfade> Lets just say |
15:01:26 | FromDiscord | <taperfade> How do i send commands through a socket |
15:01:35 | FromDiscord | <taperfade> Commands to cmd.exe |
15:01:42 | FromDiscord | <taperfade> And have me get the response |
15:01:49 | FromDiscord | <taperfade> :meoww: |
15:06:22 | PMunch_ | How about doing something more productive than writing malware? |
15:07:40 | FromDiscord | <ieltan> lol |
15:08:10 | FromDiscord | <taperfade> In reply to @PMunch_ "How about doing something": Im not smart enough |
15:08:12 | FromDiscord | <taperfade> :( |
15:09:35 | * | PMunch_ quit (Quit: Leaving) |
15:13:59 | FromDiscord | <pmunch> I have a simple project if you want the exercise. Read the output of du -h from a file, then create small tool to navigate and find big folders/files |
15:14:15 | FromDiscord | <pmunch> Bonus point for an interface like baobab |
15:14:33 | FromDiscord | <pmunch> But it could also be TUI based |
15:15:52 | arkanoid | jmgomez, sorry but I didn't get it. What do you mean? how does importc adds that infix? |
15:15:57 | arkanoid | sorry, prefix |
15:18:42 | FromDiscord | <taperfade> In reply to @pmunch "I have a simple": du -h ? |
15:39:47 | FromDiscord | <jmgomez> In reply to @arkanoid "<@726017160115126333>, sorry but I": https://github.com/nim-lang/Nim/blob/devel/compiler/pragmas.nim#L910 |
15:50:09 | arkanoid | jmgomez, I still don't get it. Do not worry, my fault. |
15:52:36 | FromDiscord | <pmunch> In reply to @taperfade "du -h ?": https://www.geeksforgeeks.org/du-command-linux-examples/ |
15:57:04 | FromDiscord | <jmgomez> It adds that flag to the `proc` that uses it which quoting the doc in the compiler indicates: ↵> symbol needs infix call syntax in target language; for interfacing with C++, JS |
16:06:29 | arkanoid | I'm so far from understanding it, that I don't know why you are talking about procs and infix call syntax, when the question is about type importc implicit name that differs from the imported one |
16:11:09 | FromDiscord | <jmgomez> Im just highlighting the differences between `importc` and `importjs`. I should have use the reply rather than just commenting though, because I wasnt answering the question you asked above |
16:12:39 | FromDiscord | <jmgomez> That said, AFAIK the final js is untyped so the name doesnt matter |
16:14:11 | FromDiscord | <jmgomez> well a better wording would be it doesnt care about the types as it treats everything as a dictionary |
16:14:31 | FromDiscord | <jmgomez> I didnt play too much with js anyways, so I may be wrong |
16:19:01 | Amun-Ra | pmunch: why '-h'? |
17:21:14 | FromDiscord | <pmunch> Eh, that's just always what I usually run 😛 |
17:23:56 | Amun-Ra | it makes parsing harder :P |
18:02:58 | FromDiscord | <ieltan> sent a code paste, see https://play.nim-lang.org/#ix=4KVO |
18:03:40 | FromDiscord | <leorize> no, only some operators are paired |
18:04:31 | FromDiscord | <ieltan> 😢 |
18:04:33 | FromDiscord | <ieltan> sadge |
18:11:04 | * | systemdsucks quit (Server closed connection) |
18:11:14 | * | systemdsucks joined #nim |
18:14:14 | * | syl quit (Quit: C-x C-c) |
18:19:17 | * | syl joined #nim |
18:22:49 | * | oisota quit (Quit: Ping timeout (120 seconds)) |
18:23:08 | * | oisota joined #nim |
18:34:23 | * | neceve joined #nim |
19:40:03 | * | via quit (Server closed connection) |
19:40:10 | * | via joined #nim |
19:40:26 | FromDiscord | <aintea> sent a code paste, see https://play.nim-lang.org/#ix=4KW7 |
19:40:41 | FromDiscord | <aintea> Or something that lets me destructure an object |
19:41:30 | FromDiscord | <odexine> no |
19:45:41 | FromDiscord | <aintea> So I can't |
19:45:45 | FromDiscord | <aintea> 😔 |
19:46:00 | FromDiscord | <aintea> I tought that anything that could be tought, could be programmed in Nim |
19:50:00 | FromDiscord | <inventormatt> you could probably create a macro that does that |
19:57:12 | FromDiscord | <JJ> you'll have to put up with calling it something other than `let` but that is how ex. `fusion/matching` works, yeah |
20:40:27 | FromDiscord | <.aingel.> In reply to @pmunch "Bonus point for an": Whats baobab? |
20:41:59 | FromDiscord | <pmunch> In reply to @.aingel. "Whats baobab?": https://wiki.gnome.org/action/show/Apps/DiskUsageAnalyzer?action=show&redirect=Apps%2FBaobab |
20:58:17 | FromDiscord | <.aingel.> Ooh gotcha |
20:58:56 | FromDiscord | <bostonboston> In a importcpp statement is there a way to ignore a parameter, I know `'i` will give you the i'th type, but I'd there an equivalent for i'th value |
20:59:21 | FromDiscord | <pmunch> In reply to @aintea "So I can't": Maybe with a term rewriting macro |
20:59:32 | FromDiscord | <pmunch> But that's pretty hairy stuff |
21:03:13 | FromDiscord | <bostonboston> In reply to @bostonboston "In a importcpp statement": I suppose I can `/#/` in some cases |
21:22:42 | FromDiscord | <aintea> In reply to @pmunch "But that's pretty hairy": Yeah but I wanted to see how far I could go trying to make nim a functional language |
21:22:49 | FromDiscord | <aintea> For example for linked lists |
21:30:54 | * | LuxuryMode joined #nim |
21:37:11 | * | raynei joined #nim |
21:40:47 | FromDiscord | <pmunch> In reply to @aintea "Yeah but I wanted": I mean the features are there, but the syntax might be tricky |
21:41:16 | FromDiscord | <pmunch> Hmm, what happens if you have a converter to a tuple, does your unpack sample work then? |
21:41:32 | FromDiscord | <aintea> How could I get all the fields from the class |
21:41:49 | FromDiscord | <aintea> I need to get them manually ? |
21:42:07 | FromDiscord | <aintea> I need to hardcode them ? Or is there a function to get them |
21:43:12 | * | raynei quit (Ping timeout: 255 seconds) |
21:44:36 | FromDiscord | <pmunch> Damn it, a converter doesn't work.. |
21:44:54 | * | lucasta joined #nim |
21:45:08 | FromDiscord | <pmunch> You can iterate over the fields of an object, at least in a macro |
21:45:42 | FromDiscord | <aintea> I really can iterate over the fields of an object in a macro ? |
21:46:04 | FromDiscord | <aintea> Could I have some examples ? I think your method might work |
21:46:04 | Amun-Ra | yes |
21:47:51 | Amun-Ra | aintea: that was one of my very first macros I did so it may not be the best/clear/etc. https://github.com/amnr/dynlibutils |
21:48:20 | FromDiscord | <aintea> Thanks, I'm gonna take a look at it tomorrow |
21:48:44 | FromDiscord | <aintea> Thank you guys, I think it might work with all information you provided me |
21:49:21 | Amun-Ra | no worries, have fun with macros |
21:50:10 | * | neceve quit (Ping timeout: 258 seconds) |
21:52:25 | Amun-Ra | what I must add if to support when foo: […] during iteration |
21:52:36 | Amun-Ra | is* |
21:53:28 | * | raynei joined #nim |
22:03:56 | FromDiscord | <Elegantbeef> A very macro averse unpack solution https://play.nim-lang.org/#ix=4KWw |
22:04:04 | FromDiscord | <Elegantbeef> Thought I had this laying around but I did not |
22:04:05 | FromDiscord | <Elegantbeef> Yet another thing to add to my wiki 😄 |