On Saturday, 10 March 2018 at 08:49:19 UTC, Nordlöw wrote:
How do I most conveniently merge these into one single
`allSame` that can operate on mixtures of values and types?
I found the privately defined `isSame` in std.meta that does this.
On Friday, 9 March 2018 at 22:13:39 UTC, Simen Kjærås wrote:
static if (allEqual!(staticMap!(ElementEncodingType, Rs)))
{
// compare Rs byCodeUnit
}
NoDuplicates!V.length == 1
BTW, `NoDuplicates` can handle both types and values (mixed)
opposite to my `allSame` and `allSameType` defined
On Friday, 9 March 2018 at 19:24:03 UTC, Nordlöw wrote:
I'm looking for a function (that probably should be placed in
std.meta) named something like `areEqual` that checks whether
all it's arguments are equal or not.
Is there such as function already in Phobos?
My usage is
static if
On Friday, 9 March 2018 at 19:24:03 UTC, Nordlöw wrote:
I'm looking for a function (that probably should be placed in
std.meta) named something like `areEqual` that checks whether
all it's arguments are equal or not.
Is there such as function already in Phobos?
My usage is
static if
I'm looking for a function (that probably should be placed in
std.meta) named something like `areEqual` that checks whether all
it's arguments are equal or not.
Is there such as function already in Phobos?
My usage is
static if (allEqual!(staticMap!(ElementEncodingType, Rs)))
{
//