Skip to content

Commit db3acd2

Browse files
committed
---
yaml --- r: 327163 b: refs/heads/tensorflow c: a7888f0 h: refs/heads/master i: 327161: a73f35a 327159: 09602ef
1 parent 6f270ce commit db3acd2

File tree

91 files changed

+3937
-2012
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

91 files changed

+3937
-2012
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -816,7 +816,7 @@ refs/tags/swift-DEVELOPMENT-SNAPSHOT-2018-04-25-a: 22f738a831d43aff2b9c9773bcb65
816816
refs/tags/swift-DEVELOPMENT-SNAPSHOT-2018-05-08-a: 7d98cc16689baba5c8a3b90a9329bdcc1a12b4e9
817817
refs/heads/cherr42: a566ad54b073c2c56ac0a705d0a5bed9743135a5
818818
"refs/heads/codable_test_comment_fix": fc8f6824f7f347e1e8db55bff62db385c5728b5a
819-
refs/heads/tensorflow: 016acf3ac9061c22d39ab75cae817cd3f5565f7c
819+
refs/heads/tensorflow: a7888f0720d783925fb0084612fd4f0075afdfaf
820820
refs/tags/swift-4.1-DEVELOPMENT-SNAPSHOT-2018-05-11-a: 8126fd7a652e2f70ad6d76505239e34fb2ef3e1a
821821
refs/tags/swift-4.1-DEVELOPMENT-SNAPSHOT-2018-05-12-a: b3fd3dd84df6717f2e2e9df58c6d7e99fed57086
822822
refs/tags/swift-4.1-DEVELOPMENT-SNAPSHOT-2018-05-13-a: 71135119579039dc321c5f65d870050fe36efda2

branches/tensorflow/include/swift/AST/ASTContext.h

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -112,10 +112,6 @@ namespace swift {
112112

113113
enum class KnownProtocolKind : uint8_t;
114114

115-
namespace namelookup {
116-
class ImportCache;
117-
}
118-
119115
namespace syntax {
120116
class SyntaxArena;
121117
}
@@ -687,9 +683,7 @@ class ASTContext final {
687683
/// If there is no Clang module loader, returns a null pointer.
688684
/// The loader is owned by the AST context.
689685
ClangModuleLoader *getDWARFModuleLoader() const;
690-
691-
namelookup::ImportCache &getImportCache() const;
692-
686+
693687
/// Asks every module loader to verify the ASTs it has loaded.
694688
///
695689
/// Does nothing in non-asserts (NDEBUG) builds.

branches/tensorflow/include/swift/AST/Builtins.def

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -418,14 +418,6 @@ BUILTIN_MISC_OPERATION(Strideof, "strideof", "n", Special)
418418
/// IsPOD has type T.Type -> Bool
419419
BUILTIN_MISC_OPERATION(IsPOD, "ispod", "n", Special)
420420

421-
/// IsConcrete has type (T.Type) -> Bool
422-
///
423-
/// If the meta type T is concrete, we can always transform this to `true` at
424-
/// any time in SIL. If it's generic, then we lower it to `false` right before
425-
/// IRGen in IRGenPrepare. This allows for the optimizer to specialize this at
426-
/// -O and eliminate conditional code.
427-
BUILTIN_MISC_OPERATION(IsConcrete, "isConcrete", "n", Special)
428-
429421
/// IsBitwiseTakable has type T.Type -> Bool
430422
BUILTIN_MISC_OPERATION(IsBitwiseTakable, "isbitwisetakable", "n", Special)
431423

branches/tensorflow/include/swift/AST/DiagnosticsModuleDiffer.def

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,8 +96,6 @@ ERROR(decl_new_witness_table_entry,none,"%0 now requires %select{|no}1 new witne
9696

9797
ERROR(new_decl_without_intro,none,"%0 is a new API without @available attribute", (StringRef))
9898

99-
ERROR(objc_name_change,none,"%0 has ObjC name change from %1 to %2", (StringRef, StringRef, StringRef))
100-
10199
#ifndef DIAG_NO_UNDEF
102100
# if defined(DIAG)
103101
# undef DIAG

branches/tensorflow/include/swift/AST/ImportCache.h

Lines changed: 0 additions & 191 deletions
This file was deleted.

branches/tensorflow/include/swift/AST/ModuleNameLookup.h

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -42,25 +42,24 @@ enum class ResolutionKind {
4242
TypesOnly
4343
};
4444

45-
/// Performs a lookup into the given module and it's imports.
46-
///
47-
/// If 'moduleOrFile' is a ModuleDecl, we search the module and it's
48-
/// public imports. If 'moduleOrFile' is a SourceFile, we search the
49-
/// file's parent module, the module's public imports, and the source
50-
/// file's private imports.
45+
/// Performs a lookup into the given module and, if necessary, its
46+
/// reexports, observing proper shadowing rules.
5147
///
52-
/// \param moduleOrFile The module or file unit whose imports to search.
48+
/// \param module The module that will contain the name.
49+
/// \param accessPath The import scope on \p module.
5350
/// \param name The name to look up.
5451
/// \param[out] decls Any found decls will be added to this vector.
5552
/// \param lookupKind Whether this lookup is qualified or unqualified.
5653
/// \param resolutionKind What sort of decl is expected.
5754
/// \param moduleScopeContext The top-level context from which the lookup is
5855
/// being performed, for checking access. This must be either a
5956
/// FileUnit or a Module.
60-
void lookupInModule(const DeclContext *moduleOrFile,
57+
/// \param extraImports Private imports to include in this search.
58+
void lookupInModule(ModuleDecl *module, ModuleDecl::AccessPathTy accessPath,
6159
DeclName name, SmallVectorImpl<ValueDecl *> &decls,
6260
NLKind lookupKind, ResolutionKind resolutionKind,
63-
const DeclContext *moduleScopeContext);
61+
const DeclContext *moduleScopeContext,
62+
ArrayRef<ModuleDecl::ImportedModule> extraImports = {});
6463

6564
template <typename Fn>
6665
void forAllVisibleModules(const DeclContext *DC, const Fn &fn) {
@@ -75,12 +74,12 @@ void forAllVisibleModules(const DeclContext *DC, const Fn &fn) {
7574
/// Performs a qualified lookup into the given module and, if necessary, its
7675
/// reexports, observing proper shadowing rules.
7776
void
78-
lookupVisibleDeclsInModule(const DeclContext *moduleOrFile,
79-
ModuleDecl::AccessPathTy accessPath,
77+
lookupVisibleDeclsInModule(ModuleDecl *M, ModuleDecl::AccessPathTy accessPath,
8078
SmallVectorImpl<ValueDecl *> &decls,
8179
NLKind lookupKind,
8280
ResolutionKind resolutionKind,
83-
const DeclContext *moduleScopeContext);
81+
const DeclContext *moduleScopeContext,
82+
ArrayRef<ModuleDecl::ImportedModule> extraImports = {});
8483

8584
} // end namespace namelookup
8685

branches/tensorflow/include/swift/AST/NameLookup.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -378,11 +378,11 @@ bool removeOverriddenDecls(SmallVectorImpl<ValueDecl*> &decls);
378378
/// other declarations in that set.
379379
///
380380
/// \param decls The set of declarations being considered.
381-
/// \param dc The DeclContext from which the lookup was performed.
381+
/// \param curModule The current module.
382382
///
383383
/// \returns true if any shadowed declarations were removed.
384384
bool removeShadowedDecls(SmallVectorImpl<ValueDecl*> &decls,
385-
const DeclContext *dc);
385+
const ModuleDecl *curModule);
386386

387387
/// Finds decls visible in the given context and feeds them to the given
388388
/// VisibleDeclConsumer. If the current DeclContext is nested in a function,

branches/tensorflow/include/swift/Basic/LangOptions.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ namespace swift {
259259
bool WarnIfASTScopeLookup = false;
260260

261261
/// Build the ASTScope tree lazily
262-
bool LazyASTScopes = true;
262+
bool LazyASTScopes = false;
263263

264264
/// Whether to use the import as member inference system
265265
///

branches/tensorflow/include/swift/Basic/Statistics.def

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -175,19 +175,6 @@ FRONTEND_STATISTIC(AST, NumBraceStmtASTScopeExpansions)
175175
/// Number of ASTScope lookups
176176
FRONTEND_STATISTIC(AST, NumASTScopeLookups)
177177

178-
/// Number of lookups of the cached import graph for a module or
179-
/// source file.
180-
FRONTEND_STATISTIC(AST, ImportSetFoldHit)
181-
FRONTEND_STATISTIC(AST, ImportSetFoldMiss)
182-
183-
FRONTEND_STATISTIC(AST, ImportSetCacheHit)
184-
FRONTEND_STATISTIC(AST, ImportSetCacheMiss)
185-
186-
FRONTEND_STATISTIC(AST, ModuleVisibilityCacheHit)
187-
FRONTEND_STATISTIC(AST, ModuleVisibilityCacheMiss)
188-
189-
FRONTEND_STATISTIC(AST, ModuleShadowCacheHit)
190-
FRONTEND_STATISTIC(AST, ModuleShadowCacheMiss)
191178

192179
/// Number of full function bodies parsed.
193180
FRONTEND_STATISTIC(Parse, NumFunctionsParsed)

branches/tensorflow/include/swift/Frontend/Frontend.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -297,6 +297,7 @@ class CompilerInvocation {
297297
/// Called from lldb, see rdar://53971116
298298
void disableASTScopeLookup() {
299299
LangOpts.EnableASTScopeLookup = false;
300+
LangOpts.LazyASTScopes = false;
300301
}
301302

302303
CodeCompletionCallbacksFactory *getCodeCompletionFactory() const {

branches/tensorflow/include/swift/IDE/DigesterEnums.def

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,6 @@ KEY_STRING(IntroiOS, intro_iOS)
151151
KEY_STRING(IntrotvOS, intro_tvOS)
152152
KEY_STRING(IntrowatchOS, intro_watchOS)
153153
KEY_STRING(Introswift, intro_swift)
154-
KEY_STRING(ObjCName, objc_name)
155154

156155
KEY_STRING_ARR(SuperclassNames, superclassNames)
157156
KEY_STRING_ARR(ToolArgs, tool_arguments)

branches/tensorflow/include/swift/Index/IndexSymbol.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,6 @@ struct IndexSymbol : IndexRelation {
6666
SmallVector<IndexRelation, 3> Relations;
6767
unsigned line = 0;
6868
unsigned column = 0;
69-
Optional<unsigned> offset;
7069

7170
IndexSymbol() = default;
7271

branches/tensorflow/lib/AST/ASTContext.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@
2525
#include "swift/AST/GenericEnvironment.h"
2626
#include "swift/AST/GenericSignature.h"
2727
#include "swift/AST/GenericSignatureBuilder.h"
28-
#include "swift/AST/ImportCache.h"
2928
#include "swift/AST/KnownProtocols.h"
3029
#include "swift/AST/LazyResolver.h"
3130
#include "swift/AST/ModuleLoader.h"
@@ -253,9 +252,6 @@ FOR_KNOWN_FOUNDATION_TYPES(CACHE_FOUNDATION_DECL)
253252
/// ASTContext.
254253
SmallVector<std::unique_ptr<swift::ModuleLoader>, 4> ModuleLoaders;
255254

256-
/// Singleton used to cache the import graph.
257-
swift::namelookup::ImportCache TheImportCache;
258-
259255
/// The module loader used to load Clang modules.
260256
ClangModuleLoader *TheClangModuleLoader = nullptr;
261257

@@ -1498,10 +1494,6 @@ void ASTContext::verifyAllLoadedModules() const {
14981494
#endif
14991495
}
15001496

1501-
swift::namelookup::ImportCache &ASTContext::getImportCache() const {
1502-
return getImpl().TheImportCache;
1503-
}
1504-
15051497
ClangModuleLoader *ASTContext::getClangModuleLoader() const {
15061498
return getImpl().TheClangModuleLoader;
15071499
}

0 commit comments

Comments
 (0)