Bug 20190 – Deprecation not triggered on templates

Status
RESOLVED
Resolution
WORKSFORME
Severity
critical
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2019-09-04T02:54:43Z
Last change time
2023-04-18T10:44:23Z
Keywords
pull
Assigned to
No Owner
Creator
Mathias LANG

Comments

Comment #0 by pro.mathias.lang — 2019-09-04T02:54:43Z
``` deprecated template Const (T) { deprecated alias Const = const(T); } void foo(Const!(char)[]) {} ``` This should print a deprecation message. The double deprecated shouldn't be necessary either. Yet, as of 2.087.1, there's no output.
Comment #1 by dlang-bot — 2019-11-04T14:03:09Z
@RazvanN7 created dlang/dmd pull request #10534 "Fix Issue 20190 - Deprecation not triggered on templates" fixing this issue: - Fix Issue 20190 - Deprecation not triggered on templates https://github.com/dlang/dmd/pull/10534
Comment #2 by razvan.nitu1305 — 2023-04-18T10:44:23Z
I now get: test.d(5): Deprecation: template `test.Const(T)` is deprecated So this seems to have been fixed.