Index: src/Virtual/ExpandCasts.cc
===================================================================
--- src/Virtual/ExpandCasts.cc	(revision 08fc48f4a5c70b7f3e402da3afef2763f754ff3a)
+++ src/Virtual/ExpandCasts.cc	(revision 098f7ff82a41df8f91550ab661699753dd53e90f)
@@ -147,16 +147,16 @@
 				//		)
 				//	),
-			new UntypedExpr( new NameExpr( "__cfa__virtual_cast" ), {
+			new ApplicationExpr( VariableExpr::functionPointer( vcast_decl ), {
 					new CastExpr(
 						new AddressExpr( new VariableExpr( table ) ),
 						pointer_to_pvt(1)
-						),
+					),
 					new CastExpr(
 						castExpr->get_arg(),
 						pointer_to_pvt(2)
-						)
-				} ),
+					)
+			} ),
 			castExpr->get_result()->clone()
-			);
+		);
 
 		castExpr->set_arg( nullptr );
