If a dysrhythmia is threatening life that would otherwise not be ending, an ICD provides a major safety net. If it fires ONCE, it has saved your life. If a patient reaches a point where life is NOT going to continue. Once someone decides they don't WANT that, an ICD can be turned off. It is not invasive, not painful, not time consuming. If a patient is laying in bed, terminal... at that point, one would NOT want to have a lethal rhythm shocked only to have to die again in hours or days. An ICD thump can be a painful experience- one that would not be appreciated in a hospice setting. Have the doctor who says he NEEDS it have this discussion with you and him.
My Dad was supposed to fill out a form that gave specific directions on what he wanted done or not done after he was diagnosed with end stage heart failure. He didn't like the idea of filling out the form. My Mom and I ended up having to make the decisions based on what we knew he'd want. Very hard thing to do during a hard time.
If your father-in-law ends up in hospice care (like my Dad) it's understood that some things will not be done. They won't do any surgical procedures, anything requiring hospitalization. At the end the hospice folks did only comfort measures - a catheter for his bladder and pain meds, keeping him positioned with pillows to avoid sores and creams for his skin. There was no feeding tube, no IV. And when he did pass, the hospice nurse was right there with him. She noticed his breathing had changed and stayed there. She called us immediately.
At least look over the form, see what you think. And if you think he'll end up with hospice care, see what they allow or disallow.
BTW, my Dad finally died from cancer; his heart kept going till the end.
My wife and I both have a signed "directive" on how to deal with us, individually, when/if we become unable to speak for ourselves. The ramifications are it makes life and death decisions easier for those who have to make those decision on behalf on another, especially on behalf of a loved one.
The format we used makes if very easy to say "don't pull the plug" unless things are really bad. In may case I hope to live as long as it is possible given I am receiving some enjoyment from living. In my mind this can be a rather simple existence, but does not include life support for a comatose or painful state.