21 hours ago Issues » [Issue 24892] We need a __traits trait to test for whether one class is derived from another | |||
|---|---|---|---|
| |||
https://issues.dlang.org/show_bug.cgi?id=24892 --- Comment #4 from Dennis <dkorpel@live... | |||
1 day ago Issues » [Issue 24892] We need a __traits trait to test for whether one class is derived from another | |||
|---|---|---|---|
| |||
...test for whether a class was derived from a specific class in order to do... | |||
1 day ago General » Re: Something like ADL from C++? | |||
|---|---|---|---|
| |||
...realThis));
}
}
class MyClass : SerializationRoot { }
class MyOtherClass : SerializationRoot {
this(int) { }
override void serialize() {
writeln("This class... | |||
1 day ago Issues » [Issue 24892] We need a __traits trait to test for whether one class is derived from another | |||
|---|---|---|---|
| |||
...a template function accepts a generic struct/class, the constraints test for capabilities (like having... | |||
1 day ago General » Re: Something like ADL from C++? | |||
|---|---|---|---|
| |||
...std;
interface ISerialize {
void serialize();
}
struct thing{ }
class SerializableRoot {
void serialize(this T)() {
// serialize here... | |||
1 day ago Issues » [Issue 24892] We need a __traits trait to test for whether one class is derived from another | |||
|---|---|---|---|
| |||
https://issues.dlang.org/show_bug.cgi?id=24892 Richard (Rikki) Andrew Cattermole <alphaglosined@gmail... | |||
1 day ago Issues » [Issue 24892] New: We need a __traits trait to test for whether one class is derived from another | |||
|---|---|---|---|
| |||
...foo;
static assert(is(Foo : A));
}
class A {}
class Foo
{
A a;
alias this = a... | |||
1 day ago DIP Ideas » Re: Struct inheritance | |||
|---|---|---|---|
| |||
...conversions aren't involved. And even for class inheritance, which has the implicit conversion, it... | |||
1 day ago General » Re: Something like ADL from C++? | |||
|---|---|---|---|
| |||
...interface ISerialize {
void serialize();
}
class SerializableRoot {
void serialize() {
// serialize here
}
}
class MyType : SerializableRoot {
@thing int... | |||
1 day ago DIP Ideas » Re: Struct inheritance | |||
|---|---|---|---|
| |||
...a child class can implicitly convert to a reference of its parent class. It's... | |||
Copyright © 1999-2021 by the D Language Foundation