For resolving any kind of symbol to string via CTFE, I'd suggest we defer running semantic analysis until the second pass. See for instance: https://github.com/D-Programming-Language/dmd/pull/5302/files#diff-0d13b271f20a2f0982c3c74062c314fdR440