Re: CTFE in betterC needs the GC

2022-10-29 Thread arandomonlooker via Digitalmars-d-learn
On Sunday, 30 October 2022 at 04:14:17 UTC, Ali Çehreli wrote: On 10/29/22 20:41, arandomonlooker wrote: > [...] Although you need that function only at compile time, it is an ordinary function that could be called at run time as well. The function needs GC for that concatenation in the

Re: CTFE in betterC needs the GC

2022-10-29 Thread Ali Çehreli via Digitalmars-d-learn
On 10/29/22 20:41, arandomonlooker wrote: > string exampleCTFE(string a, string b) { > return a ~ b; > } Although you need that function only at compile time, it is an ordinary function that could be called at run time as well. The function needs GC for that concatenation in the general

CTFE in betterC needs the GC

2022-10-29 Thread arandomonlooker via Digitalmars-d-learn
Hello, i'm a beginner to the D programming language that has posted many times for simple questions and code errors. I have written a function that manipulates D code (passed through a q{...} block) and returns it to be compiled into the program by a mixin. The problem is that i need to do so