Tom:
> What should I do? Is there some way to get the original array type?
This code shows two ways to solve your problem:
import std.stdio: writeln;
import std.algorithm: map;
import std.conv: to;
import std.traits: ForeachType;
import std.array: array;
void foo(Range)(Range srange) if (is(Fo
On 2010-11-15 16:52, Steven Schveighoffer wrote:
On Sun, 14 Nov 2010 05:28:29 -0500, Per Ångström wrote:
Fortunately, by separating interface and implementation, one can at
least keep the implementation modules free from interdependencies.
It's not perfect but it's not a complete mess either.
On 11/27/2010 02:05 PM, bearophile wrote:
>> Reduced case for bugzilla:
>>
> http://d.puremagic.com/issues/show_bug.cgi?id=5281
>
I investigated into the bug and the reason is the signature of opEquals,
which currently is
bool opEquals(Tdummy=void)(ref const BigInt y) const
bool opEquals(T
On Sun, 28 Nov 2010 06:19:00 -0500
bearophile wrote:
> Tom:
>
> > What should I do? Is there some way to get the original array type?
> [...]
> void foo(Range)(Range srange) if (is(ForeachType!Range == string)) {
> writeln(srange);
> }
> [...]
> If you want to simplify your code a little yo
Matthias Walter Wrote:
> bool opEquals(Tdummy=void)(ref const BigInt y) const
> bool opEquals(T: int)(T y) const
>
> The only working sigature for array-of-structs-comparison to work is
>
> bool opEquals(ref const BigInt y) const
>
> But this removes the ability to compare against ints.
Why ar
El 28/11/2010 04:11, Jonathan M Davis escribió:
On Saturday 27 November 2010 22:48:28 Tom wrote:
Hi,
I wonder how to solve this kind of stuff...
void foo(string[] sarray) {
// do something with sarray
}
void bar(int[] iarray) {
auto sarray = map!(to!string)(iarray);
foo(sarr
El 28/11/2010 08:19, bearophile escribió:
Tom:
What should I do? Is there some way to get the original array type?
This code shows two ways to solve your problem:
import std.stdio: writeln;
import std.algorithm: map;
import std.conv: to;
import std.traits: ForeachType;
import std.array: arr
Nrgyzer Wrote:
> decode(to!(string)(content));
check out, what you send to decode function.
the code... /3_=
Kagamin wrote:
Matthias Walter Wrote:
bool opEquals(Tdummy=void)(ref const BigInt y) const
bool opEquals(T: int)(T y) const
The only working sigature for array-of-structs-comparison to work is
bool opEquals(ref const BigInt y) const
But this removes the ability to compare against ints.
Why
Tom:
> Also I wish to point out that the layout and presentation of some of
> phobos ddoc pages are, IMHO and as I said before, a little bit of a
> mess. Wish they could look more like javadoc, or at least more organized.
D docs will surely need improvements, but I don't think they will look li
On Sunday 28 November 2010 11:37:26 Tom wrote:
> El 28/11/2010 04:11, Jonathan M Davis escribió:
> > On Saturday 27 November 2010 22:48:28 Tom wrote:
> >> Hi,
> >>
> >> I wonder how to solve this kind of stuff...
> >>
> >> void foo(string[] sarray) {
> >>
> >> // do something with sarray
>
El 28/11/2010 20:37, Jonathan M Davis escribió:
On Sunday 28 November 2010 11:37:26 Tom wrote:
El 28/11/2010 04:11, Jonathan M Davis escribió:
On Saturday 27 November 2010 22:48:28 Tom wrote:
Hi,
I wonder how to solve this kind of stuff...
void foo(string[] sarray) {
// do something
On Sunday 28 November 2010 19:53:36 Tom wrote:
> I'm not criticizing ddoc color or fonts. I mean, for example, in the
> index of symbols at the beginning of every ddoc page, there are
> functions, constants, classes, and templates, all mixed and each next to
> the other. It doesn't even have an alp
El 29/11/2010 01:58, Jonathan M Davis escribió:
On Sunday 28 November 2010 19:53:36 Tom wrote:
I'm not criticizing ddoc color or fonts. I mean, for example, in the
index of symbols at the beginning of every ddoc page, there are
functions, constants, classes, and templates, all mixed and each nex
On Sunday 28 November 2010 21:49:19 Tom wrote:
> El 29/11/2010 01:58, Jonathan M Davis escribió:
> > On Sunday 28 November 2010 19:53:36 Tom wrote:
> >> I'm not criticizing ddoc color or fonts. I mean, for example, in the
> >> index of symbols at the beginning of every ddoc page, there are
> >> fun
15 matches
Mail list logo