mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Propagate a DeclContext through NameBinding for IdentifierTypes.
Swift SVN r1803
This commit is contained in:
@@ -138,12 +138,13 @@ public:
|
||||
class TranslationUnit : public Module {
|
||||
public:
|
||||
typedef std::pair<Module::AccessPathTy, Module*> ImportedModule;
|
||||
typedef std::pair<IdentifierType*, DeclContext*> IdentTypeAndContext;
|
||||
typedef std::pair<TupleType*, DeclContext*> TupleTypeAndContext;
|
||||
private:
|
||||
/// UnresolvedIdentifierTypes - This is a list of scope-qualified dotted types
|
||||
/// that were unresolved at the end of the translation unit's parse
|
||||
/// phase.
|
||||
ArrayRef<IdentifierType*> UnresolvedIdentifierTypes;
|
||||
ArrayRef<IdentTypeAndContext> UnresolvedIdentifierTypes;
|
||||
|
||||
/// UnresolvedIdentifierTypes - This is a list of tuples containing a default
|
||||
/// value expression, along with the context containing the type with the
|
||||
@@ -167,16 +168,16 @@ public:
|
||||
/// getUnresolvedIdentifierTypes - This is a list of scope-qualified types
|
||||
/// that were unresolved at the end of the translation unit's parse
|
||||
/// phase.
|
||||
ArrayRef<IdentifierType*> getUnresolvedIdentifierTypes() const {
|
||||
ArrayRef<IdentTypeAndContext> getUnresolvedIdentifierTypes() const {
|
||||
assert(ASTStage == Parsed);
|
||||
return UnresolvedIdentifierTypes;
|
||||
}
|
||||
void setUnresolvedIdentifierTypes(ArrayRef<IdentifierType*> T) {
|
||||
void setUnresolvedIdentifierTypes(ArrayRef<IdentTypeAndContext> T) {
|
||||
assert(ASTStage == Parsing);
|
||||
UnresolvedIdentifierTypes = T;
|
||||
}
|
||||
void clearUnresolvedIdentifierTypes() {
|
||||
UnresolvedIdentifierTypes = ArrayRef<IdentifierType*>();
|
||||
UnresolvedIdentifierTypes = ArrayRef<IdentTypeAndContext>();
|
||||
}
|
||||
|
||||
ArrayRef<TupleTypeAndContext> getTypesWithDefaultValues() const {
|
||||
|
||||
Reference in New Issue
Block a user