From a61fb6e542d8094583bbd2bf6dc34b28d0bd7ae0 Mon Sep 17 00:00:00 2001 From: "H. S. Teoh" Date: Thu, 27 Nov 2014 10:20:20 -0800 Subject: [PATCH] Use Flag instead of single-use enum. --- std/algorithm.d | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/std/algorithm.d b/std/algorithm.d index d52dae1c1..7667cbf21 100644 --- a/std/algorithm.d +++ b/std/algorithm.d @@ -4552,11 +4552,8 @@ Group!(pred, Range) group(alias pred = "a == b", Range)(Range r) /** * Specifies whether a predicate is an equivalence relation. */ -enum IsEquivRelation : bool -{ - no, /// Predicate is not an equivalence relation - yes, /// Predicate is an equivalence relation -} +import std.typecons : Flag; +alias IsEquivRelation = Flag!"isEquivRelation"; // Used by implementation of groupBy. private struct GroupByChunkImpl(alias pred, IsEquivRelation isEquivRelation, Range)