01:00:02 | * | nazgulsenpai quit (Quit: ZNC 1.8.2 - https://znc.in) |
01:03:27 | * | nazgulsenpai joined #nim |
01:27:05 | * | krux02 quit (Remote host closed the connection) |
07:02:51 | * | coldfeet joined #nim |
07:37:37 | * | ntat joined #nim |
08:58:10 | * | coldfeet quit (Remote host closed the connection) |
09:19:59 | * | coldfeet joined #nim |
09:23:47 | FromDiscord | <orzogc> Can the official vscode extension format codes on save? I didn't get it to work. |
09:26:54 | FromDiscord | <zumi.dxy> there's a separate unofficial extension called `nph` |
09:27:00 | FromDiscord | <zumi.dxy> that will do the formatting for you |
09:32:28 | FromDiscord | <orzogc> I get it, thanks |
09:38:42 | * | beholders_eye joined #nim |
09:49:21 | * | beholders_eye quit (Ping timeout: 256 seconds) |
09:51:29 | * | beholders_eye joined #nim |
09:57:15 | * | beholders_eye quit (Ping timeout: 264 seconds) |
10:04:21 | FromDiscord | <kots> sent a code paste, see https://play.nim-lang.org/#pasty=REmFOusd |
10:05:14 | FromDiscord | <zumi.dxy> how does it change? |
10:05:40 | FromDiscord | <kots> no more ugly double-indent when splitting a long parameter list into multiple lines, and no more separating parameters with commas |
10:22:17 | * | ntat quit (Quit: Leaving) |
10:29:29 | FromDiscord | <zumi.dxy> i kinda see the point of the double indent as awful as it looks |
11:27:07 | NimEventer | New thread by phoenix27: Problem with object oriented programming, see https://forum.nim-lang.org/t/11829 |
11:53:21 | FromDiscord | <amjadhd> Why is sort `cmp` declared with `{.closure.}` ? |
11:53:37 | FromDiscord | <amjadhd> (edit) "?" => "?↵https://github.com/nim-lang/Nim/blob/830153323af0fce9ca5c73030c2374f03367a412/lib/pure/algorithm.nim#L369" |
11:55:33 | FromDiscord | <kots> At the risk of stating the obvious... So that you can pass closures in? |
12:00:22 | FromDiscord | <amjadhd> In reply to @k0ts "At the risk of": You can pass them without: https://play.nim-lang.org/#pasty=EtwasfLh. |
12:01:25 | FromDiscord | <Phil> In reply to @amjadhd "Why is sort `cmp`": Otherwise it would assume the proc your passing in is Nimcall, which would mean it couldn't accept a closure as those come with an environment of variables they capture, unlike Nimcall procs |
12:02:22 | FromDiscord | <Phil> Since a Nimcall proc can easily be converted into a closure without logic changes one could argue there should be some kind of converter that allows Nimcall procs everywhere that closures are specified |
12:02:29 | FromDiscord | <Phil> Sadly we don't have that |
12:02:49 | FromDiscord | <kots> In reply to @amjadhd "You can pass them": Looks like it was added before closure became the default calling convention for proc types, judging by this commit message:↵https://github.com/nim-lang/Nim/commit/8d99753d6320489e4de8cf186415b0a7be8260b4#diff-cbc4d5016c6d92af2c107522f0312d77f3935fa34c90e433dbcfba6f2138d159 |
12:02:54 | FromDiscord | <Phil> So it's a closure to accept the maximum possible types of procs |
12:04:13 | FromDiscord | <Phil> In reply to @k0ts "Looks like it was": Whether closure or Nimcall is the default heavily depends on which syntax you're in. ↵Iirc in a type declaration it assumes closure automatically. ↵In top level procs it assumes Nimcall.↵I forgot what it assumes for procs defined in procs |
12:05:00 | FromDiscord | <kots> Default is closure for proc types:↵https://wandbox.org/permlink/Di8Eht1VtCf0iBmp |
12:06:00 | FromDiscord | <Phil> In reply to @k0ts "Default is closure for": As a pro parameter.↵I would not bet that foo is a closure |
12:06:05 | FromDiscord | <ieltan> In reply to @k0ts "Default is closure for": well you're creating a lambda which is a closure in this case |
12:06:11 | FromDiscord | <Phil> (edit) "pro parameter.↵I" => "proc parameter of foo.↵I" |
12:06:44 | FromDiscord | <Robyn [She/Her]> In reply to @isofruit "Whether closure or Nimcall": Ooooh so that's why I need to explicitly cast my functions to my Parser type, but weirdly enough this only applies for varargs |
12:07:22 | FromDiscord | <kots> https://wandbox.org/permlink/uqIWoIULXXyKkjh3 |
12:07:23 | FromDiscord | <ieltan> i think this part of Nim sucks so much lol |
12:07:27 | FromDiscord | <kots> It's still a closure guys |
12:07:48 | FromDiscord | <kots> (edit) "a" => "~~a~~" |
12:08:08 | FromDiscord | <Phil> Calling convention between Nimcall and Closure is one of those things that ideally would be transparent |
12:08:19 | FromDiscord | <Robyn [She/Her]> In reply to @ieltan "i think this part": The fact nimcall is distinct from closure? |
12:08:49 | FromDiscord | <Phil> In reply to @k0ts "It's still ~~a~~ closure": You're still passing it into the proc, messaging Nim likely does the calling convention of closure implicitly. ↵Try the same echo for foo itself |
12:09:06 | FromDiscord | <Phil> (edit) "messaging" => "meaning" |
12:09:21 | FromDiscord | <ieltan> In reply to @chronos.vitaqua "The fact nimcall is": the fact that you think you're passing a nimcall but it's actually closure |
12:09:42 | FromDiscord | <ieltan> and you need to anotate `{.nimcall.}` to avoid that |
12:09:47 | FromDiscord | <ieltan> 😐 |
12:09:50 | FromDiscord | <kots> https://nim-lang.github.io/Nim/manual.html#types-procedural-type |
12:10:01 | FromDiscord | <kots> It says proc types are closure by default |
12:10:03 | FromDiscord | <Robyn [She/Her]> In reply to @ieltan "and you need to": I mean, it makes sense |
12:10:15 | FromDiscord | <kots> Can someone show me when this isn't the case? |
12:10:46 | FromDiscord | <Phil> is the default convention used for a Nim proc. It is the same as fastcall, but only for C compilers that support fastcall. |
12:10:52 | FromDiscord | <Phil> For nimcall |
12:11:03 | FromDiscord | <Phil> Closure is the default for proc types |
12:11:11 | FromDiscord | <kots> That's what I've been saying though... |
12:11:21 | FromDiscord | <kots> I'm not sure what we are disagreeing about here... |
12:12:06 | FromDiscord | <Phil> And we've been telling you it depends on which syntax you're in and it's a mixed bag.↵Outside of your proc on top level, chances are that the Nimcall calling convention is used |
12:12:49 | FromDiscord | <Phil> I'm on phone and in between exercises so I can't exactly write code rn |
12:12:50 | FromDiscord | <kots> It's not a mixed bag, when you write a proc it's nimcall, when you write a proc type it's closure |
12:13:34 | FromDiscord | <kots> When you declare a proc parameter its type is a proc type so its default convention is closure |
12:13:55 | FromDiscord | <kots> The only question here is why it was declared explicitly when it defaults to closure anyway |
12:14:14 | FromDiscord | <ieltan> In reply to @chronos.vitaqua "I mean, it makes": i'm just sauying it sucks, i remember making a custom `map`, i had to make like two versions because of the compiler crying about`{.nimcall.}` and`{.closure.}` . But now you have no clue which one is being used at call site loo |
12:14:22 | FromDiscord | <kots> If I'm missing something please point it out explicitly, I feel like I'm retarded |
12:15:03 | FromDiscord | <kots> (edit) removed "proc" | "parameter ... its" added "that is a proc," |
12:16:46 | FromDiscord | <Robyn [She/Her]> In reply to @ieltan "i'm just sauying it": I'd say that's a non-issue since functionality is still identical, no? |
12:18:05 | FromDiscord | <ieltan> In reply to @chronos.vitaqua "I'd say that's a": erm no, if i would want to avoid closures whenever i can because they have bigger overhead. so i have to make a `{.nimcall.}` version... |
12:18:16 | FromDiscord | <ieltan> (edit) removed "if" |
12:19:26 | FromDiscord | <Robyn [She/Her]> True, didn't think of that |
12:20:17 | FromDiscord | <Robyn [She/Her]> It's a non-issue in my case since my parser combinator does parser combination at compile-time when possible |
12:21:47 | FromDiscord | <ieltan> well in my case i just have no way to know which one is called because nimcall implicitly converts to closures. |
12:22:28 | FromDiscord | <Robyn [She/Her]> Couldn't you make two functions that accepts either one? |
12:22:56 | FromDiscord | <Robyn [She/Her]> Then the one that accepts a closure can just be annotated with `{.error.}` |
12:23:25 | FromDiscord | <ieltan> yes but sometimes i need to closure too, i mean a `map` that cannot accept closure is kinda useless |
12:23:37 | FromDiscord | <Robyn [She/Her]> Fair enough |
12:24:12 | FromDiscord | <ieltan> `{.nimcall.}` is accepted because not everything is a closure and it's a good way to avoid overhead |
12:25:10 | FromDiscord | <Robyn [She/Her]> Makes sense |
12:25:38 | FromDiscord | <amjadhd> In reply to @isofruit "Since a Nimcall proc": It is converted implicitly to a closure: https://play.nim-lang.org/#pasty=xIugyPRA |
12:26:43 | FromDiscord | <kots> the answer to the original question is that it was marked as closure before closure became the default:↵https://github.com/nim-lang/Nim/commit/8d99753d6320489e4de8cf186415b0a7be8260b4↵https://github.com/nim-lang/Nim/commit/033dc50c691f37808e021856bcd0d385cf427ec2 |
12:27:43 | FromDiscord | <ieltan> i tried looking up how the stdlib does it, hoping they're not just sticking with `{.closure.}` |
12:27:53 | FromDiscord | <ieltan> nope, of course theyre are |
12:28:12 | FromDiscord | <Phil> In reply to @amjadhd "It is converted implicitly": ... I'm highly wondering why that conversion didn't work for me when also dealing with async procs elsewhere, but likely a caveat of sorts |
12:30:05 | FromDiscord | <ieltan> In reply to @isofruit "... I'm highly wondering": async are totally different thing |
12:35:45 | FromDiscord | <ieltan> i guess this answers my problem: https://play.nim-lang.org/#pasty=oaLihBns |
12:36:13 | FromDiscord | <ieltan> but it's very unintuitive |
12:40:06 | FromDiscord | <ieltan> In reply to @ieltan "i guess this answers": or not, why is `baz()` calling the closure version ? |
12:42:19 | FromDiscord | <kots> cause baz is a closure, isn't it |
12:42:37 | FromDiscord | <ieltan> ah |
12:42:47 | FromDiscord | <ieltan> yeah sorry i missed the `x` |
12:43:13 | FromDiscord | <ieltan> nvm |
13:49:36 | * | xet7 joined #nim |
13:59:59 | * | xtr00 joined #nim |
15:16:02 | * | xtr00 quit (Ping timeout: 250 seconds) |
15:49:13 | * | lucasta joined #nim |
15:49:42 | FromDiscord | <saint.___.> Has there been any news on IC? |
15:49:56 | FromDiscord | <saint.___.> I can't seem to find any updates on github, but not totally sure where I should be looking |
15:53:34 | FromDiscord | <leorize> check back in 8 years, then maybe IC will be here |
16:08:17 | * | lucasta quit (Remote host closed the connection) |
16:25:30 | * | xtr00 joined #nim |
16:59:41 | * | ntat joined #nim |
17:04:50 | FromDiscord | <ieltan> lol |
17:18:30 | FromDiscord | <albassort> i need a type which is like |
17:18:32 | FromDiscord | <albassort> not pointer |
17:18:39 | FromDiscord | <albassort> anything besides a pointer |
17:20:15 | FromDiscord | <fabric.input_output> `distinct pointer` |
17:27:47 | FromDiscord | <Robyn [She/Her]> In reply to @albassort "not pointer": `not pointer`? |
17:27:58 | FromDiscord | <Robyn [She/Her]> Literally pass that as a generic argument :P |
17:28:14 | FromDiscord | <Robyn [She/Her]> !eval echo $(not pointer) |
17:28:15 | NimBot | Compile failed: /usercode/in.nim(1, 6) Error: type mismatch |
17:28:29 | FromDiscord | <Robyn [She/Her]> Huh? |
17:28:38 | FromDiscord | <Robyn [She/Her]> Oh wait |
17:30:36 | FromDiscord | <Robyn [She/Her]> !eval echo (proc(arg: (not pointer | not ptr typedesc): typeof(arg) = arg)("string") |
17:30:38 | NimBot | Compile failed: /usercode/in.nim(1, 50) Error: expected: ')', but got: ':' |
17:31:10 | FromDiscord | <Robyn [She/Her]> This is painful |
17:31:32 | FromDiscord | <Robyn [She/Her]> Hey mods, please can we get a bot that can run Nim code for the Discord and Matrix side? Would be hella useful |
17:32:14 | FromDiscord | <Robyn [She/Her]> Like, multiple lines of code |
17:32:29 | FromDiscord | <Robyn [She/Her]> !eval echo("a",↵ "b") |
17:32:31 | NimBot | Compile failed: /usercode/in.nim(1, 10) Error: undeclared identifier: '↵' |
17:32:55 | FromDiscord | <Robyn [She/Her]> :P |
17:51:35 | * | om3ga joined #nim |
17:57:52 | * | coldfeet quit (Remote host closed the connection) |
18:06:04 | FromDiscord | <leorize> nimbot is a dom product |
18:06:24 | FromDiscord | <leorize> ah no, it's in nim-lang |
18:06:36 | FromDiscord | <leorize> so further dev could be done |
18:06:46 | FromDiscord | <leorize> I guess that just meant\: PR welcome \:p |
18:07:04 | FromDiscord | <Robyn [She/Her]> Idk how to do Matrix bot development :P |
18:09:13 | FromDiscord | <leorize> just make it be able to handle multi-line discord messages from IRC side |
18:15:10 | FromDiscord | <Robyn [She/Her]> Fair point |
18:15:35 | FromDiscord | <Robyn [She/Her]> How does it work for multiple line Matrix messages? Same issue? |
18:18:41 | FromDiscord | <leorize> the pipeline is\: matrix -\> discord -\> irc |
18:18:50 | FromDiscord | <leorize> so handle discord part and you get matrix for free |
18:36:59 | FromDiscord | <Robyn [She/Her]> Makes sense |
18:42:44 | xtr00 | what's up with this code? https://play.nim-lang.org/#pasty=hHgSCmVD |
18:46:47 | FromDiscord | <Robyn [She/Her]> sent a code paste, see https://play.nim-lang.org/#pasty=VmpVaqXg |
18:47:51 | FromDiscord | <Robyn [She/Her]> Doesn't handle distinct pointers but that's easy to solve with a concept |
18:49:07 | FromDiscord | <ieltan> why not `type SomePointer = ref | ptr | pointer | proc; proc test[T: not SomePointer](val: T): T` |
18:50:12 | FromDiscord | <ieltan> its also DRY if you have lots of procs where you dont want to take pointers |
19:44:04 | * | disso-peach joined #nim |
19:47:00 | FromDiscord | <Elegantbeef> @Robyn [She/Her] why `not ptr typedesc`? |
19:47:09 | FromDiscord | <Elegantbeef> In what world can you have a `ptr typedesc`? |
19:50:39 | FromDiscord | <Phil> In reply to @chronos.vitaqua "Hey mods, *please* can": I can only drop the good old "PR welcome" line here |
19:52:00 | FromDiscord | <albassort> phil |
19:52:14 | FromDiscord | <albassort> i've spent the past few hours squashing memory leaks |
19:52:16 | FromDiscord | <albassort> :) |
19:52:27 | FromDiscord | <albassort> unlike you though, my efforts are born fruit and i haven't gone insane (yet) |
19:53:48 | FromDiscord | <Robyn [She/Her]> In reply to @Elegantbeef "In what world can": I would've thought that'd do generic binding or something |
19:54:03 | FromDiscord | <Elegantbeef> I can make up word combinations aswell |
19:54:04 | FromDiscord | <Robyn [She/Her]> Though I think it just shows how dead my memory is rn |
19:54:20 | FromDiscord | <Elegantbeef> Tangential static type parameters |
19:54:23 | FromDiscord | <Elegantbeef> Look words! |
19:54:27 | FromDiscord | <Robyn [She/Her]> What would you do to prevent any `ptr`? |
19:54:39 | FromDiscord | <Elegantbeef> `not(ptr or ref)` |
19:54:47 | FromDiscord | <Elegantbeef> `or pointer` |
19:55:23 | FromDiscord | <Elegantbeef> xtr00 complex type aliases are no bueno so https://play.nim-lang.org/#pasty=TXEfBPFH |
19:57:49 | FromDiscord | <Phil> In reply to @albassort "unlike you though, my": If you got energy to shit-talk you got energy to do bot contributions 😛 |
19:58:18 | FromDiscord | <albassort> im just bragging that my issues are much smaller in scale :p |
19:58:53 | FromDiscord | <Phil> Sidenote, for general debugging with multithreaded code I found balls to be pretty handy |
19:59:13 | FromDiscord | <Phil> As in, if you want to be a thousand percent safe, that's the way to go imo.↵Yes this is me shilling a disruptek project |
19:59:16 | FromDiscord | <albassort> afab people c ant debug multithreaded data leaks? |
19:59:31 | FromDiscord | <albassort> (edit) "c ant" => "cant" |
19:59:46 | FromDiscord | <Elegantbeef> It's their loss |
20:00:04 | FromDiscord | <Elegantbeef> I am confused how ACAB and AFAB intersect 😄 |
20:00:07 | FromDiscord | <Phil> In reply to @albassort "afab people cant debug": Its a new form of modern sexism and misoginy, you're not cool enough to understand |
20:00:24 | FromDiscord | <Phil> In reply to @Elegantbeef "I am confused how": Some people are just assigned cop at birth |
20:01:31 | FromDiscord | <Phil> Coming off my joke-horse though, I mean the "Balls" test-lib.↵It essentially runs valgrind, helgrind, asan and tsan over your project (because valgrind/helgrind sometimes catch things asan/tsan don't and vice versa) |
20:01:49 | xtr00 | Elegantbeef: thanks that works, but not intuitive. |
20:02:02 | * | ntat quit (Quit: Leaving) |
20:02:10 | FromDiscord | <Elegantbeef> Yea generic alias types are fun! |
20:03:44 | xtr00 | there are more imporant things to improve in nim, so I wont create a bug for this, for now. |
20:03:50 | FromDiscord | <albassort> i think my code has classical malloc dataleaks |
20:03:57 | FromDiscord | <albassort> so nothing to worry about |
22:04:50 | FromDiscord | <Robyn [She/Her]> sent a code paste, see https://play.nim-lang.org/#pasty=xaBxCYiq |
22:04:54 | FromDiscord | <Robyn [She/Her]> Yummy hacky code |
22:13:40 | FromDiscord | <Elegantbeef> But why |
22:13:55 | FromDiscord | <Robyn [She/Her]> Parser combinator :3 |
22:14:25 | FromDiscord | <Robyn [She/Her]> Recursive calls to `parseExpression` needed and since I'm doing pratt parsing, I need `subExpPrecedence` |
22:14:45 | FromDiscord | <Robyn [She/Her]> I think I need another param for `out` too... |
22:16:06 | FromDiscord | <Elegantbeef> But why the converter? |
22:19:02 | FromDiscord | <Robyn [She/Her]> In reply to @Elegantbeef "But why the converter?": Type mismatch otherwise and I don't wanna explicitly convert it |
22:19:30 | FromDiscord | <Elegantbeef> So define an overload? |
22:22:54 | FromDiscord | <Robyn [She/Her]> In reply to @Elegantbeef "So define an overload?": That's... A good idea :P |
22:27:34 | FromDiscord | <Robyn [She/Her]> sent a code paste, see https://play.nim-lang.org/#pasty=hjiTMPTd |
22:27:39 | FromDiscord | <Robyn [She/Her]> In the stdlib |
22:29:57 | FromDiscord | <Elegantbeef> Cause `or` is wrong there 😛 |
22:30:06 | FromDiscord | <Elegantbeef> Wait I'm daft |
22:30:14 | FromDiscord | <Elegantbeef> No comment |
22:31:44 | FromDiscord | <Omi.> https://t.me/Hamster_kombat_bot/start?startapp=kentId7455986345↵↵↵Million dollar business |
22:32:35 | FromDiscord | <Omi.> Get started, time is limited |
22:34:01 | FromDiscord | <Robyn [She/Her]> <@&371760044473319454> |
22:34:54 | FromDiscord | <Robyn [She/Her]> In reply to @Elegantbeef "No comment": Hm, should I ask in internals then? I'ma do it |
22:48:34 | FromDiscord | <zumi.dxy> how about a one dollar business instead 😏 |
23:01:38 | FromDiscord | <Elegantbeef> A million one dollar business |
23:01:42 | FromDiscord | <Elegantbeef> es |
23:03:32 | FromDiscord | <tommyzjones_20> sent a long message, see https://pasty.ee/YqMqFHVz |
23:08:31 | * | pbsds3 quit (Quit: Ping timeout (120 seconds)) |
23:09:02 | * | pbsds3 joined #nim |
23:16:42 | FromDiscord | <Robyn [She/Her]> :p |
23:17:00 | FromDiscord | <Robyn [She/Her]> Anyway, maybe writing my own parser combinator was a mistake xD |
23:18:46 | * | xtr00 quit (Ping timeout: 250 seconds) |
23:43:52 | NimEventer | New thread by mig: Forum on Firefox is broken, see https://forum.nim-lang.org/t/11831 |
23:49:32 | FromDiscord | <albassort> alright i found a nim bug but i don't know how to solve it |
23:50:19 | FromDiscord | <__jont__> Having the most difficult time creating a Nim binding for a C/C++ library - namely Box2D. Anyone have any resources out there to help with creating Nim bindings? Finding language documentation hard to follow |
23:50:55 | FromDiscord | <saint.___.> In reply to @__jont__ "Having the most difficult": Is it C or c++ |
23:51:12 | FromDiscord | <saint.___.> Or both |
23:51:27 | FromDiscord | <saint.___.> If you write a C interface for it then futhark can do it automatically for you |
23:51:43 | FromDiscord | <albassort> do i have a return struct from an ffi function, for some reason in my current build, if I dont echo the errorcode it will assume its 0, if i do echo it will not. This means that my unittest fails depending on if it observe it not |
23:51:48 | FromDiscord | <__jont__> In reply to @saint.___. "Is it C or": Could be either. They have box2c, which is a pure C implementation |
23:51:50 | FromDiscord | <albassort> @ElegantBeef is this a bug or a feature :) |
23:51:58 | FromDiscord | <Elegantbeef> Use a C api instead of C++ |
23:52:00 | FromDiscord | <albassort> In reply to @__jont__ "Could be either. They": you'd want to use the C |
23:52:01 | FromDiscord | <saint.___.> In reply to @__jont__ "Could be either. They": Okie have you looked into futhark then? It does it automatically |
23:52:02 | FromDiscord | <saint.___.> Ya |
23:52:05 | FromDiscord | <saint.___.> It's very good |
23:52:10 | FromDiscord | <Elegantbeef> Then use c2nim or futhark |
23:52:17 | FromDiscord | <albassort> (edit) "do" => "so" |
23:52:20 | FromDiscord | <saint.___.> Try futhark first |
23:52:37 | FromDiscord | <saint.___.> I could not get c2nim to work and not easy to figure out personally |
23:52:41 | FromDiscord | <Elegantbeef> > so i have a return struct from an ffi function, |
23:52:42 | FromDiscord | <Elegantbeef> ... |
23:52:48 | FromDiscord | <Elegantbeef> What do you expect |
23:52:52 | FromDiscord | <__jont__> In reply to @saint.___. "Okie have you looked": I’ve seen it mentioned but haven’t used it yet. C2nim didn’t output anything worthwhile |
23:52:54 | FromDiscord | <albassort> it to work as expected? |
23:52:57 | FromDiscord | <Elegantbeef> Returning a struct should work find if the ABI is the same |
23:53:23 | FromDiscord | <saint.___.> In reply to @__jont__ "I’ve seen it mentioned": Install it and it should work good. Ppl here will be able to help you too but basically it should all work |
23:53:23 | FromDiscord | <Elegantbeef> So provide an example so I can see what you're doing instead of throwing darts at my monitor... I'm running out of spare monitors |
23:53:27 | FromDiscord | <albassort> it has worked fine for like 2 weeks up until RIGHT Now where im getting this issue on this particular build |
23:53:33 | FromDiscord | <Elegantbeef> C2nim works best with `gcc -E` |
23:53:36 | FromDiscord | <saint.___.> Just have to learn what sort of nim types correspond to c types |
23:53:45 | FromDiscord | <albassort> grumble grumble grumble |
23:53:49 | FromDiscord | <saint.___.> And then pass your data in and it will work |
23:54:13 | FromDiscord | <albassort> i'll change the rust build slightly and see if that will make it not do this |
23:54:16 | FromDiscord | <Elegantbeef> @albassort I do wish I could just intuit the code you've written but I'm only a simple man without supernatural powers |
23:54:23 | FromDiscord | <Elegantbeef> Just show the Nim bindings and your usage |
23:55:18 | FromDiscord | <albassort> i'm not ready for the beef critique |
23:55:35 | FromDiscord | <Elegantbeef> Well then you are not read for help |
23:55:51 | FromDiscord | <Elegantbeef> Are you by anychance using a `ref` in the Nim struct? |
23:56:02 | FromDiscord | <Elegantbeef> If so you NEED to mark it `{.cdecl.}` |
23:56:05 | FromDiscord | <albassort> no ref, its a pure unt8 |
23:56:08 | FromDiscord | <Elegantbeef> Otherwise Nim will NRVO it |
23:56:10 | FromDiscord | <albassort> (edit) "unt8" => "uint8" |
23:56:28 | FromDiscord | <__jont__> In reply to @saint.___. "Install it and it": For sure, will try it out. Thank you everyone |
23:56:35 | FromDiscord | <albassort> uint8 straight from rust's memory, no pointers, no smart pointers, 1 byte of memory, organic, farm raised |
23:56:56 | FromDiscord | <saint.___.> In reply to @__jont__ "For sure, will try": No problem! |
23:57:05 | FromDiscord | <Elegantbeef> Well then what's the Nim header? |
23:57:24 | FromDiscord | <albassort> everything is synced up and it worked effortlessly in the past |
23:57:47 | FromDiscord | <albassort> there are like 20 tests for this function, it only happens for 1 of them |
23:58:49 | FromDiscord | <albassort> i recompiled both nim and rust, removed the echo, and it works fine |
23:58:51 | FromDiscord | <albassort> ?????????? |
23:59:09 | FromDiscord | <albassort> alright this is too silly maybe i should keep this |
23:59:15 | FromDiscord | <albassort> (edit) "alright this is too silly maybe i should keep this ... " added "for bug tracking" |
23:59:39 | FromDiscord | <albassort> because its reproducible so long as i keep the rust without an extra \n |