Make helpers static.

llvm-svn: 128339
This commit is contained in:
Benjamin Kramer 2011-03-26 12:38:21 +00:00
parent 8d2227373d
commit 8aef596dec
4 changed files with 8 additions and 7 deletions

View File

@ -3877,7 +3877,7 @@ Expr *ASTNodeImporter::VisitCompoundAssignOperator(CompoundAssignOperator *E) {
Importer.Import(E->getOperatorLoc()));
}
bool ImportCastPath(CastExpr *E, CXXCastPath &Path) {
static bool ImportCastPath(CastExpr *E, CXXCastPath &Path) {
if (E->path_empty()) return false;
// TODO: import cast paths

View File

@ -91,6 +91,7 @@ static bool isAlwaysUninit(const Value v) {
return v == Uninitialized;
}
namespace {
class ValueVector {
llvm::BitVector vec;
public:
@ -126,7 +127,6 @@ public:
typedef std::pair<ValueVector *, ValueVector *> BVPair;
namespace {
class CFGBlockValues {
const CFG &cfg;
BVPair *vals;
@ -157,7 +157,7 @@ public:
ValueVector::reference operator[](const VarDecl *vd);
};
}
} // end anonymous namespace
CFGBlockValues::CFGBlockValues(const CFG &c) : cfg(c), vals(0) {
unsigned n = cfg.getNumBlockIDs();

View File

@ -1785,9 +1785,9 @@ static void AddOrdinaryNameResults(Sema::ParserCompletionContext CCC,
///
/// This routine provides a fast path where we provide constant strings for
/// common type names.
const char *GetCompletionTypeString(QualType T,
ASTContext &Context,
CodeCompletionAllocator &Allocator) {
static const char *GetCompletionTypeString(QualType T,
ASTContext &Context,
CodeCompletionAllocator &Allocator) {
PrintingPolicy Policy(Context.PrintingPolicy);
Policy.AnonymousTagLocations = false;

View File

@ -1097,7 +1097,8 @@ static bool DiagnoseDefaultTemplateArgument(Sema &S,
/// \brief Check for unexpanded parameter packs within the template parameters
/// of a template template parameter, recursively.
bool DiagnoseUnexpandedParameterPacks(Sema &S, TemplateTemplateParmDecl *TTP){
static bool DiagnoseUnexpandedParameterPacks(Sema &S,
TemplateTemplateParmDecl *TTP) {
TemplateParameterList *Params = TTP->getTemplateParameters();
for (unsigned I = 0, N = Params->size(); I != N; ++I) {
NamedDecl *P = Params->getParam(I);