mstange / msvc-demangler-rust

A rust library that demangles / undecorates C++ symbols mangled by MSVC
Other
42 stars 13 forks source link

Error API Cleanup #45

Closed mitsuhiko closed 5 years ago

mitsuhiko commented 5 years ago

This removes all obvious remaining panics (still need to check if there are other operations that can panic such as slicing) and reforms the error interface as outlined in #44

It now forces all operations that fail through a central interface which makes it easier to debug. I wanted to also add a backtrace to the errors but that's overkill since they are only needed for internal debugging. I found that adding panics temporarily to the fail method is a good way to debug this thing.

mitsuhiko commented 5 years ago

Going to merge it as I do most development off this branch since it makes debugging easier.