On Mon, 06 Apr 2015 19:16:33 +0000, Jonathan wrote:

> What's the best way to do this? I'm assuming this should be best
> practice:
> http://dlang.org/traits.html#isSame
> 
> struct S { }
> writeln(__traits(isSame, S, S));


struct S {}

auto s0 = S();
auto s1 = S();

static if (is(typeof(s0) == typeof(s1))) {
  pragma(msg, "Woe to the Republic.");
}

Attachment: signature.asc
Description: PGP signature

Reply via email to