src/ResolvExpr/Resolver.cc
void finishExpr(
			ast::ptr< ast::Expr > & expr, const ast::TypeEnvironment & env,
			const ast::TypeSubstitution * oldenv = nullptr
		) {
			// set up new type substitution for expression
			ast::ptr< ast::TypeSubstitution > newenv =
				 oldenv ? oldenv : new ast::TypeSubstitution{};
			env.writeToSubstitution( *newenv.get_and_mutate() );
			expr.get_and_mutate()->env = std::move( newenv );
			// remove unncecessary casts
			StripCasts_new::strip( expr );
		}
// anonymous namespace
/// Establish post-resolver invariants for expressions
anonymous namespace
Establish post-resolver invariants for expressions
anonymous namespace Establish post - resolver invariants for expressions
void finishExpr(
			ast::ptr< ast::Expr > & expr, const ast::TypeEnvironment & env,
			const ast::TypeSubstitution * oldenv = nullptr
		) {
			ast::ptr< ast::TypeSubstitution > newenv =
				 oldenv ? oldenv : new ast::TypeSubstitution{};
			env.writeToSubstitution( *newenv.get_and_mutate() );
			expr.get_and_mutate()->env = std::move( newenv );
			StripCasts_new::strip( expr );
		}
void finishExpr ( ast :: ptr < ast :: Expr > & expr , const ast :: TypeEnvironment & env , const ast :: TypeSubstitution * oldenv = nullptr ) { ast :: ptr < ast :: TypeSubstitution > newenv = oldenv ? oldenv : new ast :: TypeSubstitution { } ; env . writeToSubstitution ( * newenv . get_and_mutate ( ) ) ; expr . get_and_mutate ( ) -> env = std :: move ( newenv ) ; StripCasts_new :: strip ( expr ) ; }
anonymous namespace
Establish post-resolver invariants for expressions
anonymous namespace Establish post - resolver invariants for expressions
// set up new type substitution for expression // remove unncecessary casts