[Issue 4697] New: std.demangle doesn't work correctly

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Aug 20 16:10:05 PDT 2010


http://d.puremagic.com/issues/show_bug.cgi?id=4697

           Summary: std.demangle doesn't work correctly
           Product: D
           Version: D2
          Platform: Other
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Phobos
        AssignedTo: nobody at puremagic.com
        ReportedBy: necroment at gmail.com


--- Comment #0 from Max Klyga <necroment at gmail.com> 2010-08-20 16:10:03 PDT ---
import std.demangle, std.stdio;

void main() {
    auto a = (float x, char y) { return 0; };
    auto b = [ 1, 2, 3 ];
    auto c = 3.5;

    writeln(demangle(a.mangleof));
    writeln(demangle(b.mangleof));
    writeln(demangle(c.mangleof));
    writeln(demangle("_D3std4math3cosFNaNbeZe"));
    writeln(demangle("_D3std3utf6toUTF8FG4awZAa"));
    writeln(demangle("_D3std6string7sformatFAaYAa"));
}

output:

DFfaZi
Ai
d
_D3std4math3cosFNaNbeZe
char[] std.utf.toUTF8(char[4], dchar)
char[] std.string.sformat(char[], ...)

So it does unmangle some of the symbols, but it's very limited currently.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list