On Thursday, 29 January 2015 at 08:47:18 UTC, Mike wrote:
It just seems to return a void*. But, searching the source
code, it doesn't seem to be set by anything anywhere.
It can actually return anything: RTInfo is a template that is
automatically instantiated for each user-defined struct or
On 1/29/15 3:47 AM, Mike wrote:
object.d [1] says it's infomation for the precise GC (which I thought
wasn't implemented yet).
It just seems to return a void*. But, searching the source code, it
doesn't seem to be set by anything anywhere.
So, what is RTInfo and what is its purpose. And how
object.d [1] says it's infomation for the precise GC (which I
thought wasn't implemented yet).
It just seems to return a void*. But, searching the source code,
it doesn't seem to be set by anything anywhere.
So, what is RTInfo and what is its purpose. And how is it
different from
I would suggest instead of using make, use dub[0] build manager
instead.
It'll handle grabbing all the files and compiling them
correctly.
[0] http://code.dlang.org/package-format
Or for simple projects such as this one seems to be, just use
rdmd.
Atila
@property auto info() @safe @nothrow @pure @return const { return this; }
It is mesmerizing... (@ _ @)
On Wednesday, 28 January 2015 at 12:29:09 UTC, Fyodor Ustinov
wrote:
On Wednesday, 28 January 2015 at 11:27:53 UTC, Kagamin wrote:
Associative array doesn't support thread-safe operations,
that's why they don't work on shared instance. You should use
std.concurrency or implement low-level
Basically what the title says, how do I check if a type T is an
instantiation of a specific template?
Tofu Ninja:
Basically what the title says, how do I check if a type T is an
instantiation of a specific template?
If you have an updated Phobos std.traits.isInstanceOf could be
what you look for.
Bye,
bearophile
On Thursday, 29 January 2015 at 12:10:41 UTC, bearophile wrote:
Tofu Ninja:
Basically what the title says, how do I check if a type T is
an instantiation of a specific template?
If you have an updated Phobos std.traits.isInstanceOf could be
what you look for.
Bye,
bearophile
Yep,
On Wednesday, 28 January 2015 at 11:50:46 UTC, Danny wrote:
Hello,
I'm trying to write some toy examples using threads in D.
Is the std.stdio.File thread-local or shared? Is flockfile used
when I synchronize on it?
I tried checking phobos myself and found some things I don't
get (in
On Thursday, 29 January 2015 at 17:48:04 UTC, rumbu wrote:
bool opEquals(Object obj, int value)
{
//do something to compare them
return false;
}
void main(string[] args)
{
Object obj;
if (obj == 12) {}
//ERROR function object.Object.opEquals (Object o) is not
callable
On Thu, Jan 29, 2015 at 12:58:46PM +, Tofu Ninja via Digitalmars-d-learn
wrote:
[...]
Incidentally, while trying to see how its used I found that a lot of
the links on the std.traits doc page do not work and have no
documentation.
[...]
Please file bugs for these. We need to fix the docs.
bool opEquals(Object obj, int value)
{
//do something to compare them
return false;
}
void main(string[] args)
{
Object obj;
if (obj == 12) {}
//ERROR function object.Object.opEquals (Object o) is not
callable using argument types (int)
}
According to paragraph (2) -
On Thursday, 29 January 2015 at 05:02:58 UTC, ketmar wrote:
http://wiki.dlang.org/DIP25
this is a very recent thing, it wasn't coded when 2.066 was
released.
Thanks, I like it.
On Thursday, 29 January 2015 at 11:50:29 UTC, FG wrote:
@property auto info() @safe @nothrow @pure @return const {
return this; }
It is mesmerizing... (@ _ @)
And soon its gong to look like this:
export @property auto info() @safe @nothrow @pure @return const {
return this; }
On Thursday, 29 January 2015 at 10:26:56 UTC, Atila Neves wrote:
I would suggest instead of using make, use dub[0] build
manager instead.
It'll handle grabbing all the files and compiling them
correctly.
[0] http://code.dlang.org/package-format
Or for simple projects such as this one seems
On 01/29/2015 09:48 AM, rumbu wrote:
bool opEquals(Object obj, int value)
{
//do something to compare them
return false;
}
void main(string[] args)
{
Object obj;
if (obj == 12) {}
//ERROR function object.Object.opEquals (Object o) is not callable
using argument types
On Tuesday, 27 January 2015 at 04:38:59 UTC, David Monagle wrote:
Hi guys,
I'm a former C++ developer and really enjoying working with D
now. I have a question that I hope some of you may be able to
answer.
class Parent {
@property string typeName() {
return typeof(this).stringof;
}
even more weird:
---
module test;
import std.conv;
interface Meh{
final string typeName()
{return to!string(this);}
}
class Parent : Meh {}
class Child : Parent {}
void main() {
auto p = new Parent;
auto c = new Child;
assert(p.typeName == __MODULE__ ~ .Parent);
This is almost the same code as written initially,
let somone explain why the hell this is working:
---
module test;
import std.conv;
class Parent {
@property final string typeName() {
return to!string(this);
}
}
class Child : Parent {
}
void main() {
auto p = new Parent;
auto c
Let me try to explain the compilation process which may help you
to understand where your problem lies.
* Build system
* Maintain program/library dependencies
* Execute commands resulting in a usable program/library
* Compiler
* Lexical Analysis
* Parsing
On Thursday, 29 January 2015 at 20:50:16 UTC, ref2401 wrote:
It's written here:
http://dlang.org/module.html#staticorder
Oops. Thnx!
On 01/29/2015 12:11 PM, Fyodor Ustinov wrote:
Hi!
Nowhere is it written that the start of a new thread also launch this()
for module (and stop a thread launch ~this()). It really is not written
anywhere or I just missed?
WBR,
Fyodor.
I imply it here:
It's written here:
http://dlang.org/module.html#staticorder
On 01/29/2015 12:33 PM, Christiaan wrote:
Can someone please explain what might be the issue here?
If the memory is too large, needing to be swapped to and from disk, then
your program may be waiting for I/O instead of doing actual work.
Ali
On Friday, 26 December 2014 at 08:43:24 UTC, Joel wrote:
On Wednesday, 24 December 2014 at 09:57:31 UTC, Kagamin wrote:
Works for me on allegro-5.0.10-mt.dll, produced 391kb lib file.
I think my Windows 7 on my Mac has system damage - I used a
doggy flash drive. I plan to install Window 8.1,
It's a bit hard to know where to start here. It's not obvious
from your code what you are trying to achieve.
In essence, you do have a circular reference as Base has
functions that use a types A and B which are derived from the
Base. I don't see how the complier could be asked to resolve
On Friday, 30 January 2015 at 06:35:31 UTC, Jeremy DeHaan wrote:
I have a template fuction that looks like this:
immutable(T)[] getString(T)() const
if (is(T == dchar)||is(T == wchar)||is(T == char))
Basically, I was hoping that the type would be deduced based on
the prameter that was being
I have a template fuction that looks like this:
immutable(T)[] getString(T)() const
if (is(T == dchar)||is(T == wchar)||is(T == char))
Basically, I was hoping that the type would be deduced based on
the prameter that was being assigned to like so.
string ret = thing.getString();
Apparently
On Friday, 30 January 2015 at 07:13:09 UTC, Jeremy DeHaan wrote:
That seems strange. I figured that it would be smart enough to
deduce the parameter type based on the type that it was trying
to
be assigned to.
It seems sensible to me, as changing string to auto would leave
the type of the
I ran into an issue with cross referencing to classes, that I
can't figure out. I reproduced the issue below:
import std.stdio;
class Base(t)
{
public void Foo(A!(t) a)
{
writeln(Base.Foo(A a));
}
public void Foo(B!(t) a)
{
On Friday, 30 January 2015 at 06:58:58 UTC, Vlad Levenfeld wrote:
On Friday, 30 January 2015 at 06:35:31 UTC, Jeremy DeHaan wrote:
A bunch of stuff
for template type deduction to work, you have to supply an
argument. Your type signature would need to look like this:
immutable(T)[]
On Friday, 30 January 2015 at 06:16:21 UTC, Joel wrote:
What happens is, that I run the script file (in DAllegro
folder) and it is suppose to create lib files from the DLL
ones. On my system, it says its done it but no lib files pop up!
You can try procmon to watch, what happens with files.
33 matches
Mail list logo