Index: src/Concurrency/Keywords.cc
===================================================================
--- src/Concurrency/Keywords.cc	(revision 1cdfa82ab4efb64ed6273f4e8e3993bc8895a419)
+++ src/Concurrency/Keywords.cc	(revision f6f0cca3f172613989f420c40761026fe191b651)
@@ -284,10 +284,7 @@
 			// convert (thread &)t to (thread_desc &)*get_thread(t), etc.
 			if( !type_decl ) SemanticError( cast, context_error );
-			Expression * arg = cast->arg;
-			cast->arg = nullptr;
-			delete cast;
 			return new CastExpr(
 				UntypedExpr::createDeref(
-					new UntypedExpr( new NameExpr( getter_name ), { arg } )
+					new UntypedExpr( new NameExpr( getter_name ), { cast->arg } )
 				),
 				new ReferenceType(
