Index: src/ResolvExpr/Unify.cc
===================================================================
--- src/ResolvExpr/Unify.cc	(revision 9d79f93feba80fa8dad090444ec65f5916b13bd5)
+++ src/ResolvExpr/Unify.cc	(revision 3096ec12d2390a7c26677b34b4cde57bf1a539c6)
@@ -22,4 +22,5 @@
 #include <utility>                // for pair
 
+#include "Common/PassVisitor.h"   // for PassVisitor
 #include "FindOpenVars.h"         // for findOpenVars
 #include "Parser/LinkageSpec.h"   // for C
@@ -537,10 +538,11 @@
 	/// If this isn't done then argument lists can have wildly different
 	/// size and structure, when they should be compatible.
-	struct TtypeExpander : public Mutator {
-		TypeEnvironment & env;
-		TtypeExpander( TypeEnvironment & env ) : env( env ) {}
-		Type * mutate( TypeInstType * typeInst ) {
+	struct TtypeExpander : public WithShortCircuiting {
+		TypeEnvironment & tenv;
+		TtypeExpander( TypeEnvironment & tenv ) : tenv( tenv ) {}
+		void premutate( TypeInstType * ) { visit_children = false; }
+		Type * postmutate( TypeInstType * typeInst ) {
 			EqvClass eqvClass;
-			if ( env.lookup( typeInst->get_name(), eqvClass ) ) {
+			if ( tenv.lookup( typeInst->get_name(), eqvClass ) ) {
 				if ( eqvClass.data.kind == TypeDecl::Ttype ) {
 					// expand ttype parameter into its actual type
@@ -560,5 +562,5 @@
 		dst.clear();
 		for ( DeclarationWithType * dcl : src ) {
-			TtypeExpander expander( env );
+			PassVisitor<TtypeExpander> expander( env );
 			dcl->acceptMutator( expander );
 			std::list< Type * > types;
@@ -750,5 +752,5 @@
 			std::list<Type *> types1, types2;
 
-			TtypeExpander expander( env );
+			PassVisitor<TtypeExpander> expander( env );
 			flat1->acceptMutator( expander );
 			flat2->acceptMutator( expander );
