Then you get terminal cancer. You've got a week to live.
Suddenly someone comes in and stabs you in the chest with a knife.
What do you want marked as the cause of death?
That's right: Bleeding from knife wound
If you're dyING of something, but something else comes in, takes advantage of that, and kills you (you can't fight back against knife guy because of cancer and pneumonia) it's still the knife that killed you.
The cause of death is lack of air caused by chest compression, even if his conditions make that easier.