Bug 1812 – DDOC - Unicode identifiers are not correctly marked.

Status
RESOLVED
Resolution
FIXED
Severity
major
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Windows
Creation time
2008-01-30T15:24:00Z
Last change time
2014-02-24T15:31:46Z
Keywords
ddoc, patch
Assigned to
bugzilla
Creator
burton-radons

Attachments

IDFilenameSummaryContent-TypeSize
222test.dUTF-8 source code showing the problem.text/plain;charset=utf-874
223test.htmlDocumentation produced by "dmd -D test.d".text/html;charset=utf-8485
3041812_unicode-idents.diffUse Unicode parsing for identifiers.text/plain910

Comments

Comment #0 by burton-radons — 2008-01-30T15:24:05Z
If a D identifier contains Unicode (such as führer), it will not be correctly marked by DDOC, presumably because DDOC's way of finding identifiers was not upgraded when D started allowing Unicode identifiers. Since there is no reasonable workaround, I've given it major severity. The two attachments are the source (in UTF-8) and the documentation produced from "dmd -D test.d".
Comment #1 by burton-radons — 2008-01-30T15:28:20Z
Created attachment 222 UTF-8 source code showing the problem.
Comment #2 by burton-radons — 2008-01-30T15:28:56Z
Created attachment 223 Documentation produced by "dmd -D test.d".
Comment #3 by matti.niemenmaa+dbugzilla — 2008-01-31T01:12:57Z
Looking at the attachments, it seems to work. What's the expected output? BTW, DDoc is (a lot) newer than D's support for Unicode identifiers.
Comment #4 by burton-radons — 2008-01-31T01:27:13Z
What you should see is that the first fuhrer is underlined, but the second is not, because it's not converted into a DDOC_DECL. And hm, you're right - DDoc was 0.132, while Unicode identifiers was 0.74. I guess I just noticed them in the opposite order.
Comment #5 by matti.niemenmaa+dbugzilla — 2008-01-31T15:48:13Z
I see, I didn't notice the missing underlining at all. Right you are, a bug it is.
Comment #6 by bugs-d — 2009-03-29T23:45:14Z
Created attachment 304 Use Unicode parsing for identifiers. This patch makes DDoc use Unicode to parse identifiers, which makes it properly match them in the doc comments and etc. -[Unknown]
Comment #7 by acehreli — 2009-09-17T12:03:31Z
Wanted to add that function parameters with unicode characters don't appear in the generated documentation as well. /** * BUG: The parameters are not listed under Params in the generated output * * Params: * ü = first * ş = second * ğ = third * */ int foo(int ü, int ş, int ğ) { return ğ; }
Comment #8 by bugzilla — 2009-11-06T11:29:43Z
Fixed dmd 1.051 and 2.036