Name *Node = Arena.alloc<Name>();
Node->Str = "`anonymous namespace'";
- if (MangledName.consumeFront('@'))
- return Node;
-
- Error = true;
- return nullptr;
+ size_t EndPos = MangledName.find('@');
+ if (EndPos == StringView::npos) {
+ Error = true;
+ return nullptr;
+ }
+ MangledName = MangledName.substr(EndPos + 1);
+ return Node;
}
Name *Demangler::demangleLocallyScopedNamePiece(StringView &MangledName) {
??_V@YAXPEAXAEAVklass@@@Z
; CHECK: void __cdecl operator delete[](void *, class klass &)
+; ?A@?A0x43583946@@3VB@@B
+class B const `anonymous namespace'::A
\ No newline at end of file