[Issue 20054] New: getSymbolsByUDA no longer works on modules

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Jul 15 12:59:56 UTC 2019


          Issue ID: 20054
           Summary: getSymbolsByUDA no longer works on modules
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Windows
            Status: NEW
          Severity: regression
          Priority: P1
         Component: phobos
          Assignee: nobody at puremagic.com
          Reporter: zorael at gmail.com

I use this heavily to iterate module-level functions[1].

import std.traits;

struct UDA;

void foo() {}

void main()
    alias funs = getSymbolsByUDA!(mixin(__MODULE__), UDA);

> C:\cygwin\home\zorael\work\result\bin\..\import\std\traits.d(8356): Error: template instance `isAggregateType!(uda)` does not match template declaration `isAggregateType(T)`
> uda.d(10):        while looking for match for `getSymbolsByUDA!(uda, UDA)`

Offending commit:

commit f07517ac648a933d998bc6a53af7dc55c9d48daf
Author: The Dlang Bot <code+dlang-bot at dawg.eu>
Date:   Wed Jul 10 11:57:39 2019 +0200

    phobos: Merge pull request #7100 from RazvanN7/fix_issue_19105


    Fix Issue 19105 - Bogus recursive template expansion via getSymbolsByUDA
    merged-on-behalf-of: Nicholas Wilson
<thewilsonator at users.noreply.github.com>



More information about the Digitalmars-d-bugs mailing list