Giter VIP home page Giter VIP logo

cwldemangle's People

Contributors

maddthesane avatar mattgallagher avatar maxdesiatov avatar nerdsupremacist avatar tonyarnold avatar vlas-voloshin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

cwldemangle's Issues

New mangle format?

Just a heads-up: There's been a fair amount of activity on Demangle.cpp since December, and talk of "new mangling". Maybe preparation for Swift 4?

Sigh. I was just about to integrate your great Swift-based demangle code into my Swift logging module, now I fear that could soon be a wasted investment.

(But I still think it's marvelous that you did this work.)

CWLDemangle sometimes inserts U+0001 characters in print()

For example this symbol:

"_T0s14StringProtocolP10FoundationSS5IndexVADRtzrlE10componentsSaySSGqd__11separatedBy_tsAARd__lF"

demangles into this when you call SwiftSymbol.print() on it:

"(extension in Foundation):Swift.StringProtocol<>.components(separatedBy: A\u{1}) -> Swift.Array<Swift.String>"

If you just dump this string as part of a json serialization process, then it will be invalid json and cannot be parsed by other json deserializers.

In swift you would represent the U+0001 char as "\u{1}". You can see a list of unicode characters here: https://en.wikipedia.org/wiki/List_of_Unicode_characters

Crash on printing demangled name

Hello

We are using your demangle swift code in our project to print stack traces in a little bit more readable way.

Unfortunately this mangled name is crashing Demangle.swifton printing its name, after calling SwiftName.description with following string passed to demangleSwiftName to create SwiftName instance in the first place:

_TFFFFC9Le_Figaro11DataManagerP33_4BF0F705F2DC93973E68326EF6A0FFBA16getSingleArticleFTGSqSS_13articleSourceGSqSS_10articleUrlGSqSS_17completionHandlerGSqFT_T__12errorHandlerGSqFGSqPs5Error__T___T_U_FGSqP__T_U_FCSo22NSManagedObjectContextT_U_FT6resultGSqP__5errorGSqPS1____T_

as string parameter.

Swift 3.0, Xcode 8.0

anywhere java implement with swift demangle?

this is a greate job by translate it form c++ to swift!
I want demangle swift symbols in server, my server code is java [\sad],I do not good at java develop.do you know anywhere has java implement?

Mangling back?

Sorry for the very weird question ๐Ÿ˜…

Is there a way to go back to the mangled version?

If for instance if I have a function:

Mangled:

$s6Module3FooC3bar3bazSayAA3BarVGSi_tF

Demangled:

Module.Foo.bar(baz: Swift.Int) -> Swift.Array<Module.Bar>

And if I want a specific part mangled back. For example for Swift.Int:

$sSiN

I'm not looking for anyone to fix this for me. I'm happy to implement it myself ๐Ÿ™ƒ .
Would just like some idea of how to change the code to accommodate.

My idea so far was to keep track of the area in the mangled string for a specific node in the AST and just store that, in the SwiftSymbol Object. But we still need to resolve how to mangle the module name back: i.e. how do I go from Swift.Array<Module.Bar> to $s[...]6Module3Bar[...]?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.