Add location info to named types.

Bug: 31827278

Test: hidl_test
Change-Id: I1922d5c309c9706cef37ab34d28e1193d1e247cd
diff --git a/AST.h b/AST.h
index 9a3670c..a4b4cda 100644
--- a/AST.h
+++ b/AST.h
@@ -32,6 +32,7 @@
 struct Coordinator;
 struct Formatter;
 struct Interface;
+struct Location;
 struct Method;
 struct NamedType;
 struct TypedVar;
@@ -55,7 +56,8 @@
     Scope *scope();
 
     // Returns true iff successful.
-    bool addTypeDef(const char *localName, Type *type, std::string *errorMsg);
+    bool addTypeDef(const char *localName, Type *type, const Location &location,
+            std::string *errorMsg);
 
     // Returns true iff successful.
     bool addScopedType(NamedType *type, std::string *errorMsg);