added endwise for if/end completion