Bitfield-style enum to strings?
Nick Sabalausky via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Thu May 7 21:11:36 PDT 2015
On 05/07/2015 09:17 PM, Meta wrote:
> On Thursday, 7 May 2015 at 21:41:06 UTC, Nick Sabalausky wrote:
>> On 05/07/2015 05:19 PM, Justin Whear wrote:
>>>
>>> T[] members = [ EnumMembers!T ];
>>>
>>
>> Doh! Yup, that works.
>>
>> Still, I would think there should be a way to do it without allocating
>> an array. But it's not a huge deal right now though.
>
> You could also do `TypeTuple!(EnumMembers!T))` I believe.
filter doesn't seem to like that.
More information about the Digitalmars-d-learn
mailing list