Bug 21088 – std.meta.staticMap no longer works for typeid
Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
x86
OS
All
Creation time
2020-07-29T10:58:14Z
Last change time
2020-07-30T03:51:31Z
Keywords
pull
Assigned to
No Owner
Creator
FeepingCreature
Comments
Comment #0 by default_357-line — 2020-07-29T10:58:14Z
```
import std.meta;
enum getTypeId(T) = typeid(T);
void main() { alias a = staticMap!(getTypeId, int); }
```
-> std/meta.d-mixin-810(810): Error: expression typeid(int) is not a valid template value argument
I know why. PR incoming.
Comment #1 by dlang-bot — 2020-07-29T11:23:18Z
@FeepingCreature created dlang/phobos pull request #7571 "Fix issue 21088: move alias statement into staticMap mixin body." fixing this issue:
- Fix issue 21088: move alias statement into staticMap mixin body.
https://github.com/dlang/phobos/pull/7571
Comment #2 by dlang-bot — 2020-07-30T03:51:31Z
dlang/phobos pull request #7571 "Fix issue 21088: move alias statement into staticMap mixin body." was merged into master:
- a8107862c14f1d9bc18edb817192e3543f188da4 by Mathis Beer:
Fix issue 21088: move alias statement into staticMap mixin body.
https://github.com/dlang/phobos/pull/7571