Income Tax Act — I-3.3 80
 (or, where the debtor is non-resident at the end of the year, taxable Canadian property), equal to the lesser of (i) the remaining unapplied portion of the forgiven amount at that time in respect of the obligation, and (ii) the amount, if any, by which the total of (A) all of the debtor’s capital losses from the dispositions of properties (other than listed personal properties and excluded properties), and (B) twice the amount that would, because of subsection 88(1.2), be deductible under paragraph 111(1)(b) in computing the debtor’s taxable income for the year, if the debtor had sufficient income and taxable capital gains for the year, exceeds the total of (C) all of the debtor’s capital gains for the year from the dispositions of such properties (determined without reference to this subsection), and (D) all amounts each of which is an amount deemed by this subsection to be a capital gain of the debtor for the year as a consequence of the application of this subsection to other commercial obligations settled before that time; and (b) the forgiven amount at that time in respect of the obligation shall be considered to have been applied under this subsection to the extent of the amount deemed by this subsection to be a capital gain of the debtor for the year as a consequence of the application of this subsection to the settlement of the obligation at that time. Income inclusion (13) Where a commercial obligation issued by a debtor is settled at any time in a taxation year, there shall be added, in computing the debtor’s income for the year from the source in connection with which the obligation was issued, the amount determined by the formula (A + B - C - D) × E where A is the remaining unapplied portion of the forgiven amount at that time in respect of the obligation, B is the lesser of (a) the total of all amounts designated under subsection 80(11) by the debtor in respect of the settlement of the obligation at that time, and (b) the residual balance at that time in respect of the settlement of the obligation, C is the total of all amounts each of which is an amount specified in an agreement filed under section 80.04 in respect of the settlement of the obligation at that time, D is (a) if the debtor has designated amounts under subsections (5), (8), (9) and (10) to the maximum extent permitted in respect of the settlement, the amount, if any, by which (i) the total of all amounts each of which is an unrecognized loss at that time, in respect of the obligation, from the disposition of a property exceeds (ii) twice the total of all amounts each of which is an amount by which the amount determined before that time under this subsection in respect of a settlement of an obligation issued by the debtor has been reduced because of an amount determined under this paragraph, and (b) in any other case, nil, and E is (a) where the debtor is a partnership, 1, and (b) in any other case, 1/2. Residual balance (14) For the purpose of subsection 80(13), the residual balance at any time in a taxation year in respect of the settlement of a particular commercial obligation issued by a debtor is the amount, if any, by which (a) the gross tax attributes of directed persons at that time in respect of the debtor exceeds the total of (b) the value of A in subsection 80(13) in respect of the settlement of the particular obligation at that time, (c) all amounts each of which is (i) the amount, if any, by which the value of A in subsection 80(13) in respect of a settlement before that time and in the year of a commercial obligation issued by the debtor exceeds the value of C in that subsection in respect of the settlement, (ii) the value of A in subsection 80(13) in respect of a settlement of a commercial obligation that is deemed by paragraph 80.04(4)(e) to have been issued by a directed person in respect of the debtor because of the filing of an agreement under section 80.04 in respect of a settlement before that time and in the year of a commercial