Moving the Swift demangler from libSIL to libBasic

Plus, a couple of minor cosmetic changes that I had held off for a couple days now



Swift SVN r6691
This commit is contained in:
Enrico Granata
2013-07-29 17:42:57 +00:00
parent b9476cf6e4
commit c75fe924a1
6 changed files with 27 additions and 27 deletions

View File

@@ -0,0 +1,53 @@
//===--- Demangle.h - Interface to Swift symbol demangling -----------------===//
//
// This source file is part of the Swift.org open source project
//
// Copyright (c) 2014 - 2015 Apple Inc. and the Swift project authors
// Licensed under Apache License v2.0 with Runtime Library Exception
//
// See http://swift.org/LICENSE.txt for license information
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//
//===----------------------------------------------------------------------===//
#ifndef SWIFT_BASIC_DEMANGLE_H
#define SWIFT_BASIC_DEMANGLE_H
#include "llvm/ADT/StringRef.h"
#include <string>
namespace swift {
namespace Demangle {
/// \brief Demangle the given string as a Swift symbol.
///
/// Typical usage:
/// \code
/// std::string aDemangledName =
/// swift::Demangler::demangleSymbol("SomeSwiftMangledName")
/// \endcode
///
/// \param mangled The mangled string.
///
///
/// \returns The demangled string - or the mangled string on failure.
///
std::string demangleSymbol(llvm::StringRef mangled);
/// \brief Demangle the given string as a Swift type.
///
/// Typical usage:
/// \code
/// std::string aDemangledName =
/// swift::Demangler::demangleType("SomeSwiftMangledName")
/// \endcode
///
/// \param mangled The mangled string.
///
///
/// \returns The demangled string - or the mangled string on failure.
std::string demangleType(llvm::StringRef mangled);
} // end namespace Demangle
} // end namespace swift
#endif