Skip to content

Commit fd0e1cd

Browse files
committed
swift-ide-test: Use Demangle::getTypeDeclForMangling() to implement -find-mangled flag
1 parent 4e55714 commit fd0e1cd

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

tools/swift-ide-test/swift-ide-test.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1701,11 +1701,11 @@ static int doPrintAST(const CompilerInvocation &InitInvok,
17011701
}
17021702

17031703
// If we were given a mangled name, only print that declaration.
1704-
std::string error;
1705-
const Decl *D = ide::getDeclFromMangledSymbolName(CI.getASTContext(),
1706-
MangledNameToFind, error);
1704+
const TypeDecl *D = Demangle::getTypeDeclForMangling(CI.getASTContext(),
1705+
MangledNameToFind);
17071706
if (!D) {
1708-
llvm::errs() << "Unable to find decl for symbol: " << error << "\n";
1707+
llvm::errs() << "Unable to find decl for symbol: "
1708+
<< MangledNameToFind << "\n";
17091709
return EXIT_FAILURE;
17101710
}
17111711

0 commit comments

Comments
 (0)