summaryrefslogtreecommitdiffstats
path: root/lib/Serialization/ASTReaderInternals.h
diff options
context:
space:
mode:
authorFangrui Song <maskray@google.com>2018-07-30 19:24:48 +0000
committerFangrui Song <maskray@google.com>2018-07-30 19:24:48 +0000
commitabdbb605f2c3cbe63cd589da230f648535dff76b (patch)
tree5f8677c5a6cdf9e4aebd71560932f399f956f7cc /lib/Serialization/ASTReaderInternals.h
parent19e630a4739c684e5848d2f926d0beb114bbce7b (diff)
Remove trailing space
sed -Ei 's/[[:space:]]+$//' include/**/*.{def,h,td} lib/**/*.{cpp,h} git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@338291 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Serialization/ASTReaderInternals.h')
-rw-r--r--lib/Serialization/ASTReaderInternals.h54
1 files changed, 27 insertions, 27 deletions
diff --git a/lib/Serialization/ASTReaderInternals.h b/lib/Serialization/ASTReaderInternals.h
index b5a1493a4f..37a929907d 100644
--- a/lib/Serialization/ASTReaderInternals.h
+++ b/lib/Serialization/ASTReaderInternals.h
@@ -33,7 +33,7 @@ struct HeaderFileInfo;
class HeaderSearch;
class IdentifierTable;
class ObjCMethodDecl;
-
+
namespace serialization {
class ModuleFile;
@@ -45,7 +45,7 @@ namespace reader {
class ASTDeclContextNameLookupTrait {
ASTReader &Reader;
ModuleFile &F;
-
+
public:
// Maximum number of lookup tables we allow before condensing the tables.
static const int MaxTables = 4;
@@ -141,31 +141,31 @@ public:
}
static hash_value_type ComputeHash(const internal_key_type& a);
-
+
static std::pair<unsigned, unsigned>
ReadKeyDataLength(const unsigned char*& d);
// This hopefully will just get inlined and removed by the optimizer.
static const internal_key_type&
GetInternalKey(const external_key_type& x) { return x; }
-
+
// This hopefully will just get inlined and removed by the optimizer.
static const external_key_type&
GetExternalKey(const internal_key_type& x) { return x; }
- static internal_key_type ReadKey(const unsigned char* d, unsigned n);
+ static internal_key_type ReadKey(const unsigned char* d, unsigned n);
};
/// Class that performs lookup for an identifier stored in an AST file.
class ASTIdentifierLookupTrait : public ASTIdentifierLookupTraitBase {
ASTReader &Reader;
ModuleFile &F;
-
+
// If we know the IdentifierInfo in advance, it is here and we will
// not build a new one. Used when deserializing information about an
// identifier that was constructed before the AST file was read.
IdentifierInfo *KnownII;
-
+
public:
using data_type = IdentifierInfo *;
@@ -176,12 +176,12 @@ public:
data_type ReadData(const internal_key_type& k,
const unsigned char* d,
unsigned DataLen);
-
+
IdentID ReadIdentifierID(const unsigned char *d);
ASTReader &getReader() const { return Reader; }
};
-
+
/// The on-disk hash table used to contain information about
/// all of the identifiers in the program.
using ASTIdentifierLookupTable =
@@ -192,7 +192,7 @@ using ASTIdentifierLookupTable =
class ASTSelectorLookupTrait {
ASTReader &Reader;
ModuleFile &F;
-
+
public:
struct data_type {
SelectorID ID;
@@ -203,40 +203,40 @@ public:
SmallVector<ObjCMethodDecl *, 2> Instance;
SmallVector<ObjCMethodDecl *, 2> Factory;
};
-
+
using external_key_type = Selector;
using internal_key_type = external_key_type;
using hash_value_type = unsigned;
using offset_type = unsigned;
-
+
ASTSelectorLookupTrait(ASTReader &Reader, ModuleFile &F)
: Reader(Reader), F(F) {}
-
+
static bool EqualKey(const internal_key_type& a,
const internal_key_type& b) {
return a == b;
}
-
+
static hash_value_type ComputeHash(Selector Sel);
-
+
static const internal_key_type&
GetInternalKey(const external_key_type& x) { return x; }
-
+
static std::pair<unsigned, unsigned>
ReadKeyDataLength(const unsigned char*& d);
-
+
internal_key_type ReadKey(const unsigned char* d, unsigned);
data_type ReadData(Selector, const unsigned char* d, unsigned DataLen);
};
-
+
/// The on-disk hash table used for the global method pool.
using ASTSelectorLookupTable =
llvm::OnDiskChainedHashTable<ASTSelectorLookupTrait>;
-
+
/// Trait class used to search the on-disk hash table containing all of
/// the header search information.
///
-/// The on-disk hash table contains a mapping from each header path to
+/// The on-disk hash table contains a mapping from each header path to
/// information about that header (how many times it has been included, its
/// controlling macro, etc.). Note that we actually hash based on the size
/// and mtime, and support "deep" comparisons of file names based on current
@@ -259,31 +259,31 @@ public:
};
using internal_key_ref = const internal_key_type &;
-
+
using data_type = HeaderFileInfo;
using hash_value_type = unsigned;
using offset_type = unsigned;
-
+
HeaderFileInfoTrait(ASTReader &Reader, ModuleFile &M, HeaderSearch *HS,
const char *FrameworkStrings)
: Reader(Reader), M(M), HS(HS), FrameworkStrings(FrameworkStrings) {}
-
+
static hash_value_type ComputeHash(internal_key_ref ikey);
internal_key_type GetInternalKey(const FileEntry *FE);
bool EqualKey(internal_key_ref a, internal_key_ref b);
-
+
static std::pair<unsigned, unsigned>
ReadKeyDataLength(const unsigned char*& d);
-
+
static internal_key_type ReadKey(const unsigned char *d, unsigned);
-
+
data_type ReadData(internal_key_ref,const unsigned char *d, unsigned DataLen);
};
/// The on-disk hash table used for known header files.
using HeaderFileInfoLookupTable =
llvm::OnDiskChainedHashTable<HeaderFileInfoTrait>;
-
+
} // namespace reader
} // namespace serialization