https://gist.github.com/crazymonkyyy/f3d40f5b7c0454bfaa118d5a73a3fe1c
dlopen is one of the functions not really documented in core, its api really sucks. This section of d could use some love.
Thread overview |
---|
May 16 hot reloading code gist | ||||
---|---|---|---|---|
| ||||
https://gist.github.com/crazymonkyyy/f3d40f5b7c0454bfaa118d5a73a3fe1c dlopen is one of the functions not really documented in core, its api really sucks. This section of d could use some love. |
May 15 Re: hot reloading code gist | ||||
---|---|---|---|---|
| ||||
Posted in reply to monkyyy | On Fri, May 16, 2025 at 01:03:46AM +0000, monkyyy via Digitalmars-d wrote: > https://gist.github.com/crazymonkyyy/f3d40f5b7c0454bfaa118d5a73a3fe1c > > dlopen is one of the functions not really documented in core, its api really sucks. This section of d could use some love. dlopen is a POSIX call. It sux because it's an OS C API, and there's nothing we can do about it. T -- Bomb technician: If I'm running, try to keep up. |
May 16 Re: hot reloading code gist | ||||
---|---|---|---|---|
| ||||
Posted in reply to H. S. Teoh | On Friday, 16 May 2025 at 03:18:38 UTC, H. S. Teoh wrote: >dlopen is a POSIX call. It sux because it's an OS C API, and there's nothing we can do about it. We do have |
May 30 Re: hot reloading code gist | ||||
---|---|---|---|---|
| ||||
Posted in reply to monkyyy | On Friday, 16 May 2025 at 01:03:46 UTC, monkyyy wrote: >https://gist.github.com/crazymonkyyy/f3d40f5b7c0454bfaa118d5a73a3fe1c dlopen is one of the functions not really documented in core, its api really sucks. This section of d could use some love. Id like to extend this to work with more then one function per file; whats a "good enough" target for api given that Im parsing code manually, or my previous experience with trying to grab functions from a module is just a mess. |
May 30 Re: hot reloading code gist | ||||
---|---|---|---|---|
| ||||
Posted in reply to Ogion | On Friday, 16 May 2025 at 08:37:34 UTC, Ogion wrote: >On Friday, 16 May 2025 at 03:18:38 UTC, H. S. Teoh wrote: >dlopen is a POSIX call. It sux because it's an OS C API, and there's nothing we can do about it. We do have We have the libraray "bindbc-loader", which solves this exactly problem |
May 30 Re: hot reloading code gist | ||||
---|---|---|---|---|
| ||||
Posted in reply to Hipreme | On Friday, 30 May 2025 at 17:52:19 UTC, Hipreme wrote: >On Friday, 16 May 2025 at 08:37:34 UTC, Ogion wrote: >On Friday, 16 May 2025 at 03:18:38 UTC, H. S. Teoh wrote: >dlopen is a POSIX call. It sux because it's an OS C API, and there's nothing we can do about it. We do have We have the libraray "bindbc-loader", which solves this exactly problem Hotloading local d code vs dymanic loading some big c lib probably are different problems. |
May 30 Re: hot reloading code gist | ||||
---|---|---|---|---|
| ||||
Posted in reply to monkyyy | On Friday, 30 May 2025 at 18:04:14 UTC, monkyyy wrote: >On Friday, 30 May 2025 at 17:52:19 UTC, Hipreme wrote: >On Friday, 16 May 2025 at 08:37:34 UTC, Ogion wrote: >On Friday, 16 May 2025 at 03:18:38 UTC, H. S. Teoh wrote: >dlopen is a POSIX call. It sux because it's an OS C API, and there's nothing we can do about it. We do have We have the libraray "bindbc-loader", which solves this exactly problem Hotloading local d code vs dymanic loading some big c lib probably are different problems. They are exactly the same thing. The only other use-case I know, is that it is possible to hotload class code, which I don't use and never saw any project using. I've been hot reloading my code for more than 3 years now. |
May 31 Re: hot reloading code gist | ||||
---|---|---|---|---|
| ||||
Posted in reply to monkyyy | On Friday, 30 May 2025 at 18:04:14 UTC, monkyyy wrote: >On Friday, 30 May 2025 at 17:52:19 UTC, Hipreme wrote: >On Friday, 16 May 2025 at 08:37:34 UTC, Ogion wrote: >On Friday, 16 May 2025 at 03:18:38 UTC, H. S. Teoh wrote: >dlopen is a POSIX call. It sux because it's an OS C API, and there's nothing we can do about it. We do have We have the libraray "bindbc-loader", which solves this exactly problem Hotloading local d code vs dymanic loading some big c lib probably are different problems. https://github.com/ddovod/jet-live This is for C++, but the logic is language agnostic, with some work, you could make it work for D, (strip the C++ compile part, and reuse the parsing and process patching patch). I've seen people make it work for Zig, this is much better than shared library reload, since the user has no build script to duplicate or code to separate. https://www.jakubkonka.com/2022/03/16/hcs-zig.html It's ARM in that example, but they plan to make it available for all the supported targets, built right in the compiler. The day they land that feature will be the day I switch. |
May 31 Re: hot reloading code gist | ||||
---|---|---|---|---|
| ||||
Posted in reply to xoxo | On Saturday, 31 May 2025 at 06:29:03 UTC, xoxo wrote: >A quick skim suggest they exploded the complexity budget. Im wondering if thats oo or c++ having much worse meta-programming then I previously believed I should probably try to do file watching tho. |
1 day ago Re: hot reloading code gist | ||||
---|---|---|---|---|
| ||||
Posted in reply to Hipreme | On Friday, 30 May 2025 at 17:52:19 UTC, Hipreme wrote: >On Friday, 16 May 2025 at 08:37:34 UTC, Ogion wrote: >We do have We have the libraray "bindbc-loader", which solves this exactly problem I mean, this should be in the standard library. |