Index: src/ResolvExpr/Alternative.cc
===================================================================
--- src/ResolvExpr/Alternative.cc	(revision 4e66a188a07c435c3295bee4f83f72c8069781a8)
+++ src/ResolvExpr/Alternative.cc	(revision 50377a4f7ed2666db8f0a606e0e8573661478734)
@@ -66,17 +66,17 @@
 	}
 
-	void Alternative::print( std::ostream &os, int indent ) const {
-		os << std::string( indent, ' ' ) << "Cost " << cost << ": ";
+	void Alternative::print( std::ostream &os, Indenter indent ) const {
+		os << "Cost " << cost << ": ";
 		if ( expr ) {
-			expr->print( os, indent );
-			os << "(types:" << std::endl;
-			os << std::string( indent+4, ' ' );
-			expr->get_result()->print( os, indent + 4 );
-			os << std::endl << ")" << std::endl;
+			expr->print( os, indent+1 );
+			os << std::endl << indent << "(types:" << std::endl;
+			os << indent+1;
+			expr->result->print( os, indent+1 );
+			os << std::endl << indent << ")" << std::endl;
 		} else {
 			os << "Null expression!" << std::endl;
 		} // if
-		os << std::string( indent, ' ' ) << "Environment: ";
-		env.print( os, indent+2 );
+		os << indent << "Environment: ";
+		env.print( os, indent+1 );
 		os << std::endl;
 	}
Index: src/ResolvExpr/Alternative.h
===================================================================
--- src/ResolvExpr/Alternative.h	(revision 4e66a188a07c435c3295bee4f83f72c8069781a8)
+++ src/ResolvExpr/Alternative.h	(revision 50377a4f7ed2666db8f0a606e0e8573661478734)
@@ -39,5 +39,5 @@
 		~Alternative();
 
-		void print( std::ostream &os, int indent = 0 ) const;
+		void print( std::ostream &os, Indenter indent = {} ) const;
 
 		Cost cost;
Index: src/ResolvExpr/AlternativeFinder.cc
===================================================================
--- src/ResolvExpr/AlternativeFinder.cc	(revision 4e66a188a07c435c3295bee4f83f72c8069781a8)
+++ src/ResolvExpr/AlternativeFinder.cc	(revision 50377a4f7ed2666db8f0a606e0e8573661478734)
@@ -75,5 +75,6 @@
 
 	namespace {
-		void printAlts( const AltList &list, std::ostream &os, int indent = 0 ) {
+		void printAlts( const AltList &list, std::ostream &os, unsigned int indentAmt = 0 ) {
+			Indenter indent = { Indenter::tabsize, indentAmt };
 			for ( AltList::const_iterator i = list.begin(); i != list.end(); ++i ) {
 				i->print( os, indent );
@@ -195,8 +196,8 @@
 				AltList winners;
 				findMinCost( alternatives.begin(), alternatives.end(), back_inserter( winners ) );
-				stream << "Cannot choose between " << winners.size() << " alternatives for expression ";
+				stream << "Cannot choose between " << winners.size() << " alternatives for expression\n";
 				expr->print( stream );
-				stream << "Alternatives are:";
-				printAlts( winners, stream, 8 );
+				stream << "Alternatives are:\n";
+				printAlts( winners, stream, 1 );
 				throw SemanticError( stream.str() );
 			}
@@ -728,5 +729,5 @@
 		PRINT(
 			std::cerr << "known function ops:" << std::endl;
-			printAlts( funcOpFinder.alternatives, std::cerr, 8 );
+			printAlts( funcOpFinder.alternatives, std::cerr, 1 );
 		)
 
Index: src/ResolvExpr/TypeEnvironment.cc
===================================================================
--- src/ResolvExpr/TypeEnvironment.cc	(revision 4e66a188a07c435c3295bee4f83f72c8069781a8)
+++ src/ResolvExpr/TypeEnvironment.cc	(revision 50377a4f7ed2666db8f0a606e0e8573661478734)
@@ -68,11 +68,11 @@
 	}
 
-	void EqvClass::print( std::ostream &os, int indent ) const {
-		os << std::string( indent, ' ' ) << "( ";
+	void EqvClass::print( std::ostream &os, Indenter indent ) const {
+		os << "( ";
 		std::copy( vars.begin(), vars.end(), std::ostream_iterator< std::string >( os, " " ) );
 		os << ")";
 		if ( type ) {
 			os << " -> ";
-			type->print( os, indent );
+			type->print( os, indent+1 );
 		} // if
 		if ( ! allowWidening ) {
@@ -144,5 +144,5 @@
 	}
 
-	void TypeEnvironment::print( std::ostream &os, int indent ) const {
+	void TypeEnvironment::print( std::ostream &os, Indenter indent ) const {
 		for ( std::list< EqvClass >::const_iterator i = env.begin(); i != env.end(); ++i ) {
 			i->print( os, indent );
Index: src/ResolvExpr/TypeEnvironment.h
===================================================================
--- src/ResolvExpr/TypeEnvironment.h	(revision 4e66a188a07c435c3295bee4f83f72c8069781a8)
+++ src/ResolvExpr/TypeEnvironment.h	(revision 50377a4f7ed2666db8f0a606e0e8573661478734)
@@ -68,5 +68,5 @@
 		EqvClass &operator=( const EqvClass &other );
 		~EqvClass();
-		void print( std::ostream &os, int indent = 0 ) const;
+		void print( std::ostream &os, Indenter indent = {} ) const;
 	};
 
@@ -80,5 +80,5 @@
 		void makeSubstitution( TypeSubstitution &result ) const;
 		bool isEmpty() const { return env.empty(); }
-		void print( std::ostream &os, int indent = 0 ) const;
+		void print( std::ostream &os, Indenter indent = {} ) const;
 		void combine( const TypeEnvironment &second, Type *(*combineFunc)( Type*, Type* ) );
 		void simpleCombine( const TypeEnvironment &second );
