Hello.
I'm trying to learn more of D templates, but I'm stuck with an issue I
cannot resolve. Well, actually, I don't know if this is even allowed, and
that's why I'm posting here. Suppose I have a function declared like this:
---
import std.traits;
void foo(T...)(T args) if( isSomeString!(
Justin Spahr-Summers Wrote:
>
> Hmm, that is pretty weird. Are you doing any casts anywhere, or any
> pointer arithmetic/tricks?
A search for cast didn't show any related casts.
Do you maybe know another thing to check?
I do throw references around and there are a lot of implicit casts to extend
On Tue, 06 Apr 2010 22:41:43 -0400, strtr wrote:
>
> Justin Spahr-Summers Wrote:
> >
> > I think he said that he has two distinct object references, but the
> > value stored in the object(s) changes by changing either one.
> >
> > In other words, we'd need to see the code.
>
> I've added this
Justin Spahr-Summers Wrote:
>
> I think he said that he has two distinct object references, but the
> value stored in the object(s) changes by changing either one.
>
> In other words, we'd need to see the code.
I've added this exact sequence:
if( c1 !is null )
{
bearophile Wrote:
> Time ago I have told Walter that adding images with pointers and boxes to the
> D docs, that represent the main data structures used in D, can help a lot the
> understanding and usage of D.
>
> When you *see* the data structure in an image, understanding what happens and
>
On Tue, 06 Apr 2010 21:15:02 -0400, bearophile
wrote:
>
> Time ago I have told Walter that adding images with pointers and boxes to the
> D docs, that represent the main data structures used in D, can help a lot the
> understanding and usage of D.
>
> When you *see* the data structure in an i
I'm trying to write a series of structs to a stream, which then has to
be sent over the wire within a single TCP packet, in order for the host,
an embedded device, to recognize the message. If there is too little,
or too much data for a given "command" (packet), the device will throw
out the e
Time ago I have told Walter that adding images with pointers and boxes to the D
docs, that represent the main data structures used in D, can help a lot the
understanding and usage of D.
When you *see* the data structure in an image, understanding what happens and
how to write program gets easy.
bearophile Wrote:
> strtr:
> > Is it possible to have different vpointers/monitors pointing to the same
> > object?
>
> I think this questions is meaningless. Those pointers don't point to objects.
>
> And the "is" operator compared class references, not vpointers/monitors.
>
> Bye,
> bearophi
Hello Justin Spahr-Summers,
On Mon, 5 Apr 2010 15:47:10 + (UTC), BCS wrote:
I dind't know it worked?
It seemed to when I tested the snippet that I sent, but it might've
just been luck of the draw, and in reality fail silently on certain
edge cases. I'm really not sure.
While it's ni
bearophile wrote:
> Nick Sabalausky:
>
>>> If you don't want that doplication you can also write:
>>> enum auto f = Foo();
>> Can't you do:
>> enum f = Foo();
>> ?
>
> In my opinion that's a semantic mess, I don't write that. auto is for
> automatic local type inference and enum is to ask for
11 matches
Mail list logo