https://issues.dlang.org/show_bug.cgi?id=12570
Vladimir Panteleev thecybersha...@gmail.com changed:
What|Removed |Added
Status|NEW |RESOLVED
https://issues.dlang.org/show_bug.cgi?id=12570
Issue ID: 12570
Summary: cast to template interface
Product: D
Version: D2
Hardware: x86_64
OS: Windows
Status: NEW
Severity: normal
Priority: P1
On Tuesday, 1 April 2014 at 19:55:05 UTC, Steven Schveighoffer
wrote:
On Tue, 01 Apr 2014 15:47:42 -0400, anonymous
n...@trash-mail.com wrote:
Is this bug allready reported? or can somebody who has a
deeper insight to this report it?
I don't know. I think you should report it. If it's
Is this bug allready reported? or can somebody who has a deeper
insight to this report it?
On Tuesday, 1 April 2014 at 05:51:46 UTC, anonymous wrote:
Ok, thought i did something wrong or got some wrong idea how it
should work.
On Tue, 01 Apr 2014 15:47:42 -0400, anonymous n...@trash-mail.com wrote:
Is this bug allready reported? or can somebody who has a deeper insight
to this report it?
I don't know. I think you should report it. If it's already reported,
someone will close it as a duplicate
-Steve
Hi,
I'm new to D and played a bit with templates and delegates.
Now i discovered some behaviore that i don't understand.
Can somebody explain me why i get two different outputs?
import std.stdio;
interface A(T){
bool GetBool();
T getT();
}
class C:A!(double){
override
On Mon, 31 Mar 2014 18:58:30 +, anonymous wrote:
Hi,
I'm new to D and played a bit with templates and delegates.
Now i discovered some behaviore that i don't understand. Can somebody
explain me why i get two different outputs?
import std.stdio;
interface A(T){
bool
On Mon, 31 Mar 2014 14:58:30 -0400, anonymous n...@trash-mail.com wrote:
Hi,
I'm new to D and played a bit with templates and delegates.
Now i discovered some behaviore that i don't understand.
Can somebody explain me why i get two different outputs?
import std.stdio;
interface A(T){
Ok, thought i did something wrong or got some wrong idea how it
should work.
cost, unlike using templates).
I'm suggesting something like a template interface, which is
compatible with all types, and serves as a placeholder for any type for
which the body compiles:
[snip]
void fun(List!string l);
Maybe:
void fun(L:IList)(L l);
template interface IList(E) {
template
with the current interface.
A possible enhancement is to allow structs to implement
interfaces (but this has a runtime cost, unlike using
templates).
I'm suggesting something like a template interface, which is
compatible with all types, and serves as a placeholder for any
type for
which
with the current
interface.
I'm suggesting something like a template interface, which is
compatible with all types, and serves as a placeholder for any
type for which the body compiles:
What you're looking for were also proposed for C++; they were
called concepts
void fun(List l);
template
On 2012-06-13 15:34, Nick Treleaven wrote:
Maybe it would be better for the template interface body to contain
method signatures/members rather than code?
I would prefer that.
I think it might be an interesting idea, but it would probably need to
be significantly better than the current way
interface, which is
compatible with all types, and serves as a placeholder for any
type for which the body compiles:
void fun(List l);
template interface List {
List l;
if (l.nil) {}
auto e = l.car;
l = l.cdr;
}
It might be have parameters:
void fun(List!string l);
template
/bb9200a4f80c912a4b9e4c4649307d86edb0624c
Issue 4174 - Template interface functions not allowed, making operator
overloads difficult
The lifting restriction banning final and static members in interfaces should
also apply to template functions.
https://github.com/D-Programming-Language/dmd/commit
http://d.puremagic.com/issues/show_bug.cgi?id=4174
Walter Bright bugzi...@digitalmars.com changed:
What|Removed |Added
Status|ASSIGNED|RESOLVED
http://d.puremagic.com/issues/show_bug.cgi?id=4174
yebblies yebbl...@gmail.com changed:
What|Removed |Added
CC||d...@dawgfoto.de
---
http://d.puremagic.com/issues/show_bug.cgi?id=4174
Alex R�nne Petersen xtzgzo...@gmail.com changed:
What|Removed |Added
CC|
http://d.puremagic.com/issues/show_bug.cgi?id=4174
yebblies yebbl...@gmail.com changed:
What|Removed |Added
Keywords||patch, rejects-valid
http://d.puremagic.com/issues/show_bug.cgi?id=4174
Andrei Alexandrescu and...@metalanguage.com changed:
What|Removed |Added
Status|NEW |ASSIGNED
http://d.puremagic.com/issues/show_bug.cgi?id=4174
--- Comment #3 from Steven Schveighoffer schvei...@yahoo.com 2010-12-29
12:40:08 PST ---
Yes, I think back in May, you needed +=.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this
http://d.puremagic.com/issues/show_bug.cgi?id=4174
Summary: Template interface functions not allowed
Product: D
Version: 2.041
Platform: Other
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
http://d.puremagic.com/issues/show_bug.cgi?id=4174
Steven Schveighoffer schvei...@yahoo.com changed:
What|Removed |Added
Severity|normal |blocker
--
23 matches
Mail list logo