Re: running a d compiler on the Mac Mini with an M1 chip

2021-03-26 Thread dan via Digitalmars-d-learn
On Friday, 26 March 2021 at 21:54:20 UTC, rikki cattermole wrote: On 27/03/2021 10:51 AM, dan wrote: Are there any d compilers that run natively on the Mac Mini with an M1 chip? If so, does anybody here have any experience with them that can be shared? If not, and your machine is a mac

Re: running a d compiler on the Mac Mini with an M1 chip

2021-03-26 Thread rikki cattermole via Digitalmars-d-learn
On 27/03/2021 10:51 AM, dan wrote: Are there any d compilers that run natively on the Mac Mini with an M1 chip? If so, does anybody here have any experience with them that can be shared? If not, and your machine is a mac mini, how would you go about programming in d on it? TIA for any

running a d compiler on the Mac Mini with an M1 chip

2021-03-26 Thread dan via Digitalmars-d-learn
Are there any d compilers that run natively on the Mac Mini with an M1 chip? If so, does anybody here have any experience with them that can be shared? If not, and your machine is a mac mini, how would you go about programming in d on it? TIA for any info!

Re: How can I allocate a int[] array on stack?

2021-03-26 Thread Simen Kjærås via Digitalmars-d-learn
On Friday, 26 March 2021 at 14:27:58 UTC, Jack wrote: On Friday, 26 March 2021 at 06:45:39 UTC, Daniel Kozak wrote: On Fri, Mar 26, 2021 at 7:36 AM Daniel Kozak wrote: On Fri, Mar 26, 2021 at 7:31 AM Daniel Kozak wrote: On Fri, Mar 26, 2021 at 6:50 AM Jack via Digitalmars-d-learn <

Re: How can I allocate a int[] array on stack?

2021-03-26 Thread Jack via Digitalmars-d-learn
On Friday, 26 March 2021 at 06:45:39 UTC, Daniel Kozak wrote: On Fri, Mar 26, 2021 at 7:36 AM Daniel Kozak wrote: On Fri, Mar 26, 2021 at 7:31 AM Daniel Kozak wrote: On Fri, Mar 26, 2021 at 6:50 AM Jack via Digitalmars-d-learn < digitalmars-d-learn@puremagic.com> wrote: What's the

Re: isPOD is broken?

2021-03-26 Thread kinke via Digitalmars-d-learn
A class *reference* is always a POD. Only structs can be non-PODs.

isPOD is broken?

2021-03-26 Thread Oleg B via Digitalmars-d-learn
Hi all! class Foo { private int val; this(int v) { val = v; } int vv() { return val*2; } ~this() { } } class Bar : Foo { this(int v) { super(v); } override int vv() { return val*3; } } pragma(msg, __traits(isPOD, Foo)); pragma(msg, __traits(isPOD, Bar)); prints true

Re: How can I allocate a int[] array on stack?

2021-03-26 Thread Daniel Kozak via Digitalmars-d-learn
On Fri, Mar 26, 2021 at 7:31 AM Daniel Kozak wrote: > On Fri, Mar 26, 2021 at 6:50 AM Jack via Digitalmars-d-learn < > digitalmars-d-learn@puremagic.com> wrote: > >> What's the equivalent of C's VLA in D? scoped from std.typecons >> doesn't seem to work with arrays. Should I use alloca() for my

Re: How can I allocate a int[] array on stack?

2021-03-26 Thread Daniel Kozak via Digitalmars-d-learn
On Fri, Mar 26, 2021 at 7:36 AM Daniel Kozak wrote: > On Fri, Mar 26, 2021 at 7:31 AM Daniel Kozak wrote: > >> On Fri, Mar 26, 2021 at 6:50 AM Jack via Digitalmars-d-learn < >> digitalmars-d-learn@puremagic.com> wrote: >> >>> What's the equivalent of C's VLA in D? scoped from std.typecons >>>

Re: How can I allocate a int[] array on stack?

2021-03-26 Thread Daniel Kozak via Digitalmars-d-learn
On Fri, Mar 26, 2021 at 6:50 AM Jack via Digitalmars-d-learn < digitalmars-d-learn@puremagic.com> wrote: > What's the equivalent of C's VLA in D? scoped from std.typecons > doesn't seem to work with arrays. Should I use alloca() for my > array or is there something else? >