mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
IDE: Remove getTypeFromMangledSymbolname()
There was only one remaining usage other than in testing tools. Note that when a declaration mangling was passed in, the old entry point would (try to) return the type of the declaration. The new entry point no longer has this behavior. I changed the bridging-header-first test to run lldb-moduleimport-test with -decl-from-mangled instead of -type-from-mangled-old to preserve the behavior of the test. Also, I removed test/DebugInfo/DumpTypeFromMangledName.swift completely. This test only covered a handful of cases, and a bunch of them were declaration manglings rather than type manglings. The new tests in test/TypeDecoder/ are much more comprehensive.
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
#include "swift/IDE/Utils.h"
|
||||
#include "swift/Sema/IDETypeChecking.h"
|
||||
#include "swift/AST/ASTContext.h"
|
||||
#include "swift/AST/ASTDemangler.h"
|
||||
#include "swift/AST/ASTPrinter.h"
|
||||
#include "swift/AST/Decl.h"
|
||||
#include "swift/AST/Module.h"
|
||||
@@ -182,8 +183,8 @@ printTypeInterface(ModuleDecl *M, Type Ty, ASTPrinter &Printer,
|
||||
bool swift::ide::
|
||||
printTypeInterface(ModuleDecl *M, StringRef TypeUSR, ASTPrinter &Printer,
|
||||
std::string &TypeName, std::string &Error) {
|
||||
return printTypeInterface(M, getTypeFromMangledSymbolname(M->getASTContext(),
|
||||
TypeUSR, Error),
|
||||
return printTypeInterface(M, Demangle::getTypeForMangling(M->getASTContext(),
|
||||
TypeUSR),
|
||||
Printer, TypeName, Error);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user