Re: determine ldc version in static if or version?

2020-04-02 Thread Arine via Digitalmars-d-learn
On Thursday, 2 April 2020 at 01:35:42 UTC, Adam D. Ruppe wrote: On Thursday, 2 April 2020 at 01:27:26 UTC, Nicholas Wilson wrote: https://github.com/ldc-developers/druntime/blob/ldc/src/ldc/intrinsics.di#L22-L34 ah excellent that will do. thanks! Not sure if that is what you are looking for.

Re: Best way to learn 2d games with D?

2020-03-16 Thread Arine via Digitalmars-d-learn
On Monday, 16 March 2020 at 16:42:56 UTC, Mike Parker wrote: On Monday, 16 March 2020 at 16:19:26 UTC, Arine wrote: There's no need for someone learning 2D games to even bother with SDL2 to begin with. If you use SDL2 you are going to be using something no one else uses, you'll be wasting your

Re: Best way to learn 2d games with D?

2020-03-16 Thread Arine via Digitalmars-d-learn
On Monday, 16 March 2020 at 03:03:15 UTC, Mike Parker wrote: On Sunday, 15 March 2020 at 21:33:29 UTC, Arine wrote: I wouldn't use SDL2 for rendering. It is really just there for legacy. The only thing people use SDL2 is for setting up a window and creating a render context for OpenGL/Vulka

Re: What is the wrong with my C++ interfacing

2020-03-15 Thread Arine via Digitalmars-d-learn
On Sunday, 15 March 2020 at 21:27:32 UTC, Ferhat Kurtulmuş wrote: On Sunday, 15 March 2020 at 21:16:43 UTC, Arine wrote: On Sunday, 15 March 2020 at 20:53:49 UTC, Ferhat Kurtulmuş I wouldn't use a class on the D side, unless your C++ type uses virtual functions. Classes in D are different fro

Re: Best way to learn 2d games with D?

2020-03-15 Thread Arine via Digitalmars-d-learn
On Sunday, 15 March 2020 at 20:19:17 UTC, Steven Schveighoffer wrote: On 3/15/20 4:12 PM, Jordan Wilson wrote: On Sunday, 15 March 2020 at 17:58:58 UTC, Steven Schveighoffer wrote: I want to try and learn how to write 2d games. I'd prefer to do it with D. I've found a ton of tutorials on lear

Re: What is the wrong with my C++ interfacing

2020-03-15 Thread Arine via Digitalmars-d-learn
On Sunday, 15 March 2020 at 20:53:49 UTC, Ferhat Kurtulmuş wrote: On Sunday, 15 March 2020 at 20:46:14 UTC, drug wrote: 15.03.2020 23:25, Ferhat Kurtulmuş пишет: On Sunday, 15 March 2020 at 20:21:57 UTC, drug wrote: 15.03.2020 22:39, Ferhat Kurtulmuş пишет: What is the D version of `create

Re: Idiomatic way to express errors without resorting to exceptions

2020-03-07 Thread Arine via Digitalmars-d-learn
On Saturday, 29 February 2020 at 15:23:02 UTC, Sebastiaan Koppe wrote: Like I said, I don't use optionals when I care about errors. That is not what they are designed for. If I want to type-guard potential errors I will use SumType!(T, Error). It forces you to handle both cases, either at comp