The eraser tool can be used on most layers but not all. A warning will appear when you try to use it on a layer that cannot be erased, prompting you to select another layer.