A sane person who, due to mental disorder, when committing the crime could not entirely understand the actual nature of one’s action (inaction) and its social danger, or control one’s actions, is subject to criminal liability.
Limited sanity is taken into account as a mitigating circumstance when imposing the punishment and can become the ground for the enforcement of medical measures, parallel to the punishment.