On Saturday, October 19, 2013 15:00:54 simendsjo wrote:
> o DCollections: Not updated in 4 years - dead?
It's not dead, and it's been updated more recently than 4 years ago (though it
was still 2 years ago). The latest should be here
https://github.com/schveiguy/dcollections
Steven hasn't time
Anyway to evaluate the name of the class and return its hash at
compile time?
I couldn't find the built in hash unction for strings so i used
the one from http://dlang.org/hash-map.html as an example. More
advanced and better hash functions can be found online.
public class ComponentDetail(T
public class ComponentDetail(T) : Component {
/// Component's ID as static member.
public static hash_t ID = typeid(T).toHash;
typeid(T).toHash can not be evaluated by the compiler at
compile-time.
Placing the ID
On Sunday, 20 October 2013 at 01:56:39 UTC, TheFlyingFiddle wrote:
public class ComponentDetail(T) : Component {
/// Component's ID as static member.
public static hash_t ID = typeid(T).toHash;
typeid(T).toHash can no
On Sunday, 20 October 2013 at 01:41:58 UTC, Agustin wrote:
I'm getting Assertion failure: 'thisval && thisval->op ==
TOKclassreference' on line 4067 in file 'interpret.c' when
compiling this.
public class Component {
/// Comp
I'm getting Assertion failure: 'thisval && thisval->op ==
TOKclassreference' on line 4067 in file 'interpret.c' when
compiling this.
public class Component {
/// Component's unique id.
private hash_t id;
/
res += components[i];
Should be res += components[i] * components[i];
On Saturday, 19 October 2013 at 15:22:31 UTC, Agustin wrote:
I'm trying to implement a template Vector and i would like to
know if this is possible.
My current vector class is:
public class Vector(T, size_t size) {
private T components[size];
}
And i would like to implement a property as
Is it possible to inject code into a method with UDA's?
For example if i wanted a method to do some logging when it's
called.
Something like the following.
void logMsg(string file, string msg)
{
//Log the message to the file.
}
struct Log
{
string logFile;
}
class Foo
{
void bar() { /*
Sry accedentaly clicked send while writing..
void logMsg(string file, string msg)
{
//Log the message to the file.
}
struct Log
{
string logFile;
LogInfo toLog;
}
class Foo
{
void bar() { /* do something */ }
@Log("fooInfo.txt", LogInfo.methodCall | LogInfo.returnValue)
void baz()
{
//Doess
}
}
On 2013-10-19 15:00, simendsjo wrote:
Last I heard, collection design was delayed while waiting for the
allocator design. But I guess there are plenty of collection
implementations already. So where are they?
o Phobos: std.container - RedBlackTree, BinaryHeap, Array, SList, DList
o DCollections:
I'm trying to implement a template Vector and i would like to
know if this is possible.
My current vector class is:
public class Vector(T, size_t size) {
private T components[size];
}
And i would like to implement a property as this:
@property
public size_t length() const {
return Tra
Hi,
Are there any recent improvements in how D interfaces with C++? I
got the impression that some work has been done on that, in order
to make DMD a self-hosting compiler.
Last I heard, collection design was delayed while waiting for the
allocator design. But I guess there are plenty of collection
implementations already. So where are they?
o Phobos: std.container - RedBlackTree, BinaryHeap, Array, SList,
DList
o DCollections: Not updated in 4 years - dead?
o
On Friday, 18 October 2013 at 16:52:01 UTC, Benjamin Thaut wrote:
Am 18.10.2013 18:40, schrieb Erik van Velzen:
Hello,
I have set up my enviroment according to these instructions:
http://wiki.dlang.org/Installing_DMD_on_64-bit_Windows_7_%28COFF-compatible%29
When I compile a small tutorial pro
On Sunday, 28 April 2013 at 12:46:31 UTC, Josh wrote:
I followed the instructions in
http://wiki.dlang.org/Installing_DMD_on_64-bit_Windows_7_(COFF-compatible)
and all seems ok. Except I get these errors when I'm compiling:
Is there anything that those instructions left out that I need
to do
17 matches
Mail list logo