00:22:41 | * | Jjp137 quit (Read error: Connection reset by peer) |
00:23:13 | * | Jjp137 joined #nim |
00:48:29 | * | krux02_ quit (Remote host closed the connection) |
01:02:57 | * | lritter quit (Ping timeout: 248 seconds) |
01:03:31 | * | absolutejam2 joined #nim |
01:07:58 | * | absolutejam2 quit (Ping timeout: 245 seconds) |
01:21:31 | * | SenasOzys joined #nim |
02:11:05 | * | chun joined #nim |
02:48:44 | * | leorize quit (Ping timeout: 260 seconds) |
02:50:06 | * | leorize joined #nim |
03:01:04 | Tanger | Araq: Sorry, had to disappear last night. In relation to my query about wrapConnectedSocket, how else would one make a socket use SSL? asyncnet::acceptAddr() doesn't seem to wrap the client socket when called, compared to net::acceptAddr() |
03:01:16 | Tanger | Is it just a current limitation on async/ssl? |
03:01:26 | * | Snircle quit (Quit: Textual IRC Client: www.textualapp.com) |
03:06:34 | leorize | isn't there wrapSocket also? |
03:06:50 | leorize | not sure if openssl supports non-blocking sockets |
03:09:36 | Tanger | Hmmm, I'll have a look see at the docs leorize. I figured wrapConnectedSocket was the choice as it operates on connected sockets |
03:22:18 | FromGitter | <zacharycarter> Trying to pass a callback to C and it's been a while... ```type mismatch: got <proc (this: ptr bgfx_callback_interface_t, filePath: cstring, line: uint16, format: cstring, argList: va_list){.cdecl, gcsafe, locks: 0.}> but expected 'proc (this: ptr bgfx_callback_interface_t, filePath: cstring, line: uint16, format: cstring, argList: va_list){.closure.}' ⏎ ⏎ `````` [https: |
03:22:18 | FromGitter | ... //gitter.im/nim-lang/Nim?at=5d1ec26ac5f3c329aee835cf] |
03:22:30 | FromGitter | <zacharycarter> any ideas? |
03:24:41 | * | uptime is now known as ^ |
03:25:05 | * | ^ is now known as uptime |
03:29:56 | Tanger | zacharycarter: Incorrect pragmas on the proc? ie {.closure.}? |
03:30:05 | FromGitter | <zacharycarter> I don't think that's it |
03:30:44 | FromGitter | <zacharycarter> I think it's because I have something mucked up in the definition for the C callback I'm trying to call |
03:30:58 | FromGitter | <zacharycarter> I tried adding {.cdecl.} to the end of it but that did not do anything |
03:34:13 | FromGitter | <zacharycarter> maybe also because I'm using ptr and not pointer |
03:34:47 | Tanger | Is there a semantic difference? |
03:35:40 | FromGitter | <zacharycarter> ptr is a Nim thing - pointer is not |
03:35:47 | FromGitter | <zacharycarter> well |
03:35:53 | FromGitter | <zacharycarter> pointer is generally what you use when interoping with C |
03:35:58 | FromGitter | <zacharycarter> C has no concept of `ptr` |
03:36:32 | Tanger | Ah. So pointer is just C compatible like cuint, cshort etc? |
03:37:42 | FromGitter | <zacharycarter> https://forum.nim-lang.org/t/823 - explains it better than I would :P |
03:38:26 | Tanger | Awesome, thanks |
03:39:33 | * | SenasOzys quit (Ping timeout: 258 seconds) |
03:39:45 | * | dddddd quit (Remote host closed the connection) |
03:40:41 | leorize | ptr is pointer to C anw... |
03:41:10 | FromGitter | <zacharycarter> bleh I can't figure out why this isn't working |
03:41:12 | leorize | zacharycarter looks like the function signature was incorrect |
03:41:30 | leorize | you're passing the right thing, but the wrapper function is not |
03:41:39 | FromGitter | <zacharycarter> hmm |
03:42:12 | leorize | it's expecting a `{.closure.}` somehow |
03:42:23 | leorize | guess someone forgot to annotate the param with `{.cdecl.}` |
03:43:01 | FromGitter | <zacharycarter> well I added `{.cdecl.}` to the wrapper function but that didn't seem to fix it |
03:44:00 | FromGitter | <zacharycarter> here's the C definition - ` void (*trace_vargs)(bgfx_callback_interface_t* _this, const char* *filePath, uint16*t _line, const char* *format, va*list _argList);` |
03:44:25 | leorize | what's the wrapper function signature? |
03:44:33 | FromGitter | <zacharycarter> and mine is - `proc (this: ptr bgfx_callback_interface_t; filePath: cstring; ⏎ ⏎ ``` line: uint16; format: cstring; argList: va_list) {.cdecl.}```` [https://gitter.im/nim-lang/Nim?at=5d1ec7a13a1e451bfda04c7e] |
03:45:07 | leorize | seems to be correct |
03:45:24 | FromGitter | <zacharycarter> maybe something is up with `va_list` |
03:45:38 | leorize | get rid of it |
03:45:38 | FromGitter | <zacharycarter> I have that defined as - `type va_list* {.importc,header:"<stdarg.h>".} = object` |
03:45:43 | FromGitter | <zacharycarter> okay |
03:45:45 | leorize | use `{.varargs.}` pragma instead |
03:45:57 | FromGitter | <zacharycarter> I didn't realize that would work with C interop - cool |
03:46:14 | leorize | ah wait, not that easy :p |
03:46:22 | FromGitter | <zacharycarter> haha |
03:46:31 | leorize | this is a callback :p |
03:46:35 | FromGitter | <zacharycarter> yar |
03:47:10 | leorize | your definition is correct, so what's wrong atm? |
03:47:36 | FromGitter | <zacharycarter> still getting this error - ```type mismatch: got <proc (this: ptr bgfx_callback_interface_t, filePath: cstring, line: uint16, format: cstring, argList: va_list){.cdecl, noSideEffect, gcsafe, locks: 0.}> but expected 'proc (this: ptr bgfx_callback_interface_t, filePath: cstring, line: uint16, format: cstring, argList: va_list){.cdecl.}' ⏎ ⏎ `````` [https://gitter.im/nim-lang/Nim?at=5d1ec858ce3d0458f2afb48b] |
03:48:09 | FromGitter | <zacharycarter> my callback looks like - ```proc cbTraceVargs(this: ptr bgfx_callback_interface_t; filePath: cstring; line: uint16; format: cstring; argList: va_list) {.cdecl.} = ⏎ discard``` |
03:49:05 | leorize | looks like a bug to me |
03:49:12 | leorize | these two should be compatible |
03:50:19 | FromGitter | <zacharycarter> yeah - I'll try to throw together a small reproducable gist |
03:56:16 | FromGitter | <zacharycarter> something strange is going on - I can make an small example with similar code that compiles fine |
04:02:10 | * | chun_ joined #nim |
04:03:08 | * | chun_ quit (Remote host closed the connection) |
04:03:28 | * | chun_ joined #nim |
04:04:31 | * | chun quit (Ping timeout: 246 seconds) |
04:12:11 | FromGitter | <zacharycarter> heh - I can even use the same types in another file and no compile errors |
04:15:36 | leorize | now that's weird |
04:15:38 | FromGitter | <zacharycarter> ugh so strange - I just reverted all my changes and added the same code again and no compile errors |
04:15:57 | FromGitter | <zacharycarter> something must have been going on with nimble building packages and cached libs not getting replaced I guess |
04:16:09 | FromGitter | <zacharycarter> whatever - it's working now |
04:22:27 | FromGitter | <zacharycarter> thanks for helping me leorize |
04:22:53 | leorize | np :) |
04:23:46 | * | chun_ quit (Ping timeout: 246 seconds) |
04:33:16 | * | nsf joined #nim |
04:36:57 | * | laaron joined #nim |
04:36:58 | * | SenasOzys joined #nim |
04:54:30 | * | chun joined #nim |
04:56:44 | * | SenasOzys quit (Ping timeout: 272 seconds) |
05:05:09 | * | absolutejam2 joined #nim |
05:09:53 | * | absolutejam2 quit (Ping timeout: 248 seconds) |
05:24:06 | * | hoijui joined #nim |
05:26:54 | * | absolutejam2 joined #nim |
05:31:29 | * | absolutejam2 quit (Ping timeout: 258 seconds) |
05:31:34 | * | narimiran joined #nim |
05:41:08 | * | brakmic joined #nim |
05:44:44 | * | brakmic quit (Remote host closed the connection) |
05:45:25 | * | brakmic joined #nim |
05:47:02 | * | absolutejam2 joined #nim |
06:03:13 | * | solitudesf joined #nim |
06:10:54 | * | jjido joined #nim |
06:21:45 | * | arecaceae quit (Remote host closed the connection) |
06:22:04 | * | arecaceae joined #nim |
06:39:37 | * | jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
06:39:51 | * | absolutejam2 quit (Ping timeout: 244 seconds) |
06:45:01 | * | solitudesf quit (Ping timeout: 244 seconds) |
06:45:20 | * | jjido joined #nim |
06:52:22 | * | jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
06:55:01 | * | krux02 joined #nim |
07:00:00 | * | gmpreussner quit (Quit: kthxbye) |
07:00:49 | * | chun quit (Remote host closed the connection) |
07:01:09 | * | chun joined #nim |
07:04:32 | * | gmpreussner joined #nim |
07:20:02 | * | dwdv joined #nim |
07:21:26 | * | alexander92 joined #nim |
07:21:46 | * | purebadger joined #nim |
07:29:13 | * | crem quit (Read error: Connection reset by peer) |
07:33:41 | * | crem joined #nim |
07:38:25 | * | Vladar joined #nim |
07:52:33 | * | absolutejam2 joined #nim |
07:59:07 | * | crem quit (Read error: Connection reset by peer) |
08:00:53 | * | crem joined #nim |
08:19:28 | * | chun quit (Remote host closed the connection) |
08:19:38 | * | chun joined #nim |
08:20:49 | * | chun quit (Remote host closed the connection) |
08:21:09 | * | chun joined #nim |
08:22:02 | * | chun quit (Client Quit) |
08:22:21 | * | chun joined #nim |
08:24:08 | * | chun quit (Client Quit) |
08:24:28 | * | chun joined #nim |
08:25:48 | * | chun quit (Remote host closed the connection) |
08:26:08 | * | chun joined #nim |
08:30:00 | Araq | any OBS users around? how can make the chat blend into my recorded dektop? |
08:31:18 | * | chun quit (Remote host closed the connection) |
08:31:38 | * | chun joined #nim |
08:32:00 | alexander92 | hm where do you see chat in obs |
08:34:20 | Araq | it's a separate window |
08:34:48 | alexander92 | btw are there segfault test cases in the suite |
08:34:59 | alexander92 | like something testing stack traces for them or something |
08:35:55 | alexander92 | i am looking for small programs with strange to explain segfaults e.g. race conditions or something not sure |
08:52:16 | Araq | there is tproper_stacktrace.nim |
09:00:51 | federico3 | https://elixirschool.com/blog/phoenix-live-view/ something like this would be really nice for Nim |
09:02:17 | FromDiscord_ | <SychoRyn> is nim viable for game development? |
09:02:31 | federico3 | SychoRyn: very much so |
09:02:33 | FromDiscord_ | <SychoRyn> getting really tired of C++ :/ |
09:03:16 | Vladar | totes, I used it to participate in Linux Game Jam for 3 years already |
09:04:51 | Zevv | I tried to do some c++ the last few days. Try deciphering the stream of vomit coming out of the compiler when there's a signature mismatch when doing a std::bind(), or when leaving out the |
09:04:57 | Zevv | '= 0' on a virtual method |
09:05:13 | Zevv | precious hours of my life, *poof*, gone, just like that |
09:06:08 | Zevv | I tried googling the error messages, and I get here: https://codegolf.stackexchange.com/questions/1956/generate-the-longest-error-message-in-c |
09:06:18 | Zevv | people having a little competition generating the longest error message from C++ |
09:07:04 | FromDiscord_ | <SychoRyn> amazing |
09:07:35 | FromDiscord_ | <SychoRyn> is nim viable for gui apps |
09:09:16 | Zevv | https://matthiashager.com/gui-options-for-nim |
09:09:24 | alexander92 | hm zevv, isnt clang better |
09:09:33 | alexander92 | with error messages, i think that was one of its main pro-s |
09:09:45 | FromDiscord_ | <SychoRyn> I really want to use nim but people keep telling me I should use "RUST" and RUST and ugh I fucking... Rust (I'm too dumb to use it lole) |
09:11:04 | Zevv | slightly. Part my problem was that I was making a shared lib which happely links, but barfs on my at run time with unresolved symbols like _j6Kgbcodec4Ksetup4. Which I need to demangle manually, and translates to "typeinfo of codec::setup()". WTH does that mean if the linker can't find typeinfo? |
09:11:46 | Zevv | So it seems that vtables went missing because I forgot initialze my vritual method to 0. But EVERY FRIGGING virtual method I ever saw was initialized to 0. So why is that not the default? |
09:11:57 | Zevv | </rant> |
09:17:25 | * | absolutejam joined #nim |
09:18:42 | federico3 | https://github.com/nim-lang/needed-libraries/issues/107 |
09:21:31 | FromGitter | <rokups> federico3 there are https://github.com/pragmagic/karax and https://github.com/dom96/jester |
09:21:49 | federico3 | rokups: they don't fit those requirements |
09:23:31 | FromGitter | <rokups> alright. i know little of modern webdev, just thought you might have missed these projects :] |
09:23:45 | federico3 | I'm aware of those, thank you :) |
09:24:41 | FromGitter | <rokups> someone is working on https://github.com/nepeckman/nerve-rpc which seems it will be very handy for exposing APIs |
09:24:49 | FromGitter | <rokups> and karax can render html on server side i think |
09:27:33 | federico3 | https://www.hug.rest/ is another good examuple |
09:29:04 | * | brakmic quit (Read error: Connection reset by peer) |
09:29:45 | alexander92 | praise the Lord, i was thinking about phoenix just today |
09:29:53 | alexander92 | even asked them a few questions in their irc |
09:30:13 | * | brakmic joined #nim |
09:30:15 | alexander92 | i also wanted to create a little framework eventually |
09:30:47 | alexander92 | but i feel these days usually there are minimal api-related backend libs |
09:31:16 | alexander92 | which let you easily create simpler api microservices and stuff like this (probably like hug) |
09:31:32 | alexander92 | and then you have the more classical big frameworks(e.g. phoenix, rails style) |
09:32:01 | alexander92 | and i am not sure if actually the second kind is still popular |
09:33:29 | alexander92 | (but yeah it shouldn't be too hard: there are orm-s like ormin/norm, template engine is easy to pull out: karax or htmlgen or a custom one, routing can be quite nice with macros |
09:34:28 | alexander92 | the most missing thing imho would be a good validation layer, and a good cli tool for scaffolding/managing a web app, and a migration lib |
09:34:44 | alexander92 | (i have written a migration lib in my job, but not sure if its good enough for general use) |
09:35:44 | alexander92 | and good websocket abstraction |
09:36:11 | alexander92 | and good background job mechanism: i feel like awaiting from threads might help a lot with that |
09:37:28 | alexander92 | but yeah, my point is that if one has ok components for most of those and manages to combine them with a good DSL, this might be useful as a web fr |
09:38:52 | * | tjmac joined #nim |
09:41:34 | alexander92 | but i dont really have time today to think about that |
09:52:49 | * | clyybber joined #nim |
09:59:14 | livcd | federico3: i am too stupid but i dont really understand what is this liveview |
09:59:53 | livcd | i mean i have an idea but.. |
10:00:27 | federico3 | livcd: https://www.youtube.com/watch?v=8xJzHq8ru0M |
10:01:24 | livcd | But there has to be JS right ? |
10:03:00 | * | solitudesf joined #nim |
10:10:30 | federico3 | livcd: almost none it seems |
10:16:27 | FromGitter | <rishavs> Can I update nim from nimble itself? |
10:22:58 | * | couven92 joined #nim |
10:25:18 | lqdev[m] | rishavs: no, you use choosenim to do that |
10:25:53 | * | purebadger quit (Ping timeout: 245 seconds) |
10:26:08 | FromDiscord_ | <SychoRyn> http://boards.4channel.org/g/thread/71730586 |
10:26:16 | FromDiscord_ | <SychoRyn> nim general |
10:31:47 | * | purebadger joined #nim |
10:35:06 | * | chun quit (Remote host closed the connection) |
10:36:39 | FromGitter | <rishavs> Thanks |
10:38:10 | * | purebadger quit (Ping timeout: 268 seconds) |
10:41:44 | * | purebadger joined #nim |
10:53:23 | lqdev[m] | but iirc there's a nimble package `compiler` which *is* the Nim compiler, I never tried installing it this way though. maybe it works |
11:04:05 | alexander92 | i think it works indeed |
11:13:36 | * | alexander92 quit (Quit: WeeChat 2.4) |
11:22:14 | FromGitter | <rishavs> what is this pattern supposed to do? ⏎ `discard buttonSkin.assignTexture buttonMosaic.render(patternStretchBorder(8, 2))` ⏎ essentially `discard func_a func_b()` |
11:23:02 | FromGitter | <rishavs> is it essentially, ⏎ `discard func_a() ⏎ discard func_b()` |
11:24:42 | clyybber | Araq: tySink should not be an abstractInst anymore right? |
11:25:49 | * | Vladar quit (Remote host closed the connection) |
11:27:03 | * | hoijui quit (Ping timeout: 264 seconds) |
11:44:39 | * | Vladar joined #nim |
11:54:02 | * | ibutra joined #nim |
11:55:29 | Araq | clyybber: it should be but the backend has to be careful |
11:57:30 | * | nsf quit (Quit: WeeChat 2.4) |
12:02:10 | FromGitter | <rokups> @rishavs its `discard buttonSkin.assignTexture(buttonMosaic.render(patternStretchBorder(8, 2)))`. `discard` there means you do not use return type of `assignTexture()` |
12:05:39 | * | laaron quit (Quit: ZNC 1.7.1 - https://znc.in) |
12:06:38 | * | laaron joined #nim |
12:07:10 | clyybber | Araq: Why is tyLent not an abstractInst then? |
12:09:49 | clyybber | nevermind |
12:10:20 | * | Snircle joined #nim |
12:15:18 | FromGitter | <rishavs> Thanks @rokups so, it is the same way functional langs like F# call functions |
12:17:28 | FromGitter | <rokups> not sure how they work. in nim you can make make calls in multiple ways: `foo(a, b)`, `a.foo(b)`, `foo a, b`. they all do same thing |
12:18:40 | FromGitter | <rishavs> in f#, fn(a,b) is `fn a b` |
12:19:21 | FromGitter | <rishavs> this syntax confuses my a lot, specially when the same file uses all 3 function syntaxes :) |
12:21:27 | clyybber | Araq: Where do implicit addresses get introduced when passing something as a var (or what I want to achieve: sink) to a proc? |
12:22:50 | * | ibutra quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
12:34:57 | * | dddddd joined #nim |
12:37:38 | * | ibutra joined #nim |
12:57:24 | * | stefanos82 joined #nim |
13:01:33 | * | clyybber quit (Quit: WeeChat 2.5) |
13:08:00 | * | ibutra quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
13:08:49 | * | xace quit (Ping timeout: 248 seconds) |
13:09:05 | * | ibutra joined #nim |
13:13:51 | * | ibutra quit (Ping timeout: 264 seconds) |
13:19:26 | * | ibutra joined #nim |
13:19:49 | FromGitter | <mratsim> because var need a memory location so you can mutate it (i.e. lvalue) |
13:20:05 | FromGitter | <mratsim> memory locations have addresses |
13:30:26 | narimiran | @rishavs well it that example, somebody tried really hard to make the code cryptic and not easy to understand when you skim through it |
13:31:58 | narimiran | adding parentheses, as @rokups did, makes more sense |
13:34:57 | * | couven92 quit (Quit: Client disconnecting) |
13:43:46 | * | purebadger quit (Ping timeout: 246 seconds) |
13:47:41 | * | drewr quit (Read error: Connection reset by peer) |
13:49:30 | * | drewr joined #nim |
14:01:05 | * | narimiran quit (Ping timeout: 248 seconds) |
14:40:36 | disruptek | phoenix uses a js dom differ. |
14:56:35 | * | SenasOzys joined #nim |
15:00:29 | * | tjmac left #nim ("-bye") |
15:04:00 | * | ibutra quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
15:08:53 | * | absolutejam2 quit (Ping timeout: 268 seconds) |
15:20:52 | * | SenasOzys quit (Ping timeout: 245 seconds) |
15:32:23 | lqdev[m] | nice, seems that the Nim VS Code extension is back from the dead. time to get back to work |
15:44:01 | * | lritter joined #nim |
16:07:18 | FromGitter | <awr1> lack of circular imports in nim is still bugging me. the "types.nim" solution feels too C headerfile-ish for me; in general i wouldn't have as much of a problem with that but when it comes to doc generation things get messy |
16:08:46 | FromGitter | <awr1> could also use `include` + `codeReordering` but that seems inelegant, plus the same problem occurs |
16:18:48 | * | chun joined #nim |
16:19:20 | * | crem quit (Read error: Connection reset by peer) |
16:20:18 | * | Virxes joined #nim |
16:21:37 | * | crem joined #nim |
16:24:17 | disruptek | awr1: can you give an example of how this problem manifests? |
16:27:05 | Araq | you can dislike it all you want, but F# shares the same problem so I wouldn't say "C headerfile-ish" |
16:27:38 | * | ibutra joined #nim |
16:33:31 | * | kuon__ joined #nim |
16:36:01 | kuon__ | Hello, I am still in early stage of learning nim, and I was wondering if nim has plan/had a discussion, about a pipe operator, like a(b(val)) written val |> b |> a like in elixir or elm. |
16:40:36 | disruptek | you can make your own. zero functional might be inspirational if you don't like what comes in the tin: https://github.com/zero-functional/zero-functional |
16:43:16 | kuon__ | That library is interesting, thanks. |
16:49:55 | * | chun quit (Quit: Leaving) |
16:51:36 | * | chun joined #nim |
16:53:01 | * | chun left #nim (#nim) |
16:54:29 | * | chun joined #nim |
17:04:57 | FromGitter | <awr1> @disruptek for ex: i have a toy renderer/engine i'm working on, i have a platform.nim that handles (multiple) window generation, event loops etc. and then i have a renderer_vk.nim that initializes+handles a vulkan instance, logical devices, queues, swapchain, cmd buffers, shader SPIRV etc. but i have this issue where i want to "integrate" a window to the vulkan system (swapchain, imageviews, etc.). ideally what i would do |
17:04:57 | FromGitter | ... is that the platform window would have some sort of "vulkan integration" object in it containing, which would ideally be imported from renderer_vk.nim, but then platform.nim needs to call the integration proc, and this integration proc needs to be able to grab some of the generic window internals to do its work. s ... [https://gitter.im/nim-lang/Nim?at=5d1f833911bfea0b67ac7991] |
17:06:28 | * | leorize quit (Ping timeout: 260 seconds) |
17:06:54 | * | leorize joined #nim |
17:07:55 | FromDiscord_ | <demotomohiro> kuon__: you can just write ``val.b.a`` using method call syntax. |
17:08:27 | FromGitter | <awr1> circular imports are of course never *ideal* but sometimes they would be useful |
17:09:19 | kuon__ | demotomohiro hoo, didn't think it would work |
17:13:01 | disruptek | it sounds like you have a piece of code in mind that knows about vulkan and knows about platform. shouldn't that piece import those two files and do the nasty? |
17:15:35 | FromGitter | <awr1> i could possibly have a renderer_integrator.nim, yeah. although in general i would prefer to seem vulkan code in its appropriate domain |
17:16:32 | FromGitter | <awr1> circular imports are always ultimately resolvable by the programmer but they become useful when you want to keep things more tightly bound |
17:18:03 | lqdev[m] | yeah, circular imports made me split my player.nim file into playerbase.nim and playerdef.nim which is less than ideal |
17:18:04 | FromGitter | <awr1> however on thinking about it some more some of the same problems emerge. the integrator needs details from vulkan and platform, but platform needs to be able to call the integrator |
17:20:03 | disruptek | so? |
17:24:44 | FromGitter | <awr1> is that not a circular import |
17:25:00 | kuon__ | I get this error when trying to install sdl2 package, any idea ? http://dpaste.com/2X8D2AS |
17:25:32 | kuon__ | Without colors http://dpaste.com/0BGN1PC |
17:26:59 | FromGitter | <awr1> what ver of nim are you on? |
17:27:00 | disruptek | if you want to pass types that are shared between platform and vulkan, then yes, you will have to choose a scope in which those types are shared. no way around that. if you just want to trigger events or move data, then you don't need any of that. use channels, or futures, or callbacks, or, or, or, or... |
17:27:08 | FromGitter | <awr1> try doing a `choosenim update #head` |
17:27:16 | FromGitter | <awr1> @kuon__ |
17:27:16 | kuon__ | 0.20.99 |
17:27:52 | disruptek | it sounds like you're trying to make this harder than it needs to be. make it work first, then make it correct. |
17:28:44 | disruptek | ie. just import vulkan into platform and stop being so pedantic. :-P |
17:29:00 | FromGitter | <awr1> in general i would be fine with a shared types.nim it's just that to me this would predictably more annoying when doing doc generation |
17:29:06 | FromGitter | <awr1> *would be |
17:29:15 | FromGitter | <awr1> for a larger project |
17:29:43 | disruptek | i don't use shared types, but most of my code is greenfield, so i rarely run into problems that aren't of my own creation. |
17:38:22 | kuon__ | Ho I found the problem, I installed nimble from package manager and it was an older version. |
17:42:16 | * | jjido joined #nim |
18:05:18 | * | absolutejam2 joined #nim |
18:07:37 | * | absolutejam3 joined #nim |
18:09:46 | * | absolutejam2 quit (Ping timeout: 246 seconds) |
18:14:00 | * | jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
18:24:16 | * | chun quit (Remote host closed the connection) |
18:27:42 | FromGitter | <zacharycarter> everyone is jumping on the vulkan ship |
18:28:08 | FromGitter | <zacharycarter> still not 100% sure why - I guess it's just cool |
18:31:37 | * | nsf joined #nim |
18:34:48 | FromGitter | <zacharycarter> time to test out HCR :D |
18:35:50 | * | ibutra left #nim ("Textual IRC Client: www.textualapp.com") |
18:44:26 | kuon__ | I am starting with nim, and I have a working C app using SDL I port to nim for learning. In my C code, I have a lot of calls like if (SDL_Init(...)) { SDL_Log("error..."); exit(1); } how do you write that "the nim way" ? |
18:45:37 | disruptek | quit(1); the rest should work (minus the {}). |
18:48:04 | kuon__ | ok, so the structure remain the same? No need for other error handling mechanism (exception, whatever) ? |
18:48:33 | disruptek | what would you do if the init threw an error? |
18:49:15 | FromGitter | <zacharycarter> well... that doesn't appear to work at all |
18:49:22 | FromGitter | <zacharycarter> hotcodereloading I mean |
18:49:29 | kuon__ | well, right now if I have a low level error (SDL, opengl), I just abort the app |
18:49:38 | disruptek | sounds good to me. |
18:49:47 | kuon__ | If this is acceptable in nim, I just do it the same way. |
18:50:32 | disruptek | abortions are only against the law in alabama. |
18:50:46 | lqdev[m] | zacharycarter: remember that you need to request a reload manually |
18:50:56 | FromGitter | <zacharycarter> I am |
18:50:59 | FromGitter | <zacharycarter> here's what I did |
18:51:14 | FromGitter | <zacharycarter> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5d1f9c2211bfea0b67ad3471] |
18:51:28 | FromGitter | <zacharycarter> but `getStr` returns the same value |
18:51:39 | FromGitter | <zacharycarter> every time I press enter - regardless of what the other script contains |
18:51:55 | kuon__ | And what about namespace pollution and collision? I notice that doing import sdl2 just import everything in the file namespace. What about name conflict? |
18:51:58 | FromGitter | <zacharycarter> do I need to tell the hcr module about the script or something? |
18:52:12 | disruptek | what about it? |
18:52:45 | lqdev[m] | dunno, I never used it before. I just remembered that reloading must be done manually so I thought this might be your problem |
18:52:57 | kuon__ | If I import two package with an init() proc, how do I tell which is which? |
18:53:05 | FromGitter | <zacharycarter> ah gotcha |
18:53:22 | lqdev[m] | also, you can achieve a similar effect using the dynlib module, but it's nowhere as convenient |
18:53:34 | disruptek | kuon__: you can package1.init if they have the same signature. |
18:53:51 | Araq | the compiler will tell you when it's ambiguous |
18:54:01 | kuon__ | aah, it is distinguished by signature, then I can prefix the package name, ok thanks. |
18:54:22 | disruptek | it's one of those scary-on-paper-harmless-in-practice things. |
18:54:48 | Araq | it's harmless-on-paper too when you know anything about type systems |
18:55:09 | disruptek | well, if they have the same type... |
18:56:08 | Araq | then it's ambiguous |
18:56:44 | disruptek | i think that's what kuon meant by `collision`. |
18:57:53 | FromGitter | <awr1> @zacharycarter i plan on making a more nim-friendly vulkan library |
18:57:55 | kuon__ | Yeah that is what I meant, but the fact that I can prefix the package name resolve it |
18:58:07 | FromGitter | <zacharycarter> vulkan is not friendly :P |
18:59:23 | FromGitter | <zacharycarter> well I can't get the HCR stuff to work at all |
19:00:00 | FromGitter | <zacharycarter> `hasAnyModuleChanged` always returns `false` even though an imported module HAS changed and `performCodeReload` doesn't seem to do what it's supposed to |
19:01:43 | Araq | zacharycarter: read the new docs about it? |
19:02:14 | FromGitter | <zacharycarter> hrm I think so - I built the two shared libs and put them in the same dir as my executable, I added the switch to my config |
19:02:25 | FromGitter | <zacharycarter> but I'm probably still missing something |
19:03:13 | FromGitter | <awr1> which backend are you using? C or C++? |
19:03:39 | FromGitter | <awr1> i've run into problems with the C++ backend on HCR |
19:03:48 | FromGitter | <zacharycarter> C - I'm looking at these docs: https://nim-lang.org/docs/nimc.html |
19:04:19 | * | nsf quit (Quit: WeeChat 2.4) |
19:05:12 | * | kungtotte joined #nim |
19:06:11 | FromGitter | <zacharycarter> running with - `nim c -d:useNimRtl --hotcodereloading:on -r src\zeal.nim .` |
19:06:58 | FromGitter | <awr1> try `--hotcodereloading` without the `:on` |
19:07:28 | FromGitter | <zacharycarter> okay |
19:07:35 | FromGitter | <ratiotile> Does anyone know if `coro` is supposed to work in cpp mode? I'm getting link errors |
19:07:47 | FromGitter | <awr1> also you shouldn't try to reload every tcik |
19:07:49 | FromGitter | <zacharycarter> no dice |
19:07:59 | FromGitter | <zacharycarter> I'm not - I'm only reloading when stdin can be read |
19:08:09 | FromGitter | <zacharycarter> the program pauses and waits for stdin each iteration of the while loop |
19:08:11 | FromGitter | <awr1> oh i see |
19:08:30 | Araq | I used SDL2 and a keypress to reload, it worked really well |
19:08:42 | Araq | but before I got it to work I had the same problems as you |
19:08:43 | FromGitter | <zacharycarter> I wonder why it's not working for me |
19:08:51 | FromGitter | <zacharycarter> hrm - let me try in another main file |
19:09:13 | Araq | the logic MUST NOT be in the main file, main file is never reloaded |
19:09:19 | FromGitter | <awr1> iirc performCodeReloading() shouldn't be in main module |
19:09:21 | FromGitter | <awr1> yeah |
19:09:55 | FromGitter | <awr1> does nim output an error for that? |
19:10:03 | Araq | no... |
19:10:20 | FromGitter | <awr1> hm maybe i should do a PR |
19:10:41 | FromGitter | <zacharycarter> wait - so `performCodeReload` doesn't get called from the main file? |
19:10:58 | FromGitter | <awr1> it just "doesn't work" |
19:11:22 | FromGitter | <zacharycarter> I guess I'm confused as to how this works then |
19:11:49 | FromGitter | <awr1> just put your loop in another file |
19:11:53 | FromGitter | <awr1> and call it from the main module |
19:12:23 | FromGitter | <zacharycarter> call what from the main file? my loop? |
19:12:42 | FromGitter | <zacharycarter> oh I think I get what you're saying |
19:13:12 | Araq | https://github.com/nim-lang/Nim/blob/devel/doc/hcr.rst |
19:13:50 | Araq | please read this carefully |
19:14:28 | FromGitter | <zacharycarter> I hadn't seen this doc before - thanks |
19:16:20 | FromGitter | <zacharycarter> okay I get it now and got it working - thanks! |
19:16:59 | FromGitter | <ratiotile> Is there some dll I need to include in cpp mode that has GC_addStack? Because that is the linker error I get |
19:17:10 | disruptek | it's weird that there aren't some little examples that demonstrate some of these common little projects like hcr and sdl. |
19:17:36 | Araq | ratiotile: coro.nim is hardly supported, most use async instead |
19:17:41 | disruptek | maybe i just don't know about them. |
19:17:50 | Araq | disruptek: we have the worst marketing in the world... :-( |
19:17:54 | Zevv | ah, hcr, I wanted to check that out. I get "could not import: nimrtl_nimGCvisit |
19:18:06 | FromGitter | <ratiotile> I was testing async and surprised at how slow it is |
19:18:23 | disruptek | ratiotile: what, specifically? |
19:18:27 | Zevv | at run time. Where does that come from? |
19:19:04 | FromGitter | <ratiotile> something like 1000x slower than C++ coroutines |
19:19:39 | FromGitter | <ratiotile> I was going to benchmark `coro` as well to compare |
19:20:25 | FromGitter | <awr1> ideally for HCR reloads the build script could have some IPC mechanism to tell the app to reload |
19:20:27 | Zevv | ratiotile: maybe a obvious remark, but did you compile with -d:release? |
19:20:53 | kuon__ | nimpretty cannot be used with stdin to stdout? |
19:21:15 | kuon__ | I tried to pass /dev/stdin but nimpretty is getting smart and try to open /dev/stdin.nim |
19:21:16 | disruptek | async is just a code transformation, but the last time i finally whined about it being slow, it got fixed. so, please whine about it. |
19:23:27 | Araq | there is also nim-chronos that could be faster |
19:24:10 | disruptek | it's faster for some stuff on some platforms (linux). |
19:25:18 | FromGitter | <awr1> going to do a PR, i forget, if you point choosenim at a custom Nim directory, will it auto-build? |
19:26:01 | disruptek | why is it that old people don't understand weather? if you haven't figured this shit out by the time you are 70, you just aren't gonna. |
19:27:35 | disruptek | if you do build a benchmark, i'd be curious to see some golib results. there's a nim wrapper for it somewhere. |
19:28:02 | FromGitter | <ratiotile> my notes are not precise enough :( I'm going to rerun the benchmark. |
19:28:24 | disruptek | to the noisemobile, batman! |
19:28:28 | * | laaron quit (Remote host closed the connection) |
19:29:52 | FromGitter | <alehander42> they do get weather very well actually |
19:30:04 | * | laaron joined #nim |
19:30:29 | disruptek | i guess i need to upgrade my oldsters. |
19:37:43 | FromGitter | <awr1> does enabling HCR emit a define? |
19:37:48 | FromGitter | <awr1> i dont think it does |
19:37:58 | FromGitter | <awr1> should add one in the future maybe |
19:41:12 | FromGitter | <awr1> donezo https://github.com/nim-lang/Nim/pull/11667 |
19:47:51 | kuon__ | what is the * when declaring types? I am reading the SDL2 source, and it's type \n DisplayMode* = object |
19:49:21 | FromGitter | <awr1> can you elaborate? |
19:49:31 | FromGitter | <awr1> oh |
19:49:42 | FromGitter | <awr1> markdown confused me |
19:49:57 | FromGitter | <awr1> star just means publicly exported out of the module |
19:50:01 | kuon__ | it's not only for type, it's everywhere |
19:50:07 | kuon__ | Aaaaaah. Ok |
19:50:16 | kuon__ | I couldn't find it in the doc. |
19:51:10 | kuon__ | Well, it's because I should have searched "asterisk" I searched wildcard and star in the doc:) |
19:51:32 | FromGitter | <awr1> i feel like it should be one of the first things in the nim tutorial |
19:52:17 | FromGitter | <awr1> oh it's all the way at the bottom |
19:52:18 | FromGitter | <awr1> hm |
19:52:25 | FromGitter | <awr1> https://nim-lang.org/docs/tut1.html#modules |
19:52:28 | FromGitter | <awr1> oh well |
19:53:37 | kuon__ | it's writted under objects also https://nim-lang.org/docs/tut1.html#advanced-types-objects |
19:53:48 | kuon__ | but I didn't see it :) |
19:58:21 | * | narimiran joined #nim |
19:59:03 | kuon__ | There is something that puzzle me, I am reading https://github.com/nim-lang/sdl2/blob/master/src/sdl2.nim#L1200 and getDesktopDisplayMode takes a var DisplayMode while getClosestDisplayMode takes ptr DisplayMode |
19:59:34 | kuon__ | But in C, both take pointers https://wiki.libsdl.org/SDL_GetDesktopDisplayMode https://wiki.libsdl.org/SDL_GetClosestDisplayMode |
20:03:05 | FromGitter | <awr1> passing var is implicitly done w/ pointers iirc, similar to passing references in C++ |
20:04:19 | kuon__ | but why the different signatures in the SDL lib? |
20:05:18 | FromGitter | <awr1> i would guess ease-of-use (since ideally Nim programs should avoid using raw pointers) but there are some types in there that are ptr so...idk |
20:05:21 | * | uli00 joined #nim |
20:06:09 | FromGitter | <awr1> it's possible this could be some c2nim weirdness |
20:07:00 | * | Trustable joined #nim |
20:07:06 | kuon__ | ok |
20:07:10 | FromGitter | <awr1> https://github.com/Vladar4/sdl2_nim is the one that more closely matches the original SDL2 iirc. don't quote me on that |
20:07:13 | FromGitter | <awr1> but both should work fine |
20:08:08 | kuon__ | ok |
20:08:12 | kuon__ | Thanks |
20:24:39 | lqdev[m] | https://nim-lang.github.io/Nim/dynlib.html#loadLibPattern%2Cstring I think should be referring to the `dynlib` pragma, not `dlimport` (iirc this does not exist in the latest Nim) |
20:26:03 | lqdev[m] | also, the `global_symbols` parameter does not comform to NEP1's naming scheme |
20:26:22 | lqdev[m] | same with `loadLib` |
20:50:10 | Araq | awr1: the idea was to use 'var T' if it cannot be NULL |
20:50:47 | FromGitter | <ratiotile> ok I have benchmark numbers: nim is 6000ns per await, C++ is 20ns (both in release) |
20:52:28 | FromGitter | <ratiotile> so it's more like 300x slower |
20:52:45 | FromGitter | <awr1> @lqdev[m] PR them? |
20:53:27 | FromGitter | <alehander42> 30 |
20:53:34 | FromGitter | <alehander42> not 300 |
20:53:38 | FromGitter | <alehander42> but yeah, strange |
20:53:48 | FromGitter | <ratiotile> I suspect Nim's await is doing far more than my C++ coro implementation (duff's device) |
20:53:53 | FromGitter | <alehander42> oh no 300 |
20:54:07 | FromGitter | <alehander42> wow math is hard |
20:55:43 | Zevv | rayman22201: do you have a small test program? |
20:55:55 | Zevv | oh wrong msg sorry rayman22201, I ment ratiotile |
20:56:00 | Araq | ratiotile: share the benchmark with us please |
20:56:23 | Araq | but I mean, C++ has more compiler devs working on it than Nim |
20:57:15 | Zevv | yeah, but 6µS is a lot of time to spent on an await |
20:57:20 | FromGitter | <ratiotile> well, the C++ implementation is basically a switch and a loop |
20:57:29 | FromGitter | <ratiotile> Nim is pulling in sockets and stuff |
20:57:51 | Araq | oh better compare it to a raw .closure iterator then |
20:58:06 | Araq | we too compile the state machine to duff's device btw |
20:58:36 | FromGitter | <ratiotile> hmm I'll see if I can implement it using the closure |
20:58:56 | * | brakmic quit (Read error: Connection reset by peer) |
20:59:03 | FromGitter | <zacharycarter> Is something like this in Nim possible? ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5d1fba17b682244d498be447] |
20:59:11 | Araq | read the manual about to use them for a 'task' system |
20:59:35 | * | brakmic joined #nim |
20:59:38 | Araq | zacharycharter, yes, use 'cast' |
20:59:39 | stefanos82 | I was wondering; how does Nim makes sure that the generated code, whether that is C or C++, is always secure without memory leaks and such? Genuine curiosity here, not trying to disrespect or offend the language, let alone its dev team |
20:59:46 | FromGitter | <zacharycarter> thanks Araq - makes sense |
21:00:11 | Araq | the C codegen knows the 'cast' cannot be mapped to a C cast, but needs an interim union |
21:00:15 | FromGitter | <ratiotile> thanks, that was closer to what I was looking for - await is a bit heavyweight |
21:00:36 | FromGitter | <zacharycarter> gotcha - cast worked perfectly |
21:02:01 | Araq | stefanos82: we don't have a good answer, we use valgrind and the sanitizers occasionally but simply have many tests. With the --newruntime everything works so much better... |
21:02:20 | stefanos82 | ah good good :) |
21:02:35 | Araq | I dunno why people act like I'll take away something from them. the tool support will be so much better that it's ridiculous |
21:03:03 | kuon__ | Well, I have been coding in nim for my first day, and I ported 20% of a small embedded project written in C. I like it. I really love the easy interoperability with C. We can just replace C bit by bit. |
21:03:13 | FromGitter | <awr1> is there anything i should read to get started w/ newruntime |
21:03:27 | kuon__ | It took me a while to get it to cross compile for my embedded environment, but after a little makefile it works :) |
21:03:30 | FromGitter | <awr1> i've been seeing a lot of github issues and haven't had a chance to dive into it |
21:03:44 | Zevv | Araq: I guess the majority of concern is the misconception that goes around: people feel you're making them do Rust-like things |
21:04:53 | Araq | awr1: I'm slowly fixing the bugs, clybber is working on implementing the new spec |
21:05:03 | kuon__ | I have tried a lot of "C alternatives", and this is the first time I actually think this might be true. Of course there is rust, but I found rust so hard to write for prototyping. |
21:05:20 | kuon__ | Anyway, thanks for your assistance here. |
21:05:37 | Araq | kuon__: you're welcome |
21:05:58 | Araq | anyway... can we rename the 'manual' to the 'spec' or would that still be ridiculous? |
21:06:40 | * | jjido joined #nim |
21:07:00 | * | kuon__ quit (Remote host closed the connection) |
21:07:57 | * | narimiran_ joined #nim |
21:08:11 | FromGitter | <awr1> the thing is what is considered "the definition of nim" |
21:08:46 | FromGitter | <awr1> in terms of "if XYZ person were to make their own nim compiler from scratch" or w/e |
21:09:18 | FromGitter | <awr1> because that would have to logically include some of the stuff from `system.nim` that is tied directly to compilation |
21:10:08 | stefanos82 | Araq: well, to me a spec is a document that describes the technicalities of a language and its semantics, whereas a manual demonstrates how to use the language as a whole more or less |
21:10:47 | Araq | the manual is constantly evolving into a spec, that was the goal for a long time now |
21:10:58 | stefanos82 | then a spec that is! |
21:11:02 | Araq | "how to use it" is covered by the tutorial |
21:11:02 | * | narimiran quit (Ping timeout: 258 seconds) |
21:11:09 | stefanos82 | that's more like it |
21:11:53 | Araq | but I strive for more pseudo-code in the spec instead of "legalese" |
21:11:59 | disruptek | imo, the spec is the code, however correct or incorrect the output is. understanding what that is and why it is the job of the manual. |
21:12:04 | FromGitter | <awr1> how long is the manual |
21:12:06 | FromGitter | <awr1> 200 pages? |
21:12:10 | stefanos82 | maybe there could be a section called "manual" that contains the links to spec and tutorial and any other links that could be considered useful, such as cookbook tricks? |
21:12:11 | disruptek | it's useless to describe a system that is purely theoretical. |
21:12:16 | * | lf-araujo joined #nim |
21:12:25 | FromGitter | <awr1> oh 132 pages |
21:13:05 | disruptek | 6000ns is not correct as far as await goes; i see smaller figures in debug mode running actual work. can we see the code? |
21:14:10 | Araq | disruptek: well my ideal is Knuth's literate programming for the Nim spec/reference implementation |
21:14:34 | Araq | but we are a long way from that... |
21:14:35 | FromGitter | <awr1> i'm trying to remember why the C++ spec is so long . i guess the standard library definitions take up a big part of it |
21:14:57 | FromGitter | <ratiotile> disruptek: https://pastebin.com/JDJUjYQp |
21:15:49 | stefanos82 | Araq: you are touching some sensitive chords of mine brother...one day I will get the books on my shelf, ONE day! |
21:18:30 | Zevv | ratiotile: what is your exact nim version? |
21:19:00 | FromGitter | <ratiotile> Nim Compiler Version 0.20.0 [Windows: i386] |
21:19:18 | FromGitter | <ratiotile> tried x64, and it was similar times |
21:21:43 | FromGitter | <awr1> @Araq rust seems to be a similar situation? they have a "reference" that is technically not a spec |
21:21:45 | FromGitter | <awr1> https://doc.rust-lang.org/stable/reference/ |
21:21:46 | * | absolutejam4 joined #nim |
21:23:07 | disruptek | runnable examples is great. i hope we see more of that. |
21:24:06 | * | absolutejam3 quit (Ping timeout: 272 seconds) |
21:24:37 | Araq | disruptek: the examples in the manual are also checked automatically |
21:24:53 | * | Vladar quit (Remote host closed the connection) |
21:25:59 | stefanos82 | by the way, with every git pull I run on Nim repo and recompilation, the megatest executes faster and faster |
21:26:03 | stefanos82 | that's simply amazing |
21:26:20 | FromGitter | <ratiotile> It would be a good idea to mark clearly that `coro` doesn't work in cpp |
21:27:13 | narimiran_ | stefanos82: then do the git pull 50x a day, to optimize it even further :P |
21:27:33 | stefanos82 | narimiran_: I didn't say anything about optimization Mr Sarcasm |
21:27:46 | narimiran_ | :) |
21:27:58 | stefanos82 | I meant it performs better and better due to constant improvement |
21:28:07 | Araq | stefanos82: you're alone :-( for me Nim constantly keeps getting slower at compilation |
21:28:14 | narimiran_ | i know what you meant ;) |
21:28:26 | stefanos82 | Araq: weird... |
21:28:39 | stefanos82 | let me check it right now then |
21:28:56 | Zevv | fwiw: the top 10 perf output of ratiotile's code |
21:30:35 | disruptek | it's been a very long time since i cared how long compilation took, in any language. probably 25 years. computers are fast. code does what i cannot, and for free -- i never care how long it takes. |
21:31:50 | FromGitter | <ratiotile> I get the impression that people want the compiler to work like spellcheck |
21:33:03 | stefanos82 | Araq: 34.366s is slow to fully compile the language after syncing my repo? |
21:33:05 | disruptek | and if you find a mispelling, throw away the entire OS image and start over. |
21:34:10 | Araq | stefanos82: for me it cannot be fast enough, I use 'koch temp' + echo to debug the compiler. I should use -d:leanCompiler more often... |
21:34:27 | stefanos82 | ah I use build_all.sh |
21:34:28 | stefanos82 | that's all |
21:34:31 | stefanos82 | *why |
21:34:32 | disruptek | i was surprised at your dev process, tbh. |
21:35:18 | * | narimiran_ is now known as narimiran |
21:35:23 | Araq | disruptek: got some tips for me? :-) |
21:35:27 | disruptek | you'll never get that 34.366s back. and for what? all you got in return is a current nim with fewer bugs than last week, and better performance. sucks, don't it? |
21:36:50 | FromGitter | <awr1> i wonder how much faster it would become w/ incremental comp |
21:37:28 | disruptek | i mean, i don't know anything about the compiler. it's greek to me. i just know that if it were me, i'd have long since hacked at my dev mainloop. also, i am in a linux environment quite different from your vs code world. |
21:37:54 | Araq | it was instantaneous, awr1, back when it worked |
21:38:12 | Araq | and we had it working 6 years ago |
21:38:25 | FromGitter | <awr1> what broke it? |
21:38:33 | disruptek | who was it that was working on a repl? |
21:39:52 | Araq | awr1: compile-times were fast enough, the internal formats changed, it rotted |
21:40:33 | Araq | plus of course automatic testing of this feature was a pita. now I have some ideas of how to do it better |
21:40:51 | Zevv | ratiotile: http://ix.io/1NO7 lot of time is spent in genericAssignAux/genericSeqAssign. No clue what that tells me, though |
21:40:59 | Zevv | :) |
21:41:11 | Araq | ah that thing, gah |
21:41:43 | Araq | wanna take a guess if genericAssignAux is still a thing in --newruntime? |
21:41:57 | disruptek | lol |
21:42:35 | Zevv | /home/ico/external/Nim/lib/pure/asyncfutures.nim(171, 22) Error: assignment produces a dangling ref: the unowned ref lives longer than the owned ref |
21:42:39 | Zevv | aww |
21:43:56 | * | lf-araujo quit (Ping timeout: 252 seconds) |
21:44:35 | Araq | that's the elefant in the room |
21:45:20 | Araq | I *still* don't know if the newruntime can work with async. In theory there is no problem. But the theory overlooks so many details that I don't know. |
21:46:51 | federico3 | Araq: how was incremental compilation working? |
21:47:15 | * | solitudesf quit (Ping timeout: 268 seconds) |
21:47:37 | Araq | federico3: we mmap()ed an IR for every module |
21:48:03 | federico3 | ...and then? |
21:48:03 | Araq | the IR was optimized for size |
21:48:47 | Araq | and then we loaded the IR of the modules that didn't change and recompiled the modules that did change |
21:52:25 | federico3 | if the compiler had hooks for loading and storing IRs this could be used to reimplement incremental compilation but also distributed building |
21:57:33 | disruptek | is there documentation for this mysterious "lean compiler"? |
21:59:27 | * | lf-araujo joined #nim |
22:13:56 | Araq | disruptek: grep for leanCompiler |
22:14:11 | Araq | it's the compiler without the docgen and the crazy 'parallel' statement |
22:15:02 | Araq | federico3: maybe but first it has to work before we can make it "hookable" |
22:16:50 | * | Snircle quit (Read error: Connection reset by peer) |
22:17:34 | * | Snircle joined #nim |
22:23:22 | * | narimiran quit (Ping timeout: 245 seconds) |
22:29:17 | FromGitter | <ratiotile> what is the type of an instantiated iterator closure? |
22:33:01 | * | nsf joined #nim |
22:36:04 | * | brakmic quit () |
22:46:38 | * | lf-araujo quit (Ping timeout: 252 seconds) |
22:52:22 | * | uli00 quit (Remote host closed the connection) |
22:57:45 | * | nsf quit (Quit: WeeChat 2.4) |
22:59:44 | * | Trustable quit (Remote host closed the connection) |
23:03:25 | * | dwdv quit (Ping timeout: 246 seconds) |
23:04:43 | * | krux02_ joined #nim |
23:07:10 | * | krux02 quit (Ping timeout: 252 seconds) |
23:11:06 | * | smitop joined #nim |
23:14:49 | * | absolutejam4 quit (Ping timeout: 268 seconds) |
23:34:32 | * | krux02_ quit (Remote host closed the connection) |
23:35:09 | * | NimBot joined #nim |
23:42:13 | * | jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
23:53:55 | * | chun joined #nim |
23:54:19 | * | chun_ joined #nim |
23:54:26 | * | chun_ quit (Client Quit) |