Index: src/SymTab/Indexer.cc
===================================================================
--- src/SymTab/Indexer.cc	(revision 6f096d2341e25591a9d9435e4a28725954748a7a)
+++ src/SymTab/Indexer.cc	(revision be53b87bb8b688d529b9f3ca8a4a7bfd47305629)
@@ -210,5 +210,5 @@
 	bool Indexer::addedIdConflicts(
 			const Indexer::IdData & existing, const DeclarationWithType * added,
-			Indexer::OnConflict handleConflicts, const BaseSyntaxNode * deleteStmt ) {
+			Indexer::OnConflict handleConflicts, const Declaration * deleteStmt ) {
 		// if we're giving the same name mangling to things of different types then there is
 		// something wrong
@@ -432,5 +432,5 @@
 
 	void Indexer::addId(const DeclarationWithType * decl, OnConflict handleConflicts, const Expression * baseExpr,
-			const BaseSyntaxNode * deleteStmt ) {
+			const Declaration * deleteStmt ) {
 		++* stats().add_calls;
 		const std::string &name = decl->name;
@@ -510,5 +510,5 @@
 	}
 
-	void Indexer::addDeletedId( const DeclarationWithType * decl, const BaseSyntaxNode * deleteStmt ) {
+	void Indexer::addDeletedId( const DeclarationWithType * decl, const Declaration * deleteStmt ) {
 		// default handling of conflicts is to raise an error
 		addId( decl, OnConflict::error(), nullptr, deleteStmt );
@@ -661,5 +661,5 @@
 	}
 
-	void Indexer::addWith( const std::list< Expression * > & withExprs, const BaseSyntaxNode * withStmt ) {
+	void Indexer::addWith( const std::list< Expression * > & withExprs, const Declaration * withStmt ) {
 		for ( const Expression * expr : withExprs ) {
 			if ( expr->result ) {
@@ -704,5 +704,5 @@
 			ret = new VariableExpr( const_cast<DeclarationWithType *>(id) );
 		}
-		if ( deleteStmt ) ret = new DeletedExpr( ret, const_cast<BaseSyntaxNode *>(deleteStmt) );
+		if ( deleteStmt ) ret = new DeletedExpr( ret, const_cast<Declaration *>(deleteStmt) );
 		return ret;
 	}
Index: src/SymTab/Indexer.h
===================================================================
--- src/SymTab/Indexer.h	(revision 6f096d2341e25591a9d9435e4a28725954748a7a)
+++ src/SymTab/Indexer.h	(revision be53b87bb8b688d529b9f3ca8a4a7bfd47305629)
@@ -44,5 +44,5 @@
 
 			/// non-null if this declaration is deleted
-			const BaseSyntaxNode * deleteStmt = nullptr;
+			const Declaration * deleteStmt = nullptr;
 			/// scope of identifier
 			unsigned long scope = 0;
@@ -51,8 +51,8 @@
 			IdData() = default;
 			IdData(
-				const DeclarationWithType * id, const Expression * baseExpr, const BaseSyntaxNode * deleteStmt,
+				const DeclarationWithType * id, const Expression * baseExpr, const Declaration * deleteStmt,
 				unsigned long scope )
 				: id( id ), baseExpr( baseExpr ), deleteStmt( deleteStmt ), scope( scope ) {}
-			IdData( const IdData& o, const BaseSyntaxNode * deleteStmt )
+			IdData( const IdData& o, const Declaration * deleteStmt )
 				: id( o.id ), baseExpr( o.baseExpr ), deleteStmt( deleteStmt ), scope( o.scope ) {}
 
@@ -83,5 +83,5 @@
 
 		void addId( const DeclarationWithType * decl, const Expression * baseExpr = nullptr );
-		void addDeletedId( const DeclarationWithType * decl, const BaseSyntaxNode * deleteStmt );
+		void addDeletedId( const DeclarationWithType * decl, const Declaration * deleteStmt );
 
 		void addType( const NamedTypeDecl * decl );
@@ -94,5 +94,5 @@
 
 		/// adds all of the IDs from WithStmt exprs
-		void addWith( const std::list< Expression * > & withExprs, const BaseSyntaxNode * withStmt );
+		void addWith( const std::list< Expression * > & withExprs, const Declaration * withStmt );
 
 		/// convenience function for adding a list of Ids to the indexer
@@ -152,14 +152,14 @@
 				Delete  ///< Delete the earlier version with the delete statement
 			} mode;
-			const BaseSyntaxNode * deleteStmt;  ///< Statement that deletes this expression
+			const Declaration * deleteStmt;  ///< Statement that deletes this expression
 
 		private:
 			OnConflict() : mode(Error), deleteStmt(nullptr) {}
-			OnConflict( const BaseSyntaxNode * d ) : mode(Delete), deleteStmt(d) {}
+			OnConflict( const Declaration * d ) : mode(Delete), deleteStmt(d) {}
 		public:
 			OnConflict( const OnConflict& ) = default;
 
 			static OnConflict error() { return {}; }
-			static OnConflict deleteWith( const BaseSyntaxNode * d ) { return { d }; }
+			static OnConflict deleteWith( const Declaration * d ) { return { d }; }
 		};
 
@@ -167,9 +167,9 @@
 		bool addedIdConflicts(
 			const IdData & existing, const DeclarationWithType * added, OnConflict handleConflicts,
-			const BaseSyntaxNode * deleteStmt );
+			const Declaration * deleteStmt );
 
 		/// common code for addId, addDeletedId, etc.
 		void addId(const DeclarationWithType * decl, OnConflict handleConflicts,
-			const Expression * baseExpr = nullptr, const BaseSyntaxNode * deleteStmt = nullptr );
+			const Expression * baseExpr = nullptr, const Declaration * deleteStmt = nullptr );
 
 		/// adds all of the members of the Aggregate (addWith helper)
