aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Demangle/RustDemangle.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Demangle/RustDemangle.cpp')
-rw-r--r--llvm/lib/Demangle/RustDemangle.cpp15
1 files changed, 12 insertions, 3 deletions
diff --git a/llvm/lib/Demangle/RustDemangle.cpp b/llvm/lib/Demangle/RustDemangle.cpp
index 04bc175..cbb52fa 100644
--- a/llvm/lib/Demangle/RustDemangle.cpp
+++ b/llvm/lib/Demangle/RustDemangle.cpp
@@ -545,9 +545,18 @@ void Demangler::demangleDynBounds() {
SwapAndRestore<size_t> SaveBoundLifetimes(BoundLifetimes, BoundLifetimes);
print("dyn ");
demangleOptionalBinder();
- // FIXME demangle {dyn-trait}
- if (!consumeIf('E'))
- Error = true;
+ for (size_t I = 0; !Error && !consumeIf('E'); ++I) {
+ if (I > 0)
+ print(" + ");
+ demangleDynTrait();
+ }
+}
+
+// <dyn-trait> = <path> {<dyn-trait-assoc-binding>}
+// <dyn-trait-assoc-binding> = "p" <undisambiguated-identifier> <type>
+void Demangler::demangleDynTrait() {
+ demanglePath(InType::Yes);
+ // FIXME demangle {<dyn-trait-assoc-binding>}
}
// Demangles optional binder and updates the number of bound lifetimes.