Type resolution favor local types.
Test: mma (see main.cpp; it is statically tested to ensure
types are resolved correctly)
Bug: 31971432
Change-Id: Iaf5c0ac30941269200f4c0b8312437eed61606b4
diff --git a/AST.h b/AST.h
index 7310942..a7f08b2 100644
--- a/AST.h
+++ b/AST.h
@@ -147,6 +147,11 @@
NamedType *type,
std::string *errorMsg);
+ // Helper functions for lookupType.
+ Type *lookupTypeLocally(const FQName &fqName);
+ status_t lookupAutofilledType(const FQName &fqName, Type **returnedType);
+ Type *lookupTypeFromImports(const FQName &fqName);
+
// Find a type matching fqName (which may be partial) and if found
// return the associated type and fill in the full "matchingName".
// Only types defined in this very AST are considered.