May 08, 2015 Re: Bitfield-style enum to strings? | ||||
---|---|---|---|---|
| ||||
Posted in reply to Nick Sabalausky | On Friday, 8 May 2015 at 04:11:36 UTC, Nick Sabalausky wrote:
> 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.
Yeah, sorry, forgot it was supposed to go through a range as well.
|
Copyright © 1999-2021 by the D Language Foundation