raycasthit 'hit' does not exist in current context

I’m trying to assign RaycastHit to variable ‘hit’ in Csharp.

keep getting errors no matter how I try to assign it.

 var hit = RaycastHit;
 Destroy(hit.transform.gameObject);

Is there some special method to assigning RaycastHit? How am I supposed to use raycast to destroy game \object? I thought RaycastHit was supposed to contacin info from raycast, why cant i access it?

if (Physics.Raycast (transform.position, -Vector3.up, out hit))
{

print(hit.collider.name);
Debug.DrawLine(transform.position, hit.point);
}