Warning The package will no longer be detected starting from v1.42.0

2023-06-24 Thread Soulsbane via Digitalmars-d-learn
Most of my homegrown libraries are private and are used locally for the most part. They are in ~/Projects/D/libs . Until now I've always used dub add-path and things worked fine. Updated my install am now getting this message: ``` Warning Package at path

Re: Mixin and compile-time functions for code generation

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
On Saturday, 24 June 2023 at 17:43:52 UTC, Adam D Ruppe wrote: On Saturday, 24 June 2023 at 17:31:31 UTC, Cecil Ward wrote: Can I get mixin whatever to do this for me? Mixin with a function that runs at compile-time and creates the required source ? have you tried it? No, not so far. Adam,

Re: How to setup dub project for contributing to a dub package?

2023-06-24 Thread Ferhat Kurtulmuş via Digitalmars-d-learn
On Friday, 23 June 2023 at 15:22:33 UTC, Ki Rill wrote: Recently, I tried to set up `dcv` with `dub` to improve a few things in the library, but I faced some strange issues. [...] I recommend adding DCV sub packages separately. Don't add the entire thing to your dub dependencies. Just only

Re: How to setup dub project for contributing to a dub package?

2023-06-24 Thread Ferhat Kurtulmuş via Digitalmars-d-learn
On Friday, 23 June 2023 at 15:52:44 UTC, Richard (Rikki) Andrew Cattermole wrote: First things first, dcv is added to the dub-registry, so use this. https://code.dlang.org/packages/dcv ```json "dependencies": { "dcv": "~>0.3.0" } ``` For ffmpeg the binding tells you what to add for

Re: Mixin and compile-time functions for code generation

2023-06-24 Thread Adam D Ruppe via Digitalmars-d-learn
On Saturday, 24 June 2023 at 17:31:31 UTC, Cecil Ward wrote: Can I get mixin whatever to do this for me? Mixin with a function that runs at compile-time and creates the required source ? have you tried it?

Mixin and compile-time functions for code generation

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
I have a function that can be run at compile-time and which will be able to output code to be injected into the D source code stream. Can I get mixin whatever to do this for me? Mixin with a function that runs at compile-time and creates the required source ? Like D’s solution for a

Re: How does D’s ‘import’ work?

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
On Tuesday, 20 June 2023 at 17:56:27 UTC, Ali Çehreli wrote: On 6/20/23 08:09, Cecil Ward wrote: > I’m used to slow compilers on fast machines and compiling > gives me an excuse for more coffee and possibly fruity buns. Yes, all of us in past projects accepted C++'s slowness. We did get

Compiling the runtime library

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
Is it possible to recompile the LDC and GDC runtimes yourself so you can do so with the switches you desire? (eg regarding optimisation, release vs debug build modes.) I think I saw a mention of something to help with this in the LDC docs, GDC would be a different story though. I’d have to

Unused routines and inlining

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
(Apologies if I have talked about this before, but my memory is shot because of strong pain drugs that I’m on, and it never was any good before either, so I may be repeating myself.) I’m using GDC and LDC, comparing the two, and in a medium sized routine that I have written pretty much every

Re: Unused routines and inlining

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
On Saturday, 24 June 2023 at 16:55:05 UTC, Cecil Ward wrote: (Apologies if I have talked about this before, but my memory is shot because of strong pain drugs that I’m on, and it never was any good before either, so I may be repeating myself.) [...] s/medium sized routine/medium-sized

Re: A couple of questions about arrays and slices

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
On Saturday, 24 June 2023 at 16:42:45 UTC, Cecil Ward wrote: On Saturday, 24 June 2023 at 15:12:14 UTC, Jonathan M Davis wrote: [...] Yeah, it would take me forever to get my head around that, and I only want a crude toy partial parser for certain portions of the grammar, and the parsing

Re: A couple of questions about arrays and slices

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
On Saturday, 24 June 2023 at 15:12:14 UTC, Jonathan M Davis wrote: On Saturday, June 24, 2023 8:43:00 AM MDT Cecil Ward via Digitalmars-d-learn wrote: I started out looking into a number of runtime library routines, but in the end it seemed quicker to roll my own code for a crude recursive

Re: Toolchain with ldc and AArch64 OSX

2023-06-24 Thread max haughton via Digitalmars-d-learn
On Saturday, 24 June 2023 at 15:16:37 UTC, Cecil Ward wrote: I have LDC running on an ARM Mac. If anyone else out there is an LDC or GDC user, could you knock up a quick shell program to compile and link a .d file to produce an executable ? found the linker but these tools are all new to me

Toolchain with ldc and AArch64 OSX

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
I have LDC running on an ARM Mac. If anyone else out there is an LDC or GDC user, could you knock up a quick shell program to compile and link a .d file to produce an executable ? found the linker but these tools are all new to me and a bit of help would save me a lot of trial and error and

Re: A couple of questions about arrays and slices

2023-06-24 Thread Jonathan M Davis via Digitalmars-d-learn
On Saturday, June 24, 2023 8:43:00 AM MDT Cecil Ward via Digitalmars-d-learn wrote: > I started out looking into a number of runtime library routines, > but in the end it seemed quicker to roll my own code for a crude > recursive descent parser/lexer that parses part of D’s grammar > for

Re: A couple of questions about arrays and slices

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
On Saturday, 24 June 2023 at 12:05:26 UTC, Jonathan M Davis wrote: On Saturday, June 24, 2023 1:43:53 AM MDT Cecil Ward via Digitalmars-d-learn wrote: On Saturday, 24 June 2023 at 07:36:26 UTC, Cecil Ward wrote: > [...] I just realised something, your point about altering the table and having

Re: A couple of questions about arrays and slices

2023-06-24 Thread Jonathan M Davis via Digitalmars-d-learn
On Saturday, June 24, 2023 1:43:53 AM MDT Cecil Ward via Digitalmars-d-learn wrote: > On Saturday, 24 June 2023 at 07:36:26 UTC, Cecil Ward wrote: > > Jonathan, is it possible that I wanted one thing and got > > another? My description in the earlier post was of the _aim_ of > > the program. What

Issues in the gprof output report

2023-06-24 Thread Pavankumar S V via Digitalmars-d-learn
Hello, I have followed these steps to generate a profiling data from gprof: 1) -pg flag added for both compiler and linker while compiling. Also added compiler flags like -fno-inline-functions, -fno-builtin, -no-pie as suggested in many online forums. 2) Executed the program and got the

Re: A couple of questions about arrays and slices

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
On Saturday, 24 June 2023 at 07:36:26 UTC, Cecil Ward wrote: Jonathan, is it possible that I wanted one thing and got another? My description in the earlier post was of the _aim_ of the program. What I ended up with might be something else? I wanted an array of uints whose values are the

Re: A couple of questions about arrays and slices

2023-06-24 Thread Cecil Ward via Digitalmars-d-learn
On Saturday, 24 June 2023 at 01:28:03 UTC, Jonathan M Davis wrote: On Friday, June 23, 2023 7:02:12 PM MDT Cecil Ward via Digitalmars-d-learn wrote: I just had a fight with LDC over the following code when I tried out reserve. I have an associative array that maps strings to ‘ordinals’ ie

Re: A couple of questions about arrays and slices

2023-06-24 Thread Ali Çehreli via Digitalmars-d-learn
On 6/20/23 19:09, Cecil Ward wrote: > 2.) I have a dynamic array and I wish to preinitialise its alloc cell to > be a certain large size so that I don’t need to reallocate often To be complete, 'assumeSafeAppend' must be mentioned here as well. Without it, there will be cases where the GC