Skip to content

Commit fe999d9

Browse files
author
David Ungar
committed
Format.
1 parent 4ca97ab commit fe999d9

File tree

4 files changed

+8
-5
lines changed

4 files changed

+8
-5
lines changed

include/swift/AST/ASTContext.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -943,7 +943,7 @@ class ASTContext final {
943943
}
944944

945945
/// Logically, there is a separate cache for each SourceFile.
946-
llvm::SmallVectorImpl<Type> &getDefaultTypeRequestCache(SourceFile*);
946+
llvm::SmallVectorImpl<Type> &getDefaultTypeRequestCache(SourceFile *);
947947

948948
private:
949949
friend Decl;

include/swift/AST/DeclContext.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -784,7 +784,7 @@ class IterableDeclContext {
784784
template <typename ParamT, typename = typename std::enable_if<
785785
std::is_same<ParamT, DeclContext>::value>::type>
786786
void simple_display(llvm::raw_ostream &out, const ParamT *dc) {
787-
if (!dc) {
787+
if (!dc) {
788788
out << "(null)";
789789
return;
790790
}

lib/AST/ASTContext.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,8 @@ FOR_KNOWN_FOUNDATION_TYPES(CACHE_FOUNDATION_DECL)
293293
/// Caches of default types for DefaultTypeRequest.
294294
/// Used to be instance variables in the TypeChecker.
295295
/// There is a logically separate cache for each SourceFile.
296-
llvm::DenseMap<SourceFile*, llvm::SmallVector<Type, NumKnownProtocols>> DefaultTypeRequestCaches;
296+
llvm::DenseMap<SourceFile *, llvm::SmallVector<Type, NumKnownProtocols>>
297+
DefaultTypeRequestCaches;
297298

298299
/// Structure that captures data that is segregated into different
299300
/// arenas.
@@ -5079,6 +5080,7 @@ LayoutConstraint LayoutConstraint::getLayoutConstraint(LayoutConstraintKind Kind
50795080
return LayoutConstraint(New);
50805081
}
50815082

5082-
llvm::SmallVectorImpl<Type> &ASTContext::getDefaultTypeRequestCache(SourceFile* SF) {
5083+
llvm::SmallVectorImpl<Type> &
5084+
ASTContext::getDefaultTypeRequestCache(SourceFile *SF) {
50835085
return getImpl().DefaultTypeRequestCaches[SF];
50845086
}

lib/AST/TypeCheckRequests.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -457,7 +457,8 @@ SourceFile *DefaultTypeRequest::getSourceFile() const {
457457
}
458458

459459
llvm::SmallVectorImpl<Type> &DefaultTypeRequest::getCache() const {
460-
return getDeclContext()->getASTContext().getDefaultTypeRequestCache(getSourceFile());
460+
return getDeclContext()->getASTContext().getDefaultTypeRequestCache(
461+
getSourceFile());
461462
}
462463

463464
Optional<Type> DefaultTypeRequest::getCachedResult() const {

0 commit comments

Comments
 (0)