Bug 20828 – __traits(getFunctionAttributes) doesn't support "scope"

Status
NEW
Severity
regression
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2020-05-13T13:57:34Z
Last change time
2024-12-13T19:08:39Z
Keywords
pull
Assigned to
No Owner
Creator
Atila Neves
Moved to GitHub: dmd#19705 →

Comments

Comment #0 by atila.neves — 2020-05-13T13:57:34Z
The code below prints tuple("@safe") when it should print tuple("@safe", "scope"): ---------------------------- struct Struct { void fun() @safe scope; } pragma(msg, __traits(getFunctionAttributes, Struct.fun)); ----------------------------
Comment #1 by atila.neves — 2020-05-13T14:14:11Z
Similar to https://issues.dlang.org/show_bug.cgi?id=14874 but trying its fix didn't work.
Comment #2 by moonlightsentinel — 2020-05-13T14:16:50Z
Thats a regression from 2.074 2.073.2: Success with output: tuple("scope", "@safe") Since 2.074.1: Success with output: tuple("@safe")
Comment #3 by moonlightsentinel — 2020-05-13T14:48:26Z
Comment #4 by dlang-bot — 2021-12-03T11:54:24Z
@RazvanN7 created dlang/dmd pull request #13379 "Fix Issue 20828 - __traits(getFunctionAttributes) doesn't support scope" fixing this issue: - Fix Issue 20828 - __traits(getFunctionAttributes) doesn't support scope https://github.com/dlang/dmd/pull/13379
Comment #5 by robert.schadek — 2024-12-13T19:08:39Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/19705 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB