aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Demangle/RustDemangle.cpp
diff options
context:
space:
mode:
authorTomasz Miąsko <tomasz.miasko@gmail.com>2021-06-07 19:11:16 +0200
committerTomasz Miąsko <tomasz.miasko@gmail.com>2021-06-07 19:16:11 +0200
commit43929ccc1296b13250965d75bd410550256d45c5 (patch)
tree1da5129a1741f52465fb125cc18d38a966446e9c /llvm/lib/Demangle/RustDemangle.cpp
parentfd11a26d368c5a909fb88548fef2cee7a6c2c931 (diff)
downloadllvm-43929ccc1296b13250965d75bd410550256d45c5.zip
llvm-43929ccc1296b13250965d75bd410550256d45c5.tar.gz
llvm-43929ccc1296b13250965d75bd410550256d45c5.tar.bz2
[Demangle][Rust] Parse instantiating crate
Reviewed By: dblaikie Differential Revision: https://reviews.llvm.org/D103460
Diffstat (limited to 'llvm/lib/Demangle/RustDemangle.cpp')
-rw-r--r--llvm/lib/Demangle/RustDemangle.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/llvm/lib/Demangle/RustDemangle.cpp b/llvm/lib/Demangle/RustDemangle.cpp
index 9513a00..582cdbc 100644
--- a/llvm/lib/Demangle/RustDemangle.cpp
+++ b/llvm/lib/Demangle/RustDemangle.cpp
@@ -113,7 +113,10 @@ bool Demangler::demangle(StringView Mangled) {
demanglePath(rust_demangle::InType::No);
- // FIXME parse optional <instantiating-crate>.
+ if (Position != Input.size()) {
+ SwapAndRestore<bool> SavePrint(Print, false);
+ demanglePath(InType::No);
+ }
if (Position != Input.size())
Error = true;