Re: mmap file performance

2024-04-17 Thread kdevel via Digitalmars-d-learn
On Thursday, 11 April 2024 at 16:23:44 UTC, Andy Valencia wrote: [...] void main(in string[] argv) ^^ What if you want to use bool memorymapped; getopt (argv, "m", ); inside main? [1] Have you tried using "rm" [2] instead of "r" as stdioOpenmode under Linux for a "no code"

Re: Making one struct work in place of another for function calls.

2024-04-17 Thread cc via Digitalmars-d-learn
On Wednesday, 17 April 2024 at 03:13:46 UTC, Liam McGillivray wrote: On Wednesday, 17 April 2024 at 02:39:25 UTC, Paul Backus wrote: This is called [row polymorphism][1], and it does not exist in D. You could approximate it by making `someFunction` a template, and accepting any type `T` that

Re: Statically compiled binary with C interop crashes.

2024-04-17 Thread Ferhat Kurtulmuş via Digitalmars-d-learn
On Wednesday, 17 April 2024 at 11:03:22 UTC, yabobay wrote: I'm using [dray](https://code.dlang.org/packages/dray) in my project with dub, here's the relevant parts of the dub.json: [...] İt seems your issue is related to the raylib itself, neither the binding you use nor the d programming

Statically compiled binary with C interop crashes.

2024-04-17 Thread yabobay via Digitalmars-d-learn
I'm using [dray](https://code.dlang.org/packages/dray) in my project with dub, here's the relevant parts of the dub.json: ```json "dependencies" : {"dray": "~>4.2.0-r3"}, "dflags-ldc": ["--static"], "lflags": ["-static"] ``` In my regular setup with Debian, i can compile and run my

Re: How to set include paths of a c source in dub when using importc

2024-04-17 Thread Ferhat Kurtulmuş via Digitalmars-d-learn
On Wednesday, 17 April 2024 at 00:40:28 UTC, Alex Bryan wrote: If you're not using gdc exclusively, you'll want to take a look at this: https://github.com/dlang/dub/pull/2818 I knew there was something wrong there.