Re: Fixed length vs dynamic arrays

2021-05-06 Thread Paul Backus via Digitalmars-d-learn
On Thursday, 6 May 2021 at 22:35:38 UTC, Alain De Vos wrote: Is a fixed length array created on the heap and a dynamic array on the stack ? And is this important with relation to the garbage collector ? Static arrays (`T[N]`) are value types, like structs. If you declare them as local

Fixed length vs dynamic arrays

2021-05-06 Thread Alain De Vos via Digitalmars-d-learn
Is a fixed length array created on the heap and a dynamic array on the stack ? And is this important with relation to the garbage collector ?

Re: What does @nogc do to a class?

2021-05-06 Thread Per Nordlöw via Digitalmars-d-learn
On Thursday, 6 May 2021 at 01:04:02 UTC, Jack wrote: Does it allocate the object rather on stack, like auto scope a = new A or what? Further note that auto scope a = new A; can be written shorter as scope a = new A;

Re: Can the DMC completely replace the C or C ++ compiler?

2021-05-06 Thread Alain De Vos via Digitalmars-d-learn
If you only compile D programs you only need one compiler. E.g. , ldmd2 , rdmd , ldc2

Re: Can the DMC completely replace the C or C ++ compiler?

2021-05-06 Thread Adam D. Ruppe via Digitalmars-d-learn
On Thursday, 6 May 2021 at 20:21:32 UTC, Marcone wrote: Is it compatible with C++ 17 or 20? No, it is based on the 1998 standard.

Re: Can the DMC completely replace the C or C ++ compiler?

2021-05-06 Thread Marcone via Digitalmars-d-learn
On Thursday, 6 May 2021 at 20:10:29 UTC, Adam D. Ruppe wrote: On Thursday, 6 May 2021 at 19:59:01 UTC, Marcone wrote: Well, I am writing a C++ program and compiling with DMC Digital Mars, and the program is running normally. Can the DMC completely replace the C or C ++ compiler? It IS a C

Re: Can the DMC completely replace the C or C ++ compiler?

2021-05-06 Thread Adam D. Ruppe via Digitalmars-d-learn
On Thursday, 6 May 2021 at 19:59:01 UTC, Marcone wrote: Well, I am writing a C++ program and compiling with DMC Digital Mars, and the program is running normally. Can the DMC completely replace the C or C ++ compiler? It IS a C and C++ compiler.

Can the DMC completely replace the C or C ++ compiler?

2021-05-06 Thread Marcone via Digitalmars-d-learn
Well, I am writing a C++ program and compiling with DMC Digital Mars, and the program is running normally. Can the DMC completely replace the C or C ++ compiler?

Re: What does @nogc do to a class?

2021-05-06 Thread Jack via Digitalmars-d-learn
On Thursday, 6 May 2021 at 02:11:27 UTC, Mike Parker wrote: On Thursday, 6 May 2021 at 01:04:02 UTC, Jack wrote: Does it allocate the object rather on stack, like auto scope a = new A or what? It doesn't do anything to classes. `@nogc` prevents you from any action triggers a GC allocation,

Re: How suppress DMC File name and path showing after compile?

2021-05-06 Thread Marcone via Digitalmars-d-learn
On Thursday, 6 May 2021 at 16:00:03 UTC, Paul Backus wrote: On Thursday, 6 May 2021 at 15:55:07 UTC, Marcone wrote: dmc Programa.cpp && Programa.exe is showing this, but I want show only "Hello World!" C:\Users\Usuario\Arquivos\Estudando\C\Programa.cpp: <--- I don't want DMC show this.

Re: How suppress DMC File name and path showing after compile?

2021-05-06 Thread Paul Backus via Digitalmars-d-learn
On Thursday, 6 May 2021 at 15:55:07 UTC, Marcone wrote: dmc Programa.cpp && Programa.exe is showing this, but I want show only "Hello World!" C:\Users\Usuario\Arquivos\Estudando\C\Programa.cpp: <--- I don't want DMC show this. Hello World! [Finished in 0.2s] Redirect the compiler's output

How suppress DMC File name and path showing after compile?

2021-05-06 Thread Marcone via Digitalmars-d-learn
dmc Programa.cpp && Programa.exe is showing this, but I want show only "Hello World!" C:\Users\Usuario\Arquivos\Estudando\C\Programa.cpp: <--- I don't want DMC show this. Hello World! [Finished in 0.2s]

Re: Thoughts on Structure

2021-05-06 Thread Alain De Vos via Digitalmars-d-learn
As a random example code check-in for d binding to wxwindows, https://github.com/gwichert/wxd/graphs/code-frequency