On Thursday, 16 March 2023 at 04:31:11 UTC, Elfstone wrote:
On Thursday, 16 March 2023 at 04:04:51 UTC, Elfstone wrote:
On Thursday, 16 March 2023 at 03:44:19 UTC, Elfstone wrote:
[...]
Correction.
With or without comments, mostly it doesn't compile,
occasionally it does!
I have no idea.
On Thursday, 16 March 2023 at 04:04:51 UTC, Elfstone wrote:
On Thursday, 16 March 2023 at 03:44:19 UTC, Elfstone wrote:
On Thursday, 16 March 2023 at 03:40:04 UTC, Elfstone wrote:
[...]
Oops, the above code compiles, because I added comments!!!
Now this really doesn't compile:
```D
struct M
On Thursday, 16 March 2023 at 03:44:19 UTC, Elfstone wrote:
On Thursday, 16 March 2023 at 03:40:04 UTC, Elfstone wrote:
[...]
Oops, the above code compiles, because I added comments!!!
Now this really doesn't compile:
```D
struct Matrix(S, size_t M, size_t N)
{
}
alias Vec3(S) = Matrix!(S,
```D
struct Matrix(S, size_t M, size_t N)
{
}
alias Vec3(S) = Matrix!(S, 3, 1);
void main()
{
import std.stdio;
writeln(is(Vec3!float == Matrix!(S, 3, 1), S)); // `alias`
`S` is defined here
writeln(is(Matrix!(float, 3, 1) == Matrix!(S, 3, 1), S)); //
Error: declaration `S` is alr
On Thursday, 16 March 2023 at 03:40:04 UTC, Elfstone wrote:
```D
struct Matrix(S, size_t M, size_t N)
{
}
alias Vec3(S) = Matrix!(S, 3, 1);
void main()
{
import std.stdio;
writeln(is(Vec3!float == Matrix!(S, 3, 1), S)); // `alias`
`S` is defined here
writeln(is(Matrix!(float, 3, 1
On Wednesday, 15 March 2023 at 19:22:32 UTC, Paul Backus wrote:
On Tuesday, 14 March 2023 at 10:19:24 UTC, Elfstone wrote:
[...]
Currently the best workaround for this is to define `Vector` as
a `struct` with `alias this` instead of as an `alias`:
```d
struct Matrix(S, size_t M, size_t N)
{
I replicated it, copied the Dist folder from the zip beside app.json,
set the right file to load and it worked.
http://downloads.sourceforge.net/freeimage/FreeImage3180Win32Win64.zip
```
$ dub run
Starting Performing "debug" build using
C:\Tools\D\ldc2-1.31.0-windows-multilib\bin\ldc2.exe
On Wednesday, 15 March 2023 at 22:09:35 UTC, WhatMeWorry wrote:
I appreciate all the help people have given me previously. So
I've made everything super simple. The dub.sdl file consists
of four lines:
- Solution to this problem: Checking whether it exists is
completely irrelevant if you do
I appreciate all the help people have given me previously. So
I've made everything super simple. The dub.sdl file consists of
four lines:
name "00_03_freeimage_debug"
dependency "bindbc-glfw" version="~>1.0.0"
dependency "bindbc-freeimage" version="~>1.0.2"
versions "FI_318"
The app.d use ex
On Wednesday, 15 March 2023 at 19:27:19 UTC, Paul Backus wrote:
It's shorthand for defining an unnamed `enum` with a single
member: ...
Ah, I see. Thanks!
On Wednesday, 15 March 2023 at 16:40:52 UTC, bomat wrote:
Just out of curiosity:
Can you explain to me why this is called an `enum` although
it's clearly not an enumeration?
Seems like a random abuse of a keyword...
It's shorthand for defining an unnamed `enum` with a single
member:
```d
e
On Tuesday, 14 March 2023 at 10:19:24 UTC, Elfstone wrote:
I went back to some of my old code and couldn't stand what I
had ended up with - If I already have a well-defined `Vector`,
why do I have to write extra code to implement `isVector`, and
use `isVector` instead of simply declaring the pa
Just out of curiosity:
Can you explain to me why this is called an `enum` although it's
clearly not an enumeration?
Seems like a random abuse of a keyword...
13 matches
Mail list logo