Bug 10869 – Ddoc mark methods with "const" twice

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2013-08-22T09:26:00Z
Last change time
2013-08-26T14:26:57Z
Keywords
ddoc, pull
Assigned to
andrej.mitrovich
Creator
doob

Comments

Comment #0 by doob — 2013-08-22T09:26:14Z
In std.xml all methods that are const are marked with "const" twice. http://dlang.org/phobos/std_xml.html
Comment #1 by andrej.mitrovich — 2013-08-22T09:39:11Z
Introduced by f5f71ce1f50f2c33240475c44376cf176b75217e by fixing Issue 3445. prefix is first called in declarationToDocBuffer, which adds one or more of these: deprecated static final abstract const immutable synchronized But then toCBufferWithAttributes for functions is called which adds one or more of these when it calls MODtoBuffer: immutable shared const inout So there's a bit of an overlap.
Comment #2 by andrej.mitrovich — 2013-08-22T10:05:17Z
Comment #3 by andrej.mitrovich — 2013-08-22T10:06:29Z
There's another problem, synchronized methods were usually handled in the prefix function, which output "synchronized", but then MODtoBuffer in toCBufferWithAttributes outputs "shared". So I'll file this as another bug once this pull is merged first.
Comment #4 by github-bugzilla — 2013-08-26T14:26:31Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/da91b6da998793a66f89d58343beb44e5f0889bf Fixes Issue 10869 - Ddoc outputted some function modifiers twice. https://github.com/D-Programming-Language/dmd/commit/08d621c232260b231b7a3a4f326f8d4441d22b80 Merge pull request #2494 from AndrejMitrovic/Fix10869 Issue 10869 - Ddoc outputted some function modifiers twice.