The error is with slip issuers in that hey don’t stick to one format, nor do they calculate box 20 unless you ask them to.
ACB box 20 is not calculable from box 21, they are separate items.
The equation to be solved is this:
(Net Proceeds of Disposition)- (ACB of assets disposed of) = Capital Gain/Loss
Net Proceeds will be box 21 less any costs incurred in selling the assets .
ACB is the original cost, with adjustments for any subsequent purchases or return of capital.
See CRA Guide to Mutual Funds forexamples of ACB calculation.