Employee was operating #9 locomotive. He stopped the locomotive and stepped off the locomotive onto the clear and space along the track. He twisted his right ankle and fell down. The learance space was free of obstructions and had loose slag in the travelway.