mangle
Jacob Carlborg
doob at me.com
Sat Jul 3 11:34:09 PDT 2010
On 2010-07-02 18.17, Ellery Newcomer wrote:
> On 07/01/2010 08:16 PM, Adam Ruppe wrote:
>> http://dpldocs.info/std.demangle
>
> import std.demangle;
> import std.stdio;
> void main(){
>
> writeln(demangle("_D3std6random156__T11RandomCoverTAiTS3std6random98__T21MersenneTwisterEngineTkVi32Vi624Vi397Vi31Vk2567483615Vi11Vi7Vk2636928640Vi15Vk4022730752Vi18Z21MersenneTwisterEngineZ11RandomCover4saveMFNdZS3std6random156__T11RandomCoverTAiTS3std6random98__T21MersenneTwisterEngineTkVi32Vi624Vi397Vi31Vk2567483615Vi11Vi7Vk2636928640Vi15Vk4022730752Vi18Z21MersenneTwisterEngineZ11RandomCover"));
>
> }
>
> gives
>
> _D3std6random156__T11RandomCoverTAiTS3std6random98__T21MersenneTwisterEngineTkVi32Vi624Vi397Vi31Vk2567483615Vi11Vi7Vk2636928640Vi15Vk4022730752Vi18Z21MersenneTwisterEngineZ11RandomCover4saveMFNdZS3std6random156__T11RandomCoverTAiTS3std6random98__T21MersenneTwisterEngineTkVi32Vi624Vi397Vi31Vk2567483615Vi11Vi7Vk2636928640Vi15Vk4022730752Vi18Z21MersenneTwisterEngineZ11RandomCover
>
std.demangle is incomplete, missing newer D2 features like return by
reference, and incorrectly handles floating point numbers in tempaltes.
If it encounters something it can't demangle it will just return the
original mangled name.
> There wouldn't happen to be any other demanglers about, would there?
You could try the one in tango but I wouldn't think you have any more
luck with that one.
--
Jacob Carlborg
More information about the Digitalmars-d
mailing list