@classytic/ca-tax 0.0.15 → 0.0.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index3.d.mts CHANGED
@@ -289,6 +289,15 @@ interface LossCarrybackYear {
289
289
  /** The prior tax year the loss is applied to (ISO date of its year-end). */
290
290
  taxYearEnd: string;
291
291
  amount: number;
292
+ /**
293
+ * Net-capital pools only, and only where it differs from the schedule-wide
294
+ * default: the inclusion rate of the year the loss is APPLIED to, not of the
295
+ * year the loss arose. ¾ before 2000-02-28, ⅔ from then to 2000-10-17, ½
296
+ * after — so a three-year carry-back reaching across those dates carries
297
+ * three different rates, which is why this sits per-year and not per-pool.
298
+ * AT1 Schedule 10 transmits it on 043/045/047 to six decimals.
299
+ */
300
+ inclusionRate?: number;
292
301
  }
293
302
  interface LossCarrybackInput {
294
303
  /** The loss created in the current year (non-capital or net-capital). */
@@ -880,7 +889,7 @@ type Schedule8Entry = {
880
889
  method: 'limited-life';
881
890
  class: Class14Input;
882
891
  };
883
- interface Schedule8Result$1 {
892
+ interface Schedule8Result {
884
893
  decliningBalance: CcaClassResult[];
885
894
  leasehold: Class13Result[];
886
895
  limitedLife: Class14Result[];
@@ -906,9 +915,9 @@ interface Schedule8Result$1 {
906
915
  * proceeds reach its capital cost, and the class caps at its own undepreciated
907
916
  * capital cost — so neither produces a recapture inclusion here.
908
917
  */
909
- declare function computeSchedule8$1(entries: readonly Schedule8Entry[], rates?: CcaRateTable, /** Short-tax-year proration (days ÷ 365) for the declining-balance rows. */
918
+ declare function computeSchedule8(entries: readonly Schedule8Entry[], rates?: CcaRateTable, /** Short-tax-year proration (days ÷ 365) for the declining-balance rows. */
910
919
 
911
- prorationFactor?: number): Schedule8Result$1;
920
+ prorationFactor?: number): Schedule8Result;
912
921
  //#endregion
913
922
  //#region src/t2/at1/schedules/schedule13-cca.d.ts
914
923
  /**
@@ -1687,6 +1696,86 @@ interface LimitedPartnershipLossesResult {
1687
1696
  }
1688
1697
  declare function computeLimitedPartnershipLosses(rows: readonly LimitedPartnershipLossRow[]): LimitedPartnershipLossesResult;
1689
1698
  //#endregion
1699
+ //#region src/t2/at1/schedules/schedule21-rife.d.ts
1700
+ /**
1701
+ * AT1 Schedule 21, page 5 — Continuity of Restricted Interest and Financing
1702
+ * Expenses (RIFE), lines 200-250 and 310-350.
1703
+ *
1704
+ * `schedule21-year-of-origin.ts`'s own doc comment documents that this
1705
+ * section is not part of the NetFile transmission schema (no `021200`
1706
+ * through `021350` field exists anywhere in the spec) — that is still true,
1707
+ * and this module does not emit anything into `schedule21Values`. What
1708
+ * changed: line 240 ("RIFE deducted for the tax year") is printed with its
1709
+ * own instruction — "Enter amount on line 130 of the Schedule 12" — and AT1
1710
+ * Schedule 12 line 130 ("Restricted interest and financing expenses") IS a
1711
+ * real filed line (`schedule12.ts`'s own note: "If Schedule 21 exists,
1712
+ * Alberta = 021240; otherwise Alberta = federal"). So this schedule's own
1713
+ * detail stays paper/UI-only, while this module's `deducted` output is a
1714
+ * genuine input to Schedule 12's reconciliation.
1715
+ *
1716
+ * Two blocks, read top to bottom exactly as printed:
1717
+ *
1718
+ * Block 1 — the RIFE balance itself:
1719
+ * 250 (closing) = 200 (opening) + 210 (wind-up transfer)
1720
+ * − 220 (acquisition-of-control adjustment)
1721
+ * + 230 (current-year RIFE) − 240 (deducted)
1722
+ *
1723
+ * Block 2 — the cap line 240 must not exceed:
1724
+ * 310 = 200 + 210 − 220
1725
+ * 340 = 320 (excess capacity) + 330 (received capacity)
1726
+ * 350 = the LESSER of 310 and 340 — this is line 240's ceiling
1727
+ *
1728
+ * Lines 230/320/330 are themselves sourced from other forms this engine does
1729
+ * not yet compute — 230 from T2 Schedule 4 line 710 (Schedule 4's own RIFE
1730
+ * pool is input-only in this engine — see `schedule4.ts`'s Part 8 doc
1731
+ * comment), 320/330 from T2 Schedule 130 lines 129/130 (the federal EIFEL
1732
+ * limitation module, `eifel-limitation.ts`, explicitly does not compute
1733
+ * Parts 2G/2H/2I — see that module's own doc comment). All three stay plain
1734
+ * preparer entries here until that federal work lands; once it does, they
1735
+ * become carried-in rather than typed.
1736
+ *
1737
+ * Whole dollars, pure.
1738
+ */
1739
+ interface RifeContinuityInput {
1740
+ /** 200 — RIFE at the end of the previous tax year. */
1741
+ openingBalance?: number;
1742
+ /** 210 — transferred on an amalgamation or wind-up of a subsidiary. */
1743
+ transferredOnWindUp?: number;
1744
+ /** 220 — deducted: adjustment for an acquisition of control. */
1745
+ acquisitionOfControlAdjustment?: number;
1746
+ /** 230 — current-year RIFE under ITA subsection 111(8) (T2 Schedule 4 line 710). */
1747
+ currentYearRife?: number;
1748
+ /** 320 — corporation's excess capacity for the year (T2 Schedule 130 line 129). */
1749
+ excessCapacity?: number;
1750
+ /** 330 — total received capacity for the year (T2 Schedule 130 line 130). */
1751
+ receivedCapacity?: number;
1752
+ /**
1753
+ * 240 — RIFE deducted for the tax year, discretionary. Must not exceed 350;
1754
+ * omit to claim the maximum available (350) automatically.
1755
+ */
1756
+ deductedClaim?: number;
1757
+ }
1758
+ interface RifeContinuityResult {
1759
+ openingBalance: number;
1760
+ transferredOnWindUp: number;
1761
+ acquisitionOfControlAdjustment: number;
1762
+ currentYearRife: number;
1763
+ /** 310 — RIFE from previous tax years: 200 + 210 − 220. */
1764
+ rifeFromPreviousYears: number;
1765
+ excessCapacity: number;
1766
+ receivedCapacity: number;
1767
+ /** 340 — 320 + 330. */
1768
+ totalCapacity: number;
1769
+ /** 350 — the lesser of 310 and 340; line 240's ceiling. */
1770
+ maxDeductible: number;
1771
+ /** 240 — the lesser of the requested claim and 350. */
1772
+ deducted: number;
1773
+ /** 250 — 200 + 210 − 220 + 230 − 240. */
1774
+ closingBalance: number;
1775
+ issues: string[];
1776
+ }
1777
+ declare function computeRifeContinuity(input?: RifeContinuityInput): RifeContinuityResult;
1778
+ //#endregion
1690
1779
  //#region src/t2/at1/schedules/schedule21-year-of-origin.d.ts
1691
1780
  /**
1692
1781
  * AT1 Schedule 21 — Analysis of Losses by Year of Origin.
@@ -1717,11 +1806,12 @@ declare function computeLimitedPartnershipLosses(rows: readonly LimitedPartnersh
1717
1806
  *
1718
1807
  * `Continuity of Restricted Interest and Financing Expenses` (RIFE, page 5
1719
1808
  * of the same PDF, lines 200-250/310-350) is the live form's NINTH section
1720
- * and is deliberately NOT modelled here: an exhaustive search of the entire
1721
- * NetFile transmission spec (§3.2.3.1 through the schedule index) turns up
1722
- * no `021200`-`021350` field anywhere it is not part of the electronic
1723
- * filing schema this engine targets, only the paper form. Flagged, not
1724
- * silently dropped.
1809
+ * and is deliberately NOT modelled HERE it lives in its own
1810
+ * `schedule21-rife.ts` instead, same as limited partnership losses got its
1811
+ * own file. That module's doc comment covers why RIFE's own lines still
1812
+ * never appear on the wire (an exhaustive search of the entire NetFile
1813
+ * transmission spec turns up no `021200`-`021350` field anywhere) even
1814
+ * though its final figure now feeds a real filed line elsewhere.
1725
1815
  *
1726
1816
  * Whole dollars, pure.
1727
1817
  */
@@ -2336,11 +2426,6 @@ interface At1ScheduleData {
2336
2426
  scheduleId: string;
2337
2427
  values: At1ScheduleValue[];
2338
2428
  }
2339
- /**
2340
- * Schedules the engine computes but cannot yet file, because their line numbers
2341
- * have not been transcribed from the specification. Named so the difference
2342
- * between "no data" and "not implemented" is visible rather than silent.
2343
- */
2344
2429
  /**
2345
2430
  * Schedules this module can put into a filing payload. Exported so callers and
2346
2431
  * tests share one source of truth — a hard-coded copy in a test drifts the moment
@@ -2577,6 +2662,18 @@ interface Schedule12FilingInput {
2577
2662
  federal: number;
2578
2663
  };
2579
2664
  };
2665
+ /**
2666
+ * 012130 / 012131 — restricted interest and financing expenses (the EIFEL
2667
+ * denial, ITA s.18.2). Same always-both-sides mandatory disclosure as
2668
+ * `lossDeductions`/`donations` above, per the spec: "if Schedule 21
2669
+ * exists, Alberta = 021240; otherwise Alberta = federal." Federal stays 0
2670
+ * until the federal EIFEL limitation engine computes the s.111(1)(a.1)
2671
+ * deduction (T2 line 336) — not yet wired into `computeFederalT2`.
2672
+ */
2673
+ restrictedInterestAndFinancing?: {
2674
+ alberta: number;
2675
+ federal: number;
2676
+ };
2580
2677
  }
2581
2678
  /**
2582
2679
  * The Schedule 21 → Schedule 12 carry-forwards, as the form states them beside
@@ -2654,12 +2751,21 @@ interface Schedule21FilingInput {
2654
2751
  * schedule object — the payload has one `021` block, not two.
2655
2752
  */
2656
2753
  limitedPartnershipLosses?: LimitedPartnershipLossesResult;
2754
+ /**
2755
+ * The NINTH section (page 5) — Continuity of Restricted Interest and
2756
+ * Financing Expenses. NOT part of the NetFile schema (see
2757
+ * `schedule21-rife.ts`'s own doc comment) — `schedule21Values` below does
2758
+ * not emit anything for it. Kept here only so `scheduleTwelve`'s Alberta
2759
+ * line 130 reconciliation (`AT1SCH12` line 130, "Restricted interest and
2760
+ * financing expenses") can read `.deducted`.
2761
+ */
2762
+ rife?: RifeContinuityResult;
2657
2763
  /** The SEVENTH section — analysis of non-capital losses by year of origin (151-169), 21 occurrences. */
2658
2764
  nonCapitalByYearOfOrigin?: NonCapitalLossByYearOfOriginResult;
2659
2765
  /** The EIGHTH section — farm/restricted-farm/LPP by year of origin (181-187), 21 occurrences. */
2660
2766
  otherLossesByYearOfOrigin?: OtherLossByYearOfOriginResult;
2661
2767
  }
2662
- declare function schedule21Values(input: Schedule21FilingInput): At1ScheduleData;
2768
+ declare function schedule21Values$1(input: Schedule21FilingInput): At1ScheduleData;
2663
2769
  /**
2664
2770
  * Field ids read off the live form:
2665
2771
  *
@@ -2702,7 +2808,7 @@ interface Schedule1FilingInput {
2702
2808
  /** Area A — 041/043/045, one occurrence per associated corp, claimant first. */
2703
2809
  agreementMembers?: Schedule1AgreementMember[];
2704
2810
  }
2705
- declare function schedule1Values(input: Schedule1FilingInput): At1ScheduleData;
2811
+ declare function schedule1Values$1(input: Schedule1FilingInput): At1ScheduleData;
2706
2812
  /**
2707
2813
  * Area A, the general allocation formula (ITA Reg 402). Four inputs, all taken
2708
2814
  * from the federal Schedule 5:
@@ -2721,7 +2827,7 @@ interface Schedule2FilingInput {
2721
2827
  albertaRevenue?: number;
2722
2828
  totalRevenue?: number;
2723
2829
  }
2724
- declare function schedule2Values(input: Schedule2FilingInput): At1ScheduleData;
2830
+ declare function schedule2Values$1(input: Schedule2FilingInput): At1ScheduleData;
2725
2831
  /**
2726
2832
  * Four loss types are modelled, each with its own column on the form:
2727
2833
  *
@@ -3056,13 +3162,13 @@ declare function computeSchedule3(input: Schedule3Input): Schedule3Result;
3056
3162
  * file rather than the shared filing module per the task instructions — other
3057
3163
  * agents are editing `at1-schedule-line-items.ts` concurrently.
3058
3164
  */
3059
- interface At1ScheduleValueLike$5 {
3165
+ interface At1ScheduleValueLike$1 {
3060
3166
  lineItemId: string;
3061
3167
  value: string | number;
3062
3168
  }
3063
- interface At1ScheduleDataLike$5 {
3169
+ interface At1ScheduleDataLike$1 {
3064
3170
  scheduleId: string;
3065
- values: At1ScheduleValueLike$5[];
3171
+ values: At1ScheduleValueLike$1[];
3066
3172
  }
3067
3173
  /**
3068
3174
  * Field ids per the spec transcription above: 100-108 (ITC), 200-208 (CITC),
@@ -3072,7 +3178,7 @@ interface At1ScheduleDataLike$5 {
3072
3178
  * per-vintage figures this DOES compute (304/306/308/310) are filed on the
3073
3179
  * 300-series rollup, not re-emitted as an AAPITC occurrence table.
3074
3180
  */
3075
- declare function schedule3Values(result: Schedule3Result): At1ScheduleDataLike$5;
3181
+ declare function schedule3Values(result: Schedule3Result): At1ScheduleDataLike$1;
3076
3182
  //#endregion
3077
3183
  //#region src/t2/at1/schedules/schedule4-foreign-investment-tax-credit.d.ts
3078
3184
  /**
@@ -3203,1167 +3309,6 @@ declare function computeSchedule4(input: Schedule4Input$1): Schedule4Result$1;
3203
3309
  */
3204
3310
  declare function schedule4Values(result: Schedule4Result$1): At1ScheduleData;
3205
3311
  //#endregion
3206
- //#region src/t2/at1/schedules/schedule5-royalty-tax-deduction.d.ts
3207
- /**
3208
- * Alberta AT1 Schedule 5 — Alberta Royalty Tax Deduction.
3209
- *
3210
- * TRA spec §3.2.3.6 (Chapter 3, lines 5083-6291). The Alberta Royalty Tax
3211
- * Deduction (RTD) shelters "Attributed Canadian Royalty Income" — Crown
3212
- * charges net of the resource allowance and reimbursements — against Alberta
3213
- * taxable income. Form 005 (this schedule) is required whenever the
3214
- * corporation has Attributed Canadian Royalty Income, and **Form 007 (AT1
3215
- * Schedule 7 — Royalty Tax Credit/Deduction Supplemental Information) must be
3216
- * completed before Form 005** (line 5133-5138): "IF FORM 007 IS NOT INCLUDED
3217
- * WITH FORMS 005 AND/OR 006, THEN THE CLIENT'S RTC ENTITLEMENT WILL BE
3218
- * DISALLOWED."
3219
- *
3220
- * ── Structure ────────────────────────────────────────────────────────────
3221
- *
3222
- * The schedule has two independent pool systems that both feed AT1 core line
3223
- * 064 (Royalty Tax Deduction):
3224
- *
3225
- * 1. **CRTD** ("Calculation of the Royalty Tax Deduction", 005001-005027) —
3226
- * the corporation's OWN unsuccessored royalty pool. A single running
3227
- * pool with a discretionary claim (line 016), capped by what remains
3228
- * available.
3229
- * 2. **Successored pools** (Area C/D, 005101-005140) — per-vendor pools
3230
- * acquired on a change in control or the acquisition of substantially
3231
- * all Canadian resource properties, split into "second successored"
3232
- * (SSPI, 005101-005115) and "first successored" (FSPI, 005121-005135)
3233
- * generations. Unlike the CRTD, each occurrence's claim is MANDATORY
3234
- * arithmetic (marked "M" in the spec), not discretionary: it is exactly
3235
- * `min(pool base, property income)`.
3236
- *
3237
- * AT1 core line 064 = `005016 + 005140`, capped at AT1 core line 062 (Alberta
3238
- * Taxable Income before the deduction). This engine cannot see line 062 (it
3239
- * belongs to the AT1 jacket, not this schedule) so it is accepted as a plain
3240
- * numeric input, `albertaTaxableIncomeBeforeDeduction`.
3241
- *
3242
- * ── Cross-references accepted as plain inputs (NOT re-derived here) ────────
3243
- *
3244
- * • **005001** (Crown charges, line 001) is "the amount from [AT1] Schedule
3245
- * 7, line 061" — a nine-term sum over Schedule 7's own Crown-payment,
3246
- * partnership-share and prior-year-adjustment sections (007003 + 007005 +
3247
- * 007007 + 007009 + 007011 + 007013 + 007017 + 007025 + 007029 + Σ007077
3248
- * + Σ007079 + Σ007081 − 007051). AT1 Schedule 7 is a separate schedule
3249
- * with its own filing requirement (see above) built independently of this
3250
- * module. This engine accepts the finished Schedule 7 line 061 figure —
3251
- * `crownChargesNetOfReimbursements` — and applies only the final "if
3252
- * negative, default to zero" step that line 001 itself specifies.
3253
- * • **005005** (resource allowance, line 005): "Value = 012024 if it
3254
- * exists, otherwise default to fed 001346." AT1 Schedule 12
3255
- * (income/loss reconciliation) and federal Schedule 1 are both external
3256
- * to this module; the two candidate figures are accepted as plain inputs
3257
- * and this schedule applies only the stated precedence.
3258
- *
3259
- * ── A literal-spec asymmetry worth flagging (not "fixed") ──────────────────
3260
- *
3261
- * Line 013 (the pool available before the current year's claim, used to
3262
- * build lines 016 and 017) is `005001 − 005005 − 005007 + 005011` — it nets
3263
- * out **reimbursements (005007)**. Line 025 (the Attributed Royalty Income
3264
- * carried forward to NEXT year) is defined by the spec as `005001 − 005005 +
3265
- * 005011 − 000064 − 005023` (or, when `005001 − 005005 < 0`, `005011 − 000064
3266
- * − 005023`) — with **no 005007 term at all**. That is exactly what TRA's
3267
- * EFILE business rule states (lines 5379-5386 of the spec); this module
3268
- * implements it literally rather than assuming the omission is a transcription
3269
- * error and "fixing" it to match line 013's shape.
3270
- *
3271
- * Also note line 025 subtracts **000064**, the COMBINED royalty tax deduction
3272
- * (CRTD claim + successored total, capped at Alberta taxable income) — not
3273
- * just the CRTD's own claim (005016). That is likewise the literal EFILE
3274
- * mapping, not a simplification made here.
3275
- *
3276
- * Whole dollars, pure.
3277
- */
3278
- /** One predecessor's transfer into the corporation's unsuccessored pool (Area B, 005031-005037). */
3279
- interface At1Schedule5PredecessorTransfer {
3280
- /** 005031 — predecessor's legal name. */
3281
- predecessorName: string;
3282
- /** 005033 — Alberta Corporate Account Number, if the predecessor was Alberta-registered. */
3283
- albertaCorporateAccountNumber?: string;
3284
- /** 005035 — date of the transfer event (ISO `YYYY-MM-DD`), within the corporation's taxation year. */
3285
- dateOfEvent: string;
3286
- /** 005037 — carry-forward amount transferred to this corporation. */
3287
- amountTransferred: number;
3288
- }
3289
- /**
3290
- * One occurrence in a successored-pool section (SSPI 005101-005115 or FSPI
3291
- * 005121-005135). `poolBroughtForward` and `acquisitionAmount` are mutually
3292
- * exclusive per the spec ("only one field can exist" for 105/107 and for
3293
- * 125/127) — supply exactly one.
3294
- */
3295
- interface At1Schedule5SuccessoredPoolEntry {
3296
- /** 005101 / 005121 — legal name of the vendor, predecessor, or the corporation itself on a change in control. */
3297
- vendorName: string;
3298
- /** 005103 / 005123 — date of the event (ISO `YYYY-MM-DD`), oldest to newest across occurrences. */
3299
- dateOfEvent: string;
3300
- /**
3301
- * 005105 / 005125 — pool amount available for carry-forward at the end of
3302
- * the preceding year (continuing an existing successored pool). Mutually
3303
- * exclusive with `acquisitionAmount` for the same occurrence.
3304
- */
3305
- poolBroughtForward?: number;
3306
- /**
3307
- * 005107 / 005127 — cost on acquisition of all/substantially all Canadian
3308
- * resource properties, or on a change in control, under s.20(8) or 20(14)
3309
- * (a NEW successored pool this year). Mutually exclusive with
3310
- * `poolBroughtForward` for the same occurrence.
3311
- */
3312
- acquisitionAmount?: number;
3313
- /** 005109 / 005129 — property income under s.20(1)(c). A loss (negative) is treated as nil. */
3314
- propertyIncome: number;
3315
- }
3316
- /** Result for one successored-pool occurrence (005111/005113 or 005131/005133). */
3317
- interface At1Schedule5SuccessoredPoolEntryResult {
3318
- vendorName: string;
3319
- dateOfEvent: string;
3320
- /** (105 or 107) / (125 or 127) — the pool base for this occurrence. */
3321
- base: number;
3322
- /**
3323
- * Which mutually-exclusive field `base` came from — 105/125 for
3324
- * `'broughtForward'`, 107/127 for `'acquired'`, or `'unspecified'` when
3325
- * neither was supplied (base is nil; see the `issues` entry for the
3326
- * occurrence). Drives which line `schedule5Values` files `base` under.
3327
- */
3328
- baseKind: 'broughtForward' | 'acquired' | 'unspecified';
3329
- /** Property income, floored at zero. */
3330
- propertyIncome: number;
3331
- /** 005111 / 005131 — mandatory arithmetic: min(base, propertyIncome). */
3332
- claim: number;
3333
- /** 005113 / 005133 — base minus claim. */
3334
- carryForwardBeforeTransfer: number;
3335
- }
3336
- /** 005026/005027 — whether the resource pools were transferred during the year. */
3337
- interface At1Schedule5PoolTransfer {
3338
- /**
3339
- * 005026 — 1: transfer due to disposition of all/substantially all Canadian
3340
- * resource properties (s.20(8)); 2: transfer due to a change in control or
3341
- * ceasing to be exempt under s.20(14); 3: no transfer occurred.
3342
- */
3343
- type: 1 | 2 | 3;
3344
- /** 005027 — legal name of the acquiring corporation. Required when `type` is 1 or 2; must be absent when 3. */
3345
- acquirerName?: string;
3346
- }
3347
- interface AlbertaSchedule5Input {
3348
- /**
3349
- * 005001 — Crown charges under s.20(6)(a)-(e), with reference to s.20(13):
3350
- * AT1 Schedule 7, line 061. See the module docstring — this is Schedule 7's
3351
- * finished output, not re-derived here. Floored at zero per the spec's
3352
- * final step on line 001.
3353
- */
3354
- crownChargesNetOfReimbursements?: number;
3355
- /**
3356
- * 005005 — resource allowance claimed under s.20(6)(g). Prefer
3357
- * `albertaResourceAllowance` (AT1 Schedule 12, line 024); falls back to
3358
- * `federalResourceAllowance` (federal Schedule 1, line 346) when absent,
3359
- * per the spec's stated precedence.
3360
- */
3361
- albertaResourceAllowance?: number;
3362
- /** 005005 fallback — federal Schedule 1, line 346. Used only when `albertaResourceAllowance` is not supplied. */
3363
- federalResourceAllowance?: number;
3364
- /**
3365
- * 005007 — reimbursements received under a contract in respect of amounts
3366
- * on line 001, under s.20(6)(f). Must not already be netted into
3367
- * `crownChargesNetOfReimbursements`. Excludes ARTC and other government
3368
- * rebates or credits (per the spec note).
3369
- */
3370
- reimbursementsForCrownCharges?: number;
3371
- /** 005043 — corporation's own unsuccessored pool C/F from the preceding year (normally last year's 005017; enter manually if unavailable). */
3372
- openingUnsuccessoredPoolBalance?: number;
3373
- /** 005031-005037 — predecessor transfers into the unsuccessored pool (amalgamation under s.20(10), or wind-up of a wholly-owned subsidiary under s.20(11)). */
3374
- predecessorTransfers?: readonly At1Schedule5PredecessorTransfer[];
3375
- /**
3376
- * 005016 — the CRTD claim actually made against the unsuccessored pool.
3377
- * Discretionary (spec marks it "X", not "M"): omit to claim the maximum
3378
- * available (lesser of the pool balance and remaining Alberta taxable
3379
- * income capacity).
3380
- */
3381
- crtdAmountClaimed?: number;
3382
- /** 005023 — Attributed Royalty Income transferred to another corporation during the year on disposal of substantially all Canadian resource properties. */
3383
- transferredOnDisposal?: number;
3384
- /** 005200 — whether the corporation has any successored pools to report. When false, `secondSuccessoredPools`/`firstSuccessoredPools` must be empty (spec: 005101-005140 "must not exist"). */
3385
- hasSuccessoredPools?: boolean;
3386
- /** SSPI, 005101-005115 — second successored pool occurrences, oldest date of event first. */
3387
- secondSuccessoredPools?: readonly At1Schedule5SuccessoredPoolEntry[];
3388
- /** FSPI, 005121-005135 — first successored pool occurrences, oldest date of event first. */
3389
- firstSuccessoredPools?: readonly At1Schedule5SuccessoredPoolEntry[];
3390
- /** 005026/005027 — pool transfer during the year, if any. */
3391
- poolTransfer?: At1Schedule5PoolTransfer;
3392
- /**
3393
- * 005100 — was there a change in control that created the immediately
3394
- * preceding taxation year end? Informational; cross-checked against the
3395
- * AT1 core fields below when both are supplied.
3396
- */
3397
- changeInControlEndedPrecedingYear?: boolean;
3398
- /** AT1 core 000038 — tax year end changed since the last return filed. For the 005100 cross-check only. */
3399
- at1TaxYearEndChanged?: boolean;
3400
- /** AT1 core 000039 — reason for the tax year end change (2 = change in control). For the 005100 cross-check only. */
3401
- at1TaxYearEndChangeReason?: 1 | 2 | 3;
3402
- /**
3403
- * AT1 core 000062 — Alberta Taxable Income (Loss) before this deduction.
3404
- * Owned by the AT1 jacket, not this schedule; caps both the CRTD claim
3405
- * (line 016) and the combined total (line 064).
3406
- */
3407
- albertaTaxableIncomeBeforeDeduction?: number;
3408
- }
3409
- interface AlbertaSchedule5Result {
3410
- /** 005001, floored at zero. */
3411
- crownCharges: number;
3412
- /** 005005. */
3413
- resourceAllowance: number;
3414
- /** 005007. */
3415
- reimbursements: number;
3416
- /** Sum of 005037 across predecessor transfers. */
3417
- predecessorTransfersTotal: number;
3418
- /** 005011 = 005043 + Σ005037. */
3419
- attributedRoyaltyIncomeCarryForwardIn: number;
3420
- /** Line 013 (unlabeled internal subtotal) = 005001 − 005005 − 005007 + 005011. */
3421
- unsuccessoredPoolAvailable: number;
3422
- /** The maximum line 016 could claim: max(0, min(unsuccessoredPoolAvailable, 000062 − 005140)). */
3423
- crtdMaxClaimable: number;
3424
- /** 005016 — the CRTD claim actually made. */
3425
- crtdClaim: number;
3426
- /** 005017 = unsuccessoredPoolAvailable − crtdClaim. */
3427
- poolAvailableCarryForward: number;
3428
- /** 005023, passed through. */
3429
- transferredOnDisposal: number;
3430
- /** SSPI results, in input order. */
3431
- secondSuccessoredPools: At1Schedule5SuccessoredPoolEntryResult[];
3432
- /** FSPI results, in input order. */
3433
- firstSuccessoredPools: At1Schedule5SuccessoredPoolEntryResult[];
3434
- /** 005115 = Σ SSPI carryForwardBeforeTransfer. */
3435
- secondSuccessoredSubtotal: number;
3436
- /** 005135 = Σ FSPI carryForwardBeforeTransfer. */
3437
- firstSuccessoredSubtotal: number;
3438
- /** 005140 = Σ SSPI claims + Σ FSPI claims. */
3439
- successoredTotal: number;
3440
- /** AT1 core 000064 = min(005016 + 005140, 000062), floored at zero (see `issues` when this floor binds). */
3441
- totalRoyaltyTaxDeduction: number;
3442
- /** 005025, floored at zero. */
3443
- attributedRoyaltyIncomeCarryForwardOut: number;
3444
- /** 005026/005027, passed through from input for filing — see `schedule5Values`. */
3445
- poolTransfer?: At1Schedule5PoolTransfer;
3446
- /** 005100, passed through from input for filing — see `schedule5Values`. */
3447
- changeInControlEndedPrecedingYear?: boolean;
3448
- /** True once there is Attributed Canadian Royalty Income (per the spec, this is when Form 005 must be filed). */
3449
- formRequired: boolean;
3450
- issues: string[];
3451
- }
3452
- declare function computeAlbertaSchedule5(input: AlbertaSchedule5Input): AlbertaSchedule5Result;
3453
- /**
3454
- * `scheduleNNValues` for Schedule 5, following the `at1-schedule-line-items.ts`
3455
- * builder pattern (see `schedule17Values`, `schedule18Values`, and the sibling
3456
- * `schedule3Values` in `schedule3-other-deductions-credits.ts`). Kept in THIS
3457
- * file rather than the shared filing module per the task instructions — other
3458
- * agents are wiring their own schedules into `at1-schedule-line-items.ts`
3459
- * concurrently.
3460
- *
3461
- * Emits every line `AlbertaSchedule5Result` carries a value for:
3462
- * 005001, 005005, 005007, 005011, 005016, 005017, 005023, 005025, 005026,
3463
- * 005027, 005100, and the successored-pool occurrences 005101-005140.
3464
- *
3465
- * NOT emitted, because the result does not retain them distinctly:
3466
- * 005031-005043 (Area B predecessor-transfer detail and the opening pool
3467
- * balance) — the module aggregates both into 005011
3468
- * (`attributedRoyaltyIncomeCarryForwardIn`) and does not carry the
3469
- * per-predecessor breakdown or the raw opening balance forward into the
3470
- * result; and 005200, which gates whether the successored sections are
3471
- * processed at all but is not itself a filed dollar/detail line.
3472
- */
3473
- interface At1ScheduleValueLike$4 {
3474
- lineItemId: string;
3475
- value: string | number;
3476
- }
3477
- interface At1ScheduleDataLike$4 {
3478
- scheduleId: string;
3479
- values: At1ScheduleValueLike$4[];
3480
- }
3481
- declare function schedule5Values(result: AlbertaSchedule5Result): At1ScheduleDataLike$4;
3482
- //#endregion
3483
- //#region src/t2/at1/schedules/schedule6-royalty-tax-credit.d.ts
3484
- /**
3485
- * Alberta AT1 Schedule 6 — Alberta Royalty Tax Credit.
3486
- *
3487
- * TRA spec §3.2.3.7 (Chapter 3, lines 6292-6653). Required "If the corp, for
3488
- * the taxation year, has incurred Alberta Crown Royalty in respect of a
3489
- * royalty receivable by or payable to Alberta under a lease or licence
3490
- * granting petroleum rights, natural gas rights or petroleum and natural gas
3491
- * rights" (spec lines 6342-6361). Two filing preconditions worth carrying
3492
- * into any caller, neither of which this pure module can enforce itself:
3493
- * **AT1 Schedule 7 must be completed before Schedule 6** ("IF FORM 007 IS NOT
3494
- * INCLUDED WITH FORMS 005 AND/OR 006, THEN THE CLIENT'S RTC ENTITLEMENT WILL
3495
- * BE DISALLOWED" — spec lines 6710-6715), and the completed form "must be
3496
- * submitted to Treasury Board and Finance within three years of the taxation
3497
- * year end in which the Alberta Crown Royalty was incurred" (spec lines
3498
- * 6354-6360).
3499
- *
3500
- * ── The four fields this schedule's own MAPPINGS table actually defines ────
3501
- *
3502
- * 006002 ARTC Is the corp associated with one or more corporations that
3503
- * have incurred Alberta Crown Royalty in the year? 1 = Yes,
3504
- * default 2 = No. (spec lines 6363-6373)
3505
- * 006004 Alberta Crown Royalty incurred in the taxation year:
3506
- * 007003 + Σ007077 − Σ007087 + Σ007089. (spec lines 6375-6384)
3507
- * 006006 Crown Royalty Shelter — see below. (spec lines 6443-6448)
3508
- * 006008 Weighted Average Rate — see below. (spec lines 6450-6464)
3509
- *
3510
- * plus two sections that exist ONLY when 006002 = 1 (associated):
3511
- *
3512
- * ACRS (006022-006028) — the ASSOCIATED corporation with the longest
3513
- * taxation year: its Corporate Account Number, tax year dates, and
3514
- * the number of days in that year (max 365). (spec lines 6466-6558)
3515
- * AACRS (006030-006034) — the $2,000,000 shelter pool, sized by the
3516
- * longest associated year (006028), ALLOCATED among the associated
3517
- * group. Sort such that the FIRST occurrence (006030001) is the
3518
- * corporation filing this return — 006006 (this filer's own
3519
- * shelter) then equals 006034001 exactly. Each allocation, and the
3520
- * sum of all allocations, is capped at $2,000,000 ×
3521
- * (006028 / 365). (spec lines 6559-6652)
3522
- *
3523
- * ── 006004 is accepted as a plain input, not re-derived here ───────────────
3524
- *
3525
- * Every term of 006004's formula (007003, 007077, 007087, 007089) lives on
3526
- * AT1 Schedule 7, which this package also implements
3527
- * (`schedule7-royalty-supplemental.ts`). Rather than re-import Schedule 7's
3528
- * internals here, `albertaCrownRoyaltyIncurred` is taken as a plain numeric
3529
- * input — pass `computeAlbertaSchedule7(...).albertaCrownRoyaltyForSchedule6`,
3530
- * which computes that exact formula. This mirrors how AT1 Schedule 20 takes
3531
- * its Schedule 12 income ceiling as a plain input rather than importing
3532
- * Schedule 12: the two schedules stay independently testable, and the wiring
3533
- * between them is the caller's job (`alberta-return.ts`), not this module's.
3534
- *
3535
- * ── 006006 Crown Royalty Shelter — two mutually exclusive paths ────────────
3536
- *
3537
- * associated (006002 = 1): 006006 = 006034001 (this filer's own
3538
- * allocation from the AACRS pool below)
3539
- * not associated (006002 = 2): 006006 = $2,000,000 × (days in this corp's
3540
- * own taxation year, max 365) / 365
3541
- *
3542
- * ── 006008 Weighted Average Rate — an EXTERNAL rate table, not computed ─────
3543
- *
3544
- * "For each calendar quarter that the taxation year spans, enter the sum of
3545
- * the number of days in the taxation year that fall within the calendar
3546
- * quarter / total number of days in the taxation year X RTC quarterly rate
3547
- * ... Note that the rate can be found on website:
3548
- * http://www.finance.alberta.ca/publications/tax_rebates/rates/rtc1.html"
3549
- * (spec lines 6450-6464). The RTC quarterly rate itself is a published
3550
- * external figure this engine has no source for; `quarters` therefore takes
3551
- * BOTH the day-count weight and the already-looked-up rate per quarter, and
3552
- * this module only does the weighting arithmetic the spec states, to 4
3553
- * decimal places (e.g. `.7500`, `.6667`).
3554
- *
3555
- * ── CONFIRMED: there is no "credit" dollar amount to compute here ──────────
3556
- *
3557
- * The transcribed range for this schedule (spec lines 6292-6653) ends after
3558
- * 006034 with no field that multiplies the weighted average rate (006008) by
3559
- * the royalty incurred (006004) or the shelter (006006) into a claimable
3560
- * credit — and this is not a transcription gap. Traced through the AT1
3561
- * jacket's own MAPPINGS (spec §3.2.3.1): the balance-owing reconciliation is
3562
- * `090 = 080 − (081 + 082 + 085 + 086 + 087)`, where 080 is Alberta Tax
3563
- * Payable, 081 is the SR&ED credit (form 009), 082 is "Instalments and other
3564
- * payments **and ARTC instalments** credited to income tax account for this
3565
- * taxation year" — a single, plain, preparer-entered figure — and 086/087 are
3566
- * the capital gains refund and other credits. No line in that sequence reads
3567
- * "if form 006 exists, value = ...", unlike every other schedule's credit
3568
- * (see 072 = form 004, 074 = form 008, 081 = form 009).
3569
- *
3570
- * The Alberta Royalty Tax Credit is administered as an INSTALMENT PROGRAM,
3571
- * not an annual claimed credit: TRA pays or credits ARTC instalments to the
3572
- * corporation during the year based on estimated entitlement, and the
3573
- * corporation simply reports what it already received at line 082 (already
3574
- * collected in this app's shared "Payments & Instalments" schedule) — it
3575
- * does not compute a fresh credit from Schedule 6/7's own figures on this
3576
- * return. Schedule 6/7 exist to establish the royalty amount, shelter and
3577
- * rate TRA uses to determine those instalments (and to support TRA's own
3578
- * assessment), not to produce a number the corporation deducts here. So this
3579
- * module correctly stops at the three components (006004, 006006, 006008)
3580
- * — that is the schedule's whole job.
3581
- *
3582
- * Whole dollars, pure.
3583
- */
3584
- /** ACRS (006022-006028) — the associated corporation with the longest taxation year. */
3585
- interface RoyaltyTaxCreditLongestAssociatedYear {
3586
- /** 006022 — Alberta Corporate Account Number of that corporation. */
3587
- albertaCan?: string;
3588
- /** 006024 — that corporation's taxation year beginning, ISO `YYYY-MM-DD`. */
3589
- taxationYearBeginning?: string;
3590
- /** 006026 — that corporation's taxation year ending, ISO `YYYY-MM-DD`. */
3591
- taxationYearEnding?: string;
3592
- /** 006028 — number of days in that taxation year, capped at 365 on the form. */
3593
- days: number;
3594
- }
3595
- /** One row of the AACRS allocation table (006030-006034). */
3596
- interface RoyaltyTaxCreditShelterAllocation {
3597
- /** 006030 — name of the corporation. Sort so the FIRST row is the corporation filing this return. */
3598
- name: string;
3599
- /** 006032 — Alberta Corporate Account Number, if this row is not the filer. */
3600
- albertaCan?: string;
3601
- /** 006034 — amount of the $2,000,000 shelter pool allocated to this corporation. */
3602
- allocatedAmount: number;
3603
- }
3604
- /** One resolved allocation row, after the per-row and aggregate caps are applied. */
3605
- interface RoyaltyTaxCreditShelterAllocationResult {
3606
- name: string;
3607
- albertaCan?: string;
3608
- /** 006034, capped at the pool per row. See `AlbertaSchedule6Result.issues` if capping occurred. */
3609
- allocatedAmount: number;
3610
- /** What was actually requested before capping, for the audit trail. */
3611
- requestedAmount: number;
3612
- }
3613
- /** One quarter the taxation year spans, for the 006008 weighted-average-rate calculation. */
3614
- interface RoyaltyTaxCreditQuarter {
3615
- /** Number of days in the taxation year that fall within this calendar quarter. */
3616
- days: number;
3617
- /** The published RTC quarterly rate for this calendar quarter, as a decimal (e.g. 0.0473). */
3618
- rate: number;
3619
- }
3620
- interface AlbertaSchedule6Input {
3621
- /** 006002 — is the corp associated with one or more corporations that incurred Alberta Crown Royalty in the year? Defaults to No. */
3622
- associatedWithCrownRoyaltyCorporations?: boolean;
3623
- /**
3624
- * 006004 — Alberta Crown Royalty incurred in the taxation year. Pass
3625
- * `computeAlbertaSchedule7(...).albertaCrownRoyaltyForSchedule6`; see the
3626
- * module docstring for why this is a plain input rather than re-derived.
3627
- */
3628
- albertaCrownRoyaltyIncurred?: number;
3629
- /**
3630
- * Days in THIS corporation's own taxation year — used only on the
3631
- * NOT-associated shelter path (006002 = 2). Defaults to 365 (a full year)
3632
- * and is capped at 365, per the form's own "(max 365)".
3633
- */
3634
- taxationYearDays?: number;
3635
- /** ACRS — required when `associatedWithCrownRoyaltyCorporations` is true. */
3636
- longestAssociatedYear?: RoyaltyTaxCreditLongestAssociatedYear;
3637
- /**
3638
- * AACRS — required when `associatedWithCrownRoyaltyCorporations` is true.
3639
- * The FIRST entry must be the corporation filing this return — its
3640
- * (possibly capped) `allocatedAmount` becomes 006006.
3641
- */
3642
- allocations?: readonly RoyaltyTaxCreditShelterAllocation[];
3643
- /** 006008 — one entry per calendar quarter the taxation year spans. */
3644
- quarters?: readonly RoyaltyTaxCreditQuarter[];
3645
- }
3646
- interface AlbertaSchedule6Result {
3647
- /** 006002. */
3648
- associatedWithCrownRoyaltyCorporations: boolean;
3649
- /** 006004. */
3650
- albertaCrownRoyaltyIncurred: number;
3651
- /** 006006. */
3652
- crownRoyaltyShelter: number;
3653
- /** 006008, to 4 decimal places. */
3654
- weightedAverageRate: number;
3655
- /** ACRS, echoed through with `days` resolved — present only when associated. */
3656
- longestAssociatedYear?: RoyaltyTaxCreditLongestAssociatedYear;
3657
- /** The $2,000,000 × (006028 / 365) pool being allocated — present only when associated. */
3658
- aggregateShelterPool: number;
3659
- /** AACRS, after per-row and aggregate capping. */
3660
- allocations: RoyaltyTaxCreditShelterAllocationResult[];
3661
- /** Σ allocated (post-cap). Cannot exceed `aggregateShelterPool`. */
3662
- totalAllocated: number;
3663
- /** Whether Alberta Crown Royalty was incurred at all — the form's own trigger condition (spec lines 6342-6361), evaluated from `albertaCrownRoyaltyIncurred` alone. */
3664
- formRequired: boolean;
3665
- issues: string[];
3666
- }
3667
- /**
3668
- * `scheduleNNValues` for Schedule 6, following the `at1-schedule-line-items.ts`
3669
- * builder pattern (see `schedule3Values` in `schedule3-other-deductions-credits.ts`
3670
- * for the identical local-type convention). Kept in THIS file rather than the
3671
- * shared filing module — other agents edit `at1-schedule-line-items.ts`
3672
- * concurrently.
3673
- */
3674
- interface At1ScheduleValueLike$3 {
3675
- lineItemId: string;
3676
- value: string | number;
3677
- }
3678
- interface At1ScheduleDataLike$3 {
3679
- scheduleId: string;
3680
- values: At1ScheduleValueLike$3[];
3681
- }
3682
- /**
3683
- * Emits every field this module's own MAPPINGS transcription actually defines
3684
- * a number for: 006002/004/006/008, and — only when the corporation is
3685
- * associated — the ACRS section (006022-028) and the AACRS allocation table
3686
- * (006030-034, one occurrence per row).
3687
- *
3688
- * ── No credit amount is filed here, because none exists on this schedule ────
3689
- *
3690
- * See the module docstring's "CONFIRMED: there is no 'credit' dollar amount
3691
- * to compute here" section — the Alberta Royalty Tax Credit is an instalment
3692
- * program (AT1 jacket line 000082, the shared "Payments & Instalments"
3693
- * schedule), not a value Schedule 6 computes and files. This builder emits
3694
- * exactly the three components the schedule DOES define (006004, 006006,
3695
- * 006008) plus the ACRS/AACRS detail when associated — matching
3696
- * `schedule3Values`'s `At1ScheduleDataLike` shape exactly: `{ scheduleId,
3697
- * values }`.
3698
- */
3699
- declare function schedule6Values(result: AlbertaSchedule6Result): At1ScheduleDataLike$3;
3700
- declare function computeAlbertaSchedule6(input: AlbertaSchedule6Input): AlbertaSchedule6Result;
3701
- //#endregion
3702
- //#region src/t2/at1/schedules/schedule7-royalty-supplemental.d.ts
3703
- /**
3704
- * Alberta AT1 Schedule 7 — Alberta Royalty Tax Credit/Deduction Supplemental
3705
- * Information.
3706
- *
3707
- * TRA spec §3.2.3.8 (Chapter 3, lines 6654-7251). Schedule 7 is not itself a
3708
- * claim — it is the disclosure schedule that supports BOTH AT1 Schedule 5
3709
- * (Royalty Tax Deduction) and AT1 Schedule 6 (Royalty Tax Credit): "If there
3710
- * is a requirement for forms 005 and/or form 006, then form 007 must be
3711
- * completed. IF FORM 007 IS NOT INCLUDED WITH FORMS 005 AND/OR 006, THEN THE
3712
- * CLIENT'S RTC ENTITLEMENT WILL BE DISALLOWED" (spec lines 6704-6715).
3713
- * Schedule 5 is built independently by another module in this package; this
3714
- * one only produces the figures Schedule 5 and Schedule 6 each cite as coming
3715
- * "from Schedule 7".
3716
- *
3717
- * ── Structure ────────────────────────────────────────────────────────────
3718
- *
3719
- * CPI (Crown Payment Information, 007003-007029) — the corporation's own
3720
- * crown charges, transcribed line by line from the income statement
3721
- * (fed form 125) and balance sheet (fed form 100).
3722
- * PITI (Partnership Income Tax Information, 007071-007081) — one row per
3723
- * partnership the corporation is a member of, repeating.
3724
- * ACRA (Adjustments to ACR Reported in the Current year but Relating to
3725
- * prior taxation years, 007083-007091) — one row per prior-year
3726
- * correction, repeating.
3727
- *
3728
- * ── Two totals with NO defining row of their own in this MAPPINGS table ────
3729
- *
3730
- * Both totals below are cited BY NAME from other schedules' own field
3731
- * definitions elsewhere in the same spec document, but neither has its own
3732
- * row inside Schedule 7's MAPPINGS block (spec lines 6654-7251, the full
3733
- * extent of Schedule 7 in this document) — the field numbering jumps
3734
- * 007051 → 007071 with no 007061 row ever printed, even though line 061 is
3735
- * referenced as an existing, fully-defined line. Both are modelled here
3736
- * because their formulas are stated explicitly elsewhere in the spec, not
3737
- * guessed:
3738
- *
3739
- * **007051** ("Total Adjustments to current year Alberta Crown Royalty due
3740
- * to adjustments from Prior Production Years") DOES have its own row
3741
- * (spec lines 6939-6947):
3742
- * 051 = Σ (007087 − 007089 + 007091), default zero if no ACRA rows.
3743
- *
3744
- * **007061** has no row in 6654-7251, but AT1 Schedule 5's own field 005001
3745
- * ("Crown charges") cites it verbatim, formula included in full (spec
3746
- * lines 5237-5248, inside Schedule 5's own MAPPINGS block, not Schedule
3747
- * 7's):
3748
- * "Enter the amount from Schedule 7, line 061.
3749
- * 007003 + 007005 + 007007 + 007009 + 007011 + 007013 + 007017 +
3750
- * 007025 + 007029 + (sum of all 007077) + (sum of all 007079) +
3751
- * (sum of all 007081) − 007051
3752
- * if negative, default to zero."
3753
- * The "if negative, default to zero" step is Schedule 5's own 005001 rule
3754
- * (confirmed against the Schedule 5 module in this package, which applies
3755
- * that floor itself), so `crownChargesNetOfReimbursements` here is left
3756
- * SIGNED — un-floored — and the floor is Schedule 5's job, not this
3757
- * module's.
3758
- *
3759
- * ── A sign asymmetry between 007051 and 006004, not resolved here ──────────
3760
- *
3761
- * AT1 Schedule 6's own field 006004 ("Alberta Crown Royalty incurred in the
3762
- * taxation year") is defined, also elsewhere in the spec (Schedule 6's own
3763
- * block, lines 6375-6384), as:
3764
- *
3765
- * 006004 = 007003 + (sum of all 007077) − (sum of all 007087)
3766
- * + (sum of all 007089)
3767
- *
3768
- * That is the OPPOSITE sign treatment of 007087/007089 from 007051 above
3769
- * (which adds 087 and subtracts 089). Both formulas are transcribed exactly
3770
- * as printed — this module does not "correct" the apparent inversion, and
3771
- * `albertaCrownRoyaltyForSchedule6` and `totalAdjustments` are computed
3772
- * independently, each per its own literal spec text. Flagged for the filer
3773
- * to confirm against the live form rather than silently normalized.
3774
- *
3775
- * ── Cross-reference to Schedule 5 (built independently, out of scope here) ──
3776
- *
3777
- * `totalPartnershipShareOtherCrownCharges` (Σ007081, "corporation's share of
3778
- * other Crown charges eligible for Royalty Tax Deduction") feeds Schedule 5,
3779
- * not this schedule — it is exposed here purely as data collected on this
3780
- * form, computed and passed through, never consumed by Schedule 6 or by any
3781
- * calculation inside this module.
3782
- *
3783
- * Whole dollars, pure.
3784
- */
3785
- /** One partnership the corporation is a member of (PITI, 007071-007081). */
3786
- interface RoyaltySupplementalPartnership {
3787
- /** 007071 — legal name of the partnership. */
3788
- name: string;
3789
- /** 007073 — corporation's percentage interest, as a decimal (0.75, not 75). Expressed to 4 decimal places on the form. */
3790
- interestPercent: number;
3791
- /** 007075 — partnership fiscal period end, ISO `YYYY-MM-DD`. */
3792
- fiscalPeriodEnd?: string;
3793
- /** 007077 — corporation's share of Alberta Crown Royalties eligible for the Royalty Tax Credit. */
3794
- shareEligibleForCredit?: number;
3795
- /** 007079 — corporation's share of other royalties paid to Alberta not eligible for the Royalty Tax Credit. */
3796
- shareOtherRoyaltiesNotEligible?: number;
3797
- /**
3798
- * 007081 — corporation's share of other Crown charges eligible for the
3799
- * Royalty Tax Deduction. Feeds AT1 Schedule 5 (built independently); not
3800
- * used anywhere in this module's own arithmetic beyond being summed and
3801
- * passed through.
3802
- */
3803
- shareOtherCrownChargesEligibleForDeduction?: number;
3804
- }
3805
- /** One resolved partnership row. */
3806
- interface RoyaltySupplementalPartnershipResult {
3807
- name: string;
3808
- interestPercent: number;
3809
- fiscalPeriodEnd?: string;
3810
- shareEligibleForCredit: number;
3811
- shareOtherRoyaltiesNotEligible: number;
3812
- shareOtherCrownChargesEligibleForDeduction: number;
3813
- }
3814
- /**
3815
- * One prior-year Alberta Crown Royalty adjustment reported in the current
3816
- * accounting period (ACRA, 007083-007091).
3817
- */
3818
- interface RoyaltySupplementalPriorYearAdjustment {
3819
- /** 007083 — the prior production period (taxation year end) the adjustment relates to, ISO `YYYY-MM-DD`. */
3820
- priorProductionPeriodEnd?: string;
3821
- /** 007085 — 1 = Department of Resource Development (formerly Energy), 2 = Operator. */
3822
- sourceOfAdjustment?: 1 | 2;
3823
- /** 007087 — amount of INCREASE to eligible crown royalties for that prior year (positive magnitude). */
3824
- increase?: number;
3825
- /** 007089 — amount of DECREASE to eligible crown royalties for that prior year (positive magnitude). */
3826
- decrease?: number;
3827
- /** 007091 — signed adjustment to the amount NOT eligible for the Royalty Tax Credit for that prior year. */
3828
- adjustmentNotEligibleForCredit?: number;
3829
- }
3830
- /** One resolved prior-year adjustment row. */
3831
- interface RoyaltySupplementalPriorYearAdjustmentResult {
3832
- priorProductionPeriodEnd?: string;
3833
- sourceOfAdjustment?: 1 | 2;
3834
- increase: number;
3835
- decrease: number;
3836
- adjustmentNotEligibleForCredit: number;
3837
- }
3838
- interface AlbertaSchedule7Input {
3839
- /** 007003 — Alberta crown royalty eligible for the Royalty Tax Credit, from the income statement (fed form 125). */
3840
- eligibleCrownRoyalty?: number;
3841
- /** 007005 — other royalties paid to Alberta not eligible for the Royalty Tax Credit (fed form 125). */
3842
- otherRoyaltiesNotEligible?: number;
3843
- /** 007007 — crown royalty paid to other provincial or federal jurisdictions (fed form 125). */
3844
- royaltyPaidToOtherJurisdictions?: number;
3845
- /** 007009 — non-deductible crown lease rentals (fed form 125). */
3846
- nonDeductibleCrownLeaseRentals?: number;
3847
- /** 007011 — mineral taxes (fed form 125). */
3848
- mineralTaxes?: number;
3849
- /** 007013 — Saskatchewan resources surcharge, non-deductible portion only (fed form 125). */
3850
- saskatchewanResourcesSurcharge?: number;
3851
- /** 007014 / 007015 / 007016 — up to three names of other non-deductible crown charge types (fed form 125). */
3852
- otherNonDeductibleCrownChargeTypes?: readonly string[];
3853
- /**
3854
- * 007017 — total dollar amount of the other non-deductible crown charges
3855
- * named above. The spec sums the underlying source-document amounts for
3856
- * whichever types are named; those per-type amounts are not themselves
3857
- * separate transmitted fields, so the total is taken as a pass-through
3858
- * input. Defaults to zero when no types are named, per spec.
3859
- */
3860
- otherNonDeductibleCrownCharges?: number;
3861
- /** 007025 — crown lease rentals capitalized during the year on non-producing properties, non-deductible portion (balance sheet, fed form 100). */
3862
- crownLeaseRentalsCapitalized?: number;
3863
- /** 007027 — name of another balance sheet (fed form 100) eligible deduction. */
3864
- otherBalanceSheetDeductionName?: string;
3865
- /** 007029 — dollar amount of the deduction named at 007027. Defaults to zero when no name is given, per spec. */
3866
- otherBalanceSheetDeduction?: number;
3867
- /** PITI — one row per partnership the corporation is a member of. */
3868
- partnerships?: readonly RoyaltySupplementalPartnership[];
3869
- /** ACRA — one row per prior-year Alberta Crown Royalty adjustment reported in the current year. */
3870
- priorYearAdjustments?: readonly RoyaltySupplementalPriorYearAdjustment[];
3871
- }
3872
- interface AlbertaSchedule7Result {
3873
- eligibleCrownRoyalty: number;
3874
- otherRoyaltiesNotEligible: number;
3875
- royaltyPaidToOtherJurisdictions: number;
3876
- nonDeductibleCrownLeaseRentals: number;
3877
- mineralTaxes: number;
3878
- saskatchewanResourcesSurcharge: number;
3879
- otherNonDeductibleCrownChargeTypes: string[];
3880
- /** 007017. */
3881
- otherNonDeductibleCrownCharges: number;
3882
- crownLeaseRentalsCapitalized: number;
3883
- otherBalanceSheetDeductionName?: string;
3884
- /** 007029. */
3885
- otherBalanceSheetDeduction: number;
3886
- partnerships: RoyaltySupplementalPartnershipResult[];
3887
- /** Σ 007077 across all partnerships. */
3888
- totalPartnershipShareEligibleForCredit: number;
3889
- /** Σ 007079 across all partnerships. */
3890
- totalPartnershipShareOtherRoyaltiesNotEligible: number;
3891
- /** Σ 007081 across all partnerships — feeds AT1 Schedule 5, not used here. */
3892
- totalPartnershipShareOtherCrownCharges: number;
3893
- priorYearAdjustments: RoyaltySupplementalPriorYearAdjustmentResult[];
3894
- /** 007051 = Σ (087 − 089 + 091). */
3895
- totalAdjustments: number;
3896
- /**
3897
- * 007061 — no defining row in this schedule's own MAPPINGS block; formula
3898
- * transcribed from AT1 Schedule 5's field 005001 definition, which cites it
3899
- * as "Schedule 7, line 061" in full. Left SIGNED — Schedule 5 applies its
3900
- * own floor at zero.
3901
- */
3902
- crownChargesNetOfReimbursements: number;
3903
- /**
3904
- * AT1 Schedule 6's 006004 ("Alberta Crown Royalty incurred in the taxation
3905
- * year"): 007003 + Σ077 − Σ087 + Σ089. Pass this into
3906
- * `computeAlbertaSchedule6`'s `albertaCrownRoyaltyIncurred` input.
3907
- */
3908
- albertaCrownRoyaltyForSchedule6: number;
3909
- issues: string[];
3910
- }
3911
- /**
3912
- * `scheduleNNValues` for Schedule 7, following the `at1-schedule-line-items.ts`
3913
- * builder pattern (see `schedule3Values` in `schedule3-other-deductions-credits.ts`
3914
- * for the identical local-type convention this file reuses). Kept in THIS
3915
- * file rather than the shared filing module — other agents edit
3916
- * `at1-schedule-line-items.ts` concurrently.
3917
- */
3918
- interface At1ScheduleValueLike$2 {
3919
- lineItemId: string;
3920
- value: string | number;
3921
- }
3922
- interface At1ScheduleDataLike$2 {
3923
- scheduleId: string;
3924
- values: At1ScheduleValueLike$2[];
3925
- }
3926
- /**
3927
- * Emits CPI (007003-029), the computed totals 007051 and 007061, and the two
3928
- * repeating sections — PITI (007071-081, one occurrence per partnership) and
3929
- * ACRA (007083-091, one occurrence per prior-year adjustment).
3930
- *
3931
- * 007061 is filed even though it has no defining row of its own anywhere in
3932
- * this schedule's MAPPINGS block (spec lines 6654-7251) — see the module
3933
- * docstring's "Two totals with NO defining row of their own in this MAPPINGS
3934
- * table" section. It is a real Schedule 7 output line: AT1 Schedule 5's own
3935
- * field 005001 definition (spec lines 5237-5248) names it explicitly as
3936
- * "Schedule 7, line 061" and gives its formula in full, so it is filed here
3937
- * under that citation rather than omitted for lack of a home row.
3938
- */
3939
- declare function schedule7Values(result: AlbertaSchedule7Result): At1ScheduleDataLike$2;
3940
- declare function computeAlbertaSchedule7(input: AlbertaSchedule7Input): AlbertaSchedule7Result;
3941
- //#endregion
3942
- //#region src/t2/at1/schedules/schedule8-political-contributions.d.ts
3943
- /**
3944
- * Alberta AT1 Schedule 8 — Alberta Political Contributions Tax Credit.
3945
- *
3946
- * Schedule 8 itself (TRA spec §3.2.3.9, lines 7252-7450, form "008") is a
3947
- * detail schedule, not a calculation: it collects one PCD occurrence per
3948
- * receipted contribution —
3949
- *
3950
- * 008002 name of party / constituency association / candidate M
3951
- * 008004 official receipt number M
3952
- * 008006 date of donation (the spec: "do not let ... blank") M
3953
- * 008008 donation amount M
3954
- *
3955
- * — plus two APC (Alberta Political Contributions) totals for contributions
3956
- * made THROUGH A PARTNERSHIP, sourced from federal form T5013 and not
3957
- * derivable from anything else in this schedule:
3958
- *
3959
- * 008012 partnership contributions made in 2003 or earlier (T5013 box 37)
3960
- * 008013 partnership contributions made in 2004 or later (T5013)
3961
- *
3962
- * The actual TIERED CREDIT FORMULA that turns those totals into a dollar
3963
- * credit is not on Schedule 8's own line map at all — it lives on the AT1
3964
- * JACKET, line 000074 (§3.2.3.1, "AT1 - Alberta Corporate Income Tax Return"),
3965
- * which consumes Schedule 8's own totals (008008, 008012, 008013). Because it
3966
- * is entirely built from Schedule 8's own numbers and the module's name is
3967
- * "the Alberta Political Contributions Tax Credit", it is reproduced here —
3968
- * transcribed exactly, three rate periods:
3969
- *
3970
- * **All contributions made in 2003 or earlier:**
3971
- * A = (sum of 008008) + 008012
3972
- * B = A ≤ $150 → A×.75 | A ≤ $825 → $112.50 + (A−150)×.50 | else $450 + (A−825)×.333
3973
- * credit = least of B, $750, `000068 − (000070 + 000071 + 000072)`
3974
- *
3975
- * **All contributions made in 2004 or later:**
3976
- * A = (sum of 008008) + 008013
3977
- * B = A ≤ $200 → A×.75 | A ≤ $900 → $150 + (A−200)×.50 | else $600 + (A−900)×.333
3978
- * credit = least of B, $1000, `000068 − (000070 + 000071 + 000072)`
3979
- *
3980
- * **Contributions made in BOTH 2003 and 2004, AND the tax year itself begins
3981
- * in 2003 and ends in 2004** (a straddling fiscal year-end, not just mixed
3982
- * donation dates):
3983
- * X = (sum of 008008 dated in 2004 only) + 008013
3984
- * Y = (sum of 008008) + 008012 + 008013
3985
- * A = min(Y, 150); B = min(X−A, 50); C = min(Y−(A+B), 675)
3986
- * D = min(X−(A+B+C), 225); E = min(Y−(A+B+C+D), 900); F = min(X−(A+B+C+D+E), 300)
3987
- * credit = .75A + .75B + .50C + .50D + ⅓E + ⅓F
3988
- * — the spec states NO $750/$1000/remaining-tax ceiling for this branch,
3989
- * unlike the other two. Reproduced literally: this module does not invent
3990
- * one. (Jacket line 080, "Alberta Tax Payable", cannot go negative, and
3991
- * that reconciliation is enforced elsewhere, e.g. `at1-line-items.ts`'s
3992
- * `At1TaxPayableMismatchError` — not this module's job.)
3993
- *
3994
- * If contributions span both periods WITHOUT the tax year itself straddling
3995
- * 2003/2004, the spec defines no formula for that combination; this module
3996
- * computes nothing and raises an issue rather than guessing which branch to
3997
- * apply.
3998
- *
3999
- * `000068 − (000070 + 000071 + 000072)` (basic Alberta tax minus the small
4000
- * business deduction, M&P profits deduction and foreign investment tax
4001
- * credit) is an AT1 JACKET figure built from schedules this module doesn't
4002
- * reach — taken here as a single `remainingBasicTax` input, following the
4003
- * same fail-closed convention as `schedule20-donations.ts`'s `incomeLimit`:
4004
- * absent means no claim for the two capped rate periods.
4005
- *
4006
- * Whole dollars, pure.
4007
- */
4008
- interface PoliticalContributionInput {
4009
- /** 008002 — name of the party, constituency association or candidate. */
4010
- name: string;
4011
- /** 008004 — official receipt number. */
4012
- receiptNumber: string;
4013
- /** 008006 — date of the official receipt, ISO `YYYY-MM-DD`. Mandatory per spec. */
4014
- dateOfDonation: string;
4015
- /** 008008 — donation amount. */
4016
- amount: number;
4017
- }
4018
- interface Schedule8Input {
4019
- /** One PCD occurrence per receipted contribution. */
4020
- contributions: PoliticalContributionInput[];
4021
- /**
4022
- * 008012 — Alberta political contributions from a partnership made in 2003
4023
- * or earlier, sourced from federal T5013 box 37. Defaults to nil.
4024
- */
4025
- partnershipContributionsTo2003?: number;
4026
- /**
4027
- * 008013 — Alberta political contributions from a partnership made in 2004
4028
- * or later, sourced from federal T5013. Defaults to nil.
4029
- */
4030
- partnershipContributionsFrom2004?: number;
4031
- /**
4032
- * The corporation's tax year start/end, ISO `YYYY-MM-DD`. Needed ONLY to
4033
- * confirm the third (straddling) rate-period formula applies — it
4034
- * additionally requires the tax year itself to begin in 2003 and end in
4035
- * 2004, not just that contribution dates span both years.
4036
- */
4037
- taxYearBegin?: string;
4038
- taxYearEnd?: string;
4039
- /**
4040
- * `000068 − (000070 + 000071 + 000072)` — remaining basic Alberta tax after
4041
- * the small business deduction, M&P profits deduction and foreign
4042
- * investment tax credit. Required for the 2003-or-earlier and
4043
- * 2004-or-later rate periods, which the spec caps against it; absent means
4044
- * no claim for those periods (fail closed). NOT applied to the straddling
4045
- * period, which the spec states no ceiling for.
4046
- */
4047
- remainingBasicTax?: number;
4048
- }
4049
- interface Schedule8Result {
4050
- contributions: PoliticalContributionInput[];
4051
- partnershipContributionsTo2003: number;
4052
- partnershipContributionsFrom2004: number;
4053
- /** Which of the three rate-period formulas applied, or 'none'. */
4054
- period: 'to-2003' | 'from-2004' | 'straddle-2003-2004' | 'none';
4055
- /** B in the to-2003/from-2004 branches, or the weighted A..F sum in the straddle branch — before any ceiling. */
4056
- creditBeforeCeiling: number;
4057
- /** 000074 (jacket) — the Alberta Political Contributions Tax Credit, after whatever ceiling applies. */
4058
- credit: number;
4059
- issues: string[];
4060
- }
4061
- declare function computeSchedule8(input: Schedule8Input): Schedule8Result;
4062
- /**
4063
- * Net File line items for AT1 Schedule 8: one PCD occurrence per contribution
4064
- * (002 name, 004 receipt number, 006 date, 008 amount), plus the two APC
4065
- * partnership totals (012, 013).
4066
- *
4067
- * Does NOT emit jacket line 000074 (the actual tax credit) — that is a
4068
- * jacket line, not a Schedule 8 line. Use `result.credit` for that.
4069
- */
4070
- declare function schedule8Values(result: Schedule8Result): At1ScheduleData;
4071
- //#endregion
4072
- //#region src/t2/at1/schedules/schedule9-sred-tax-credit.d.ts
4073
- /**
4074
- * AT1 Schedule 9 — Alberta Scientific Research & Experimental Development Tax
4075
- * Credit.
4076
- *
4077
- * Alberta's OWN investment tax credit on SR&ED spending — not the same thing as
4078
- * either of the two SR&ED-adjacent modules already in this package:
4079
- *
4080
- * • AT1 Schedule 16 (`schedule16-sred.ts`) — the Alberta SR&ED expenditure
4081
- * **pool**, a deduction against income; and
4082
- * • federal Schedule 31 (`t2/schedules/schedule31-sred-itc.ts`) — the FEDERAL
4083
- * investment tax credit, computed under s.127/127.1 at 35%/15%.
4084
- *
4085
- * This module is Alberta's PARALLEL investment tax credit, at a flat 10% (line
4086
- * 120, "lesser of line 009031 and 009108 X 10%") — an entirely separate credit
4087
- * mechanism from the federal one, not a top-up or a share of it.
4088
- *
4089
- * **The credit is WOUND DOWN.** Per the spec's own framing text (TRA spec
4090
- * §3.2.3.10, page 3-84): "eligible expenditures" are federal-expenditure amounts
4091
- * "carried out in Alberta before January 1, 2020, [and] the SR&ED Tax Credit may
4092
- * not be claimed in respect of any such expenditures carried out in Alberta after
4093
- * that date." This module does not filter expenditures by date itself — the
4094
- * `albertaPortionOfExpenditures` (005) input must already exclude anything
4095
- * incurred after 2019-12-31. `taxationYearEnd` is accepted purely to raise a
4096
- * reminder issue when the return's own year end falls after that cut-off, since
4097
- * a straddling year is exactly where a preparer is most likely to include an
4098
- * ineligible period by mistake.
4099
- *
4100
- * Line map (TRA spec §3.2.3.10, "Schedule 9 - Alberta Scientific Research &
4101
- * Experimental Development Tax Credit", pp. 3-84 to 3-90):
4102
- *
4103
- * 009003 federal total qualified SR&ED expenditures (fed T661 line 559) M
4104
- * 009005 portion of 003 incurred in Alberta X
4105
- * 009007 deduct: federal prescribed proxy amount in the Alberta portion X
4106
- * 009009 add: Alberta proxy amount X
4107
- * 009011 add: Alberta SR&ED credit that reduced the federal expense X
4108
- * on fed T661 line 559 in the taxation year
4109
- * 009015 federal ITC received in the immediately preceding year X
4110
- * (fed T661 line 435)
4111
- * 009017 total Alberta-eligible expenditures for years in which the X
4112
- * expenditure was incurred (009031 from all relevant years)
4113
- * 009019 total federal expenditures for those same years (fed T661 X
4114
- * line 570 from all relevant years)
4115
- * 009023 deduct: Alberta portion of the prior-year federal ITC X
4116
- * = 009015 x 009017 / 009019
4117
- * 009025 add: Alberta portion of any repayment of assistance and X
4118
- * contract payments relating to amounts in 009005
4119
- * 009040 primary field of science or technology (1-4) M
4120
- * 009100 associated with one or more corporations for SR&ED purposes? M
4121
- * 009102 if associated: allocated amount from line 240 (page 3) X
4122
- * 009104 if not associated: maximum expenditure limit = $4,000,000 x X
4123
- * (days in the corporation's tax year / 365, max 365 or 366)
4124
- * 009106 eligible expenditures for Alberta purposes = 009031 X
4125
- * 009108 maximum expenditure limit for the year (102 or 104) M
4126
- * 009112 recapture on disposal of Alberta SR&ED property O
4127
- * 009116 less: Alberta portion of prior-year federal ITC (Schedule 9 X
4128
- * Supplemental line 428 — only where the year end is on or
4129
- * before 2012-03-31)
4130
- * 009120 NET ALBERTA SR&ED TAX CREDIT (REPAYMENT), to AT1 page 2 line M
4131
- * 081 = (lesser of 009031 and 009108 x 10%) - 009112 - 009116
4132
- *
4133
- * Allocation of the Maximum Expenditure Limit (page 3, required when 100 = 1):
4134
- * 009200 CAN of the associated corporation with the longest tax year X
4135
- * 009202 / 009204 that corporation's own tax year begin / end M
4136
- * 009206 days in the longest year (max 365, or 366 across Feb 29) M
4137
- * 009220 name of each associated corporation (row 1 = the filer) M
4138
- * 009230 Alberta Corporate Account Number of each X
4139
- * 009240 allocated amount — each occurrence AND the sum of all M
4140
- * occurrences must not exceed $4,000,000 x (009206 / 365)
4141
- *
4142
- * ── Line 009031 has no formula in the spec text ─────────────────────────────
4143
- *
4144
- * Lines 009003-009025 and 009106/009017 all reference "009031" ("Total eligible
4145
- * expenditures for Alberta purposes") as the figure they equal or feed into, but
4146
- * the mapping tables jump straight from 009025 to 009040 — 009027, 009029 and
4147
- * 009031 themselves are never defined in the spec's MAPPINGS chapter, most
4148
- * likely because they are calculated-on-paper subtotals that are not, unlike
4149
- * every field above them, separately transmitted EFILE data elements. Rather
4150
- * than invent a number, this module DERIVES 031 from the six lines the spec DOES
4151
- * define and caption unambiguously as "Deduct" or "Add" against the Alberta
4152
- * expenditure pool (005, 007, 009, 011, 023, 025):
4153
- *
4154
- * 031 = 005 − 007 + 009 + 011 − 023 + 025
4155
- *
4156
- * That derivation is used only when `eligibleExpenditures` is not supplied
4157
- * directly, and an issue is always raised when it is, so a preparer with the
4158
- * authoritative figure (e.g. from the Guide to Claiming the Alberta SR&ED Tax
4159
- * Credit) knows to override it via `eligibleExpenditures`.
4160
- *
4161
- * ── Line 009011 cites a line that does not exist ────────────────────────────
4162
- *
4163
- * The spec's own business rule for 011 reads "Value = 009110. See Guide to
4164
- * Claiming The Alberta SR&ED Tax Credit for calculation" — but no line 009110 is
4165
- * defined anywhere in this schedule (the lines run ...009108, 009112...). It is
4166
- * most likely a transposed "009011" (self-reference) or a Guide-only figure with
4167
- * no corresponding transmitted line at all. Either way its actual calculation is
4168
- * explicitly deferred to an external guide this package does not model, so
4169
- * `albertaCreditReducingFederalExpense` is accepted as a plain numeric INPUT.
4170
- *
4171
- * ── Line 009116 is a legacy, pre-2012 field ─────────────────────────────────
4172
- *
4173
- * "If the taxation year end is on or before March 31, 2012, value = line 428 of
4174
- * Schedule 9 Supplemental." The Schedule 9 Supplemental and its own line 428 are
4175
- * not modelled — `priorYearFederalItcAdjustment` is a plain numeric input,
4176
- * expected to be nil for any current return.
4177
- *
4178
- * Whole dollars, pure.
4179
- */
4180
- /** Valid codes for line 009040 — "Primary field of science or technology". */
4181
- type Schedule9FieldOfScience = 1 | 2 | 3 | 4;
4182
- interface AlbertaSchedule9Input {
4183
- /** 009003 — federal total qualified SR&ED expenditures. Must equal fed T661 line 559. */
4184
- federalQualifiedExpenditures?: number;
4185
- /** 009005 — the portion of 003 incurred in Alberta. Must not exceed 003. */
4186
- albertaPortionOfExpenditures?: number;
4187
- /** 009007 — deduct: federal prescribed proxy amount included in the Alberta portion. */
4188
- federalProxyAmountInAlbertaPortion?: number;
4189
- /** 009009 — add: Alberta proxy amount. */
4190
- albertaProxyAmount?: number;
4191
- /**
4192
- * 009011 — add: Alberta SR&ED credit that reduced the federal expense on fed
4193
- * T661 line 559 in the taxation year. Its calculation is deferred by the spec
4194
- * to the Guide to Claiming the Alberta SR&ED Tax Credit — see the module
4195
- * docstring. Plain input.
4196
- */
4197
- albertaCreditReducingFederalExpense?: number;
4198
- /** 009015 — federal ITC received in the immediately preceding year (fed T661 line 435). */
4199
- priorYearFederalItcReceived?: number;
4200
- /** 009017 — total Alberta-eligible expenditures for years in which incurred (009031, all years). */
4201
- totalAlbertaExpendituresAllYears?: number;
4202
- /** 009019 — total federal expenditures for those same years (fed T661 line 570, all years). */
4203
- totalFederalExpendituresAllYears?: number;
4204
- /** 009025 — add: Alberta portion of any repayment of assistance relating to 005. */
4205
- albertaPortionOfRepayments?: number;
4206
- /**
4207
- * 009031 / 009106 — "Total eligible expenditures for Alberta purposes."
4208
- * Overrides the derived figure (005 − 007 + 009 + 011 − 023 + 025) when the
4209
- * authoritative amount is known. See the module docstring for why this is
4210
- * derived rather than read directly off the spec.
4211
- */
4212
- eligibleExpenditures?: number;
4213
- /** 009040 — primary field of science or technology. Mandatory on the live form. */
4214
- fieldOfScience?: Schedule9FieldOfScience;
4215
- /** 009100 — associated with one or more corporations for SR&ED purposes? Defaults to false (line default = 2/No). */
4216
- isAssociated?: boolean;
4217
- /** 009102 — required when associated: this corporation's allocated share of line 240. */
4218
- allocatedExpenditureLimit?: number;
4219
- /**
4220
- * Days in the corporation's own taxation year, for the non-associated 009104
4221
- * proration. Defaults to 365 (a full year); clamped to [0, 366]. Per the
4222
- * spec, days before 2009-01-01 (when the Alberta SR&ED program began) must
4223
- * already be excluded by the caller — day-of-year proration from real
4224
- * calendar dates is not modelled here, matching this package's convention
4225
- * elsewhere (e.g. the AT1 Schedule 29 group allocation).
4226
- */
4227
- daysInTaxYear?: number;
4228
- /** 009112 — recapture on disposal (or deemed disposal) of Alberta SR&ED property. */
4229
- disposalRecapture?: number;
4230
- /**
4231
- * 009116 — legacy pre-2012 adjustment from the Schedule 9 Supplemental line
4232
- * 428. See the module docstring; expected nil for a current return.
4233
- */
4234
- priorYearFederalItcAdjustment?: number;
4235
- /**
4236
- * The return's taxation year end (ISO `YYYY-MM-DD`), used only to flag a
4237
- * reminder when it falls after the 2019-12-31 wind-down date — see the
4238
- * module docstring's "WOUND DOWN" note.
4239
- */
4240
- taxationYearEnd?: string;
4241
- }
4242
- interface AlbertaSchedule9Result {
4243
- federalQualifiedExpenditures: number;
4244
- albertaPortionOfExpenditures: number;
4245
- federalProxyAmountInAlbertaPortion: number;
4246
- albertaProxyAmount: number;
4247
- albertaCreditReducingFederalExpense: number;
4248
- priorYearFederalItcReceived: number;
4249
- totalAlbertaExpendituresAllYears: number;
4250
- totalFederalExpendituresAllYears: number;
4251
- /** 009023 = 009015 x 009017 / 009019. */
4252
- priorYearItcAlbertaPortion: number;
4253
- albertaPortionOfRepayments: number;
4254
- /**
4255
- * 009031 / 009106 — the figure actually used at 009108's lesser-of test.
4256
- * Equal to `eligibleExpenditures` when supplied, otherwise the derived
4257
- * figure (see `derivedEligibleExpenditures` and the module docstring).
4258
- */
4259
- eligibleExpenditures: number;
4260
- /** The derived cross-check: 005 − 007 + 009 + 011 − 023 + 025, always computed. */
4261
- derivedEligibleExpenditures: number;
4262
- fieldOfScience: Schedule9FieldOfScience | undefined;
4263
- isAssociated: boolean;
4264
- /** 009104 — the non-associated day-prorated $4,000,000 limit (0 when associated). */
4265
- nonAssociatedMaximumExpenditureLimit: number;
4266
- /** 009108 — the maximum expenditure limit actually in effect (102 or 104). */
4267
- maximumExpenditureLimit: number;
4268
- disposalRecapture: number;
4269
- priorYearFederalItcAdjustment: number;
4270
- /** 009120 — signed; may be negative (a repayment). To AT1 page 2, line 081. */
4271
- netCredit: number;
4272
- issues: string[];
4273
- }
4274
- /** 009120's flat rate — "lesser of line 009031 and 009108 X 10%". */
4275
- declare const ALBERTA_SRED_TAX_CREDIT_RATE = 0.1;
4276
- /** Alberta's SR&ED program did not exist before this date (line 009104's note). */
4277
- declare const ALBERTA_SRED_PROGRAM_START = "2009-01-01";
4278
- /** Alberta SR&ED expenditures carried out after this date are not eligible (module docstring). */
4279
- declare const ALBERTA_SRED_EXPENDITURE_CUTOFF = "2019-12-31";
4280
- /**
4281
- * 009104 / 009206's day-prorated $4,000,000 expenditure limit. Days are clamped
4282
- * to [0, 366] — 366 only for a year genuinely spanning a February 29, per the
4283
- * spec's own note.
4284
- */
4285
- declare function computeSchedule9MaximumExpenditureLimit(daysInTaxYear?: number): number;
4286
- declare function computeAlbertaSchedule9(input: AlbertaSchedule9Input): AlbertaSchedule9Result;
4287
- /** One row of the page-3 allocation table. Row 1 must be the filing corporation. */
4288
- interface Schedule9AllocationMember {
4289
- /** 009220 — name of the associated corporation. */
4290
- name: string;
4291
- /** 009230 — Alberta Corporate Account Number. */
4292
- albertaCan?: string;
4293
- /** 009240 — this member's agreed share of the expenditure limit. */
4294
- allocated: number;
4295
- }
4296
- interface Schedule9AllocationMemberResult {
4297
- name: string;
4298
- albertaCan?: string;
4299
- allocated: number;
4300
- }
4301
- interface Schedule9AllocationResult {
4302
- /** 009206 — days in the longest associated taxation year (clamped to [0, 366]). */
4303
- daysInLongestYear: number;
4304
- /** The shared $4,000,000-based ceiling every occurrence AND their sum must respect. */
4305
- maximumExpenditureLimit: number;
4306
- members: Schedule9AllocationMemberResult[];
4307
- /** Σ 009240. Must not exceed maximumExpenditureLimit. */
4308
- totalAllocated: number;
4309
- /** The filing corporation's own allocated share (row 1) — feeds 009102. */
4310
- claimantAllocatedAmount: number;
4311
- unallocated: number;
4312
- issues: string[];
4313
- }
4314
- /**
4315
- * Allocate the day-prorated $4,000,000 maximum expenditure limit among an
4316
- * associated group (page 3). Per the spec, EACH occurrence of 009240 and the
4317
- * SUM of all occurrences are independently capped at the limit — unlike a
4318
- * running-remainder split, one member requesting more than the limit does not
4319
- * consume another member's room; it is simply capped and flagged.
4320
- */
4321
- declare function allocateSchedule9ExpenditureLimit(daysInLongestYear: number, requested: readonly Schedule9AllocationMember[]): Schedule9AllocationResult;
4322
- /**
4323
- * `scheduleNNValues` for Schedule 9, following the `at1-schedule-line-items.ts`
4324
- * builder pattern (see `schedule3Values` in `schedule3-other-deductions-credits.ts`,
4325
- * `schedule16Values`, `schedule20Values`). Kept in THIS file rather than the
4326
- * shared filing module per the task instructions — other agents are editing
4327
- * `at1-schedule-line-items.ts` concurrently.
4328
- */
4329
- interface At1ScheduleValueLike$1 {
4330
- lineItemId: string;
4331
- value: string | number;
4332
- }
4333
- interface At1ScheduleDataLike$1 {
4334
- scheduleId: string;
4335
- values: At1ScheduleValueLike$1[];
4336
- }
4337
- /**
4338
- * The page-3 "Allocation of the Maximum Expenditure Limit" context that has no
4339
- * home on `AlbertaSchedule9Result` itself — the CAN and tax-year dates of the
4340
- * associated corporation with the longest year (009200/009202/009204), plus
4341
- * the `allocateSchedule9ExpenditureLimit` result supplying 009206 and the
4342
- * per-member 009220/009230/009240 rows. Supplied only when the corporation is
4343
- * associated and a group was actually entered.
4344
- */
4345
- interface Schedule9GroupFilingInput {
4346
- /** 009200 — Alberta CAN of the associated corporation with the longest tax year. */
4347
- longestYearCan?: string;
4348
- /** 009202 — that corporation's own tax year begin, ISO `YYYY-MM-DD`. */
4349
- longestYearBegin?: string;
4350
- /** 009204 — that corporation's own tax year end, ISO `YYYY-MM-DD`. */
4351
- longestYearEnd?: string;
4352
- /** The result of `allocateSchedule9ExpenditureLimit` — supplies 009206/220/230/240. */
4353
- allocation: Schedule9AllocationResult;
4354
- }
4355
- /**
4356
- * Field ids per the spec transcription in the module docstring: 003-025 (the
4357
- * expenditure buildup), 040 (field of science), 100-120 (the credit
4358
- * calculation), and — when `group` is supplied — 200-240 (page 3's
4359
- * allocation). Line 031 has no confirmed transmitted status of its own (see
4360
- * the module docstring's "line 009031 has no formula in the spec text"), but
4361
- * is filed anyway alongside 106 since both carry the identical "Total
4362
- * eligible expenditures for Alberta purposes" figure per the spec's own
4363
- * cross-reference ("106 ... Value must equal 009031").
4364
- */
4365
- declare function schedule9Values(result: AlbertaSchedule9Result, group?: Schedule9GroupFilingInput): At1ScheduleDataLike$1;
4366
- //#endregion
4367
3312
  //#region src/t2/at1/schedules/schedule15-resource-related-deductions.d.ts
4368
3313
  /**
4369
3314
  * Alberta AT1 Schedule 15 — Alberta Resource Related Deductions.
@@ -5350,21 +4295,7 @@ interface AlbertaReturnInput {
5350
4295
  smallBusinessDeduction?: Schedule1FilingInput;
5351
4296
  allocation?: Schedule2FilingInput; /** Alberta other tax deductions and credits — ITC / CITC / APITC (Sch 3). */
5352
4297
  otherDeductionsCredits?: Schedule3Result; /** Alberta foreign investment income tax credit (Sch 4). */
5353
- foreignInvestmentTaxCredit?: Schedule4Result$1; /** Alberta royalty tax deduction — Crown Royalty Tax Deduction pools (Sch 5). */
5354
- royaltyTaxDeduction?: AlbertaSchedule5Result; /** Alberta royalty tax credit (Sch 6). */
5355
- royaltyTaxCredit?: AlbertaSchedule6Result; /** Alberta royalty tax credit / deduction supplemental information (Sch 7). */
5356
- royaltySupplemental?: AlbertaSchedule7Result; /** Alberta political contributions tax credit (Sch 8). */
5357
- politicalContributions?: Schedule8Result;
5358
- /**
5359
- * Alberta SR&ED tax credit — the CREDIT, distinct from Sch 16's deduction
5360
- * pool (Sch 9). `group` is the page-3 associated-group allocation detail;
5361
- * supplied only when `AlbertaSchedule9Result` came from an associated
5362
- * corporation with a group actually entered.
5363
- */
5364
- sredTaxCredit?: {
5365
- result: AlbertaSchedule9Result;
5366
- group?: Schedule9GroupFilingInput;
5367
- };
4298
+ foreignInvestmentTaxCredit?: Schedule4Result$1;
5368
4299
  lossCarryback?: Schedule10FilingInput;
5369
4300
  reconciliation?: Schedule12FilingInput;
5370
4301
  cca?: AlbertaSchedule13Result; /** Alberta resource related deductions — eight expense-pool continuities (Sch 15). */
@@ -5667,12 +4598,26 @@ interface At1FilingData {
5667
4598
  preparedByTaxPreparerForFee?: boolean;
5668
4599
  }
5669
4600
  /**
5670
- * AT1 line 000090 — balance unpaid (overpayment), exactly as specified:
4601
+ * AT1 line 000090 — balance unpaid (overpayment), as the PRINTED form strikes
4602
+ * it:
5671
4603
  *
5672
- * 000090 = 000080 − (000081 + 000082 + 000085 + 000086 + 000087)
4604
+ * 000088 = 000129 + 000082 + 000085 + 000086 + 000115 + 000087
4605
+ * 000090 = 000080 − 000088
5673
4606
  *
5674
- * Signed a negative result is an overpayment, and line 000092 then chooses
5675
- * between a refund and applying it to next year.
4607
+ * 088 is a printed subtotal with no line code of its own, so only 090 is
4608
+ * filed. Signed — a negative result is an overpayment, and line 000092 then
4609
+ * chooses between a refund and applying it to next year.
4610
+ *
4611
+ * This used to follow §3.2.3.1's own line-090 rule,
4612
+ * `000080 - (000081 + 000082 + 00085 + 000086 + 000087)`, which nets the
4613
+ * ELIMINATED Alberta SR&ED tax credit and omits both the Innovation
4614
+ * Employment Grant and the Film and Television Tax Credit — two credits the
4615
+ * same specification marks mandatory. Every corporation claiming an IEG was
4616
+ * therefore filed with a balance overstated by the whole grant. See
4617
+ * `AT1_BALANCE_CREDIT_LINES` in `../forms/jacket.ts` for the full evidence,
4618
+ * and `albertaBalanceUnpaidPerSpec` below for the figure the specification
4619
+ * would produce — the review layer reports the difference rather than letting
4620
+ * the disagreement pass silently.
5676
4621
  */
5677
4622
  declare function albertaBalanceUnpaid(d: At1FilingData): number;
5678
4623
  /**
@@ -5891,6 +4836,23 @@ declare function toRsiHeader(data: At1FilingData): {
5891
4836
  legalName: string;
5892
4837
  };
5893
4838
  //#endregion
4839
+ //#region src/t2/at1/filing/at1-transmitter-validation.d.ts
4840
+ /** One rule TRA would have failed, and the code it would have failed with. */
4841
+ interface At1TransmitterDefect {
4842
+ /** The `At1TransmitterInfo` path — `contact.phone`, `address.postalCode`. */
4843
+ field: string;
4844
+ /** TRA's own error code for this rule. */
4845
+ traCode: string;
4846
+ message: string;
4847
+ }
4848
+ declare function validateAt1Transmitter(info: At1TransmitterInfo): At1TransmitterDefect[];
4849
+ declare class At1TransmitterInvalidError extends Error {
4850
+ readonly defects: At1TransmitterDefect[];
4851
+ constructor(defects: At1TransmitterDefect[]);
4852
+ }
4853
+ /** Throw unless every filer-detail rule TRA applies is satisfied. */
4854
+ declare function assertAt1TransmitterValid(info: At1TransmitterInfo): void;
4855
+ //#endregion
5894
4856
  //#region src/t2/at1/schedules/schedule12-reconciliation.d.ts
5895
4857
  /**
5896
4858
  * AT1 Schedule 12 — Alberta Income/Loss Reconciliation.
@@ -6059,6 +5021,192 @@ interface LossScheduleResult {
6059
5021
  /** One loss pool end to end: Schedule 10 (carry-back) → Schedule 21 (continuity). */
6060
5022
  declare function computeLossSchedule(input: LossScheduleInput): LossScheduleResult;
6061
5023
  //#endregion
5024
+ //#region src/t2/filing/t2-schedule-line-items.d.ts
5025
+ /**
5026
+ * Federal T2 — the per-schedule, per-line breakdown of a computed return.
5027
+ *
5028
+ * Alberta has had this since the AT1 filing path was built
5029
+ * (`at1-schedule-line-items.ts`): every schedule's result turned into a flat
5030
+ * list of `{lineItemId, value}` pairs, persisted with the computed return, and
5031
+ * read back by the paper Form Views so a preparer sees the actual figure
5032
+ * against the actual line. Federal had nothing equivalent. Its computed return
5033
+ * carried only summary fields under symbolic names — `netIncomeForTax`,
5034
+ * `ccaClaimed` — which no form can be keyed by, so every federal paper view
5035
+ * rendered "not available" against every computed line of every schedule.
5036
+ *
5037
+ * ── The rule this file follows, and why it is strict ────────────────────────
5038
+ *
5039
+ * A value is emitted ONLY where the line it belongs on is recorded in code:
5040
+ * carried in the data (Schedule 1's own `Schedule1Line.line`), exported as a
5041
+ * named constant (`SCHEDULE_8_CCA_LINE`), or stated in the result type's own
5042
+ * doc comment. Nothing here is a line number typed from memory or inferred from
5043
+ * a caption that looks close.
5044
+ *
5045
+ * The reason is the failure this repository keeps hitting: a figure filed under
5046
+ * the wrong line is not a missing figure, it is a WRONG return, and it looks
5047
+ * completely correct on screen. Schedule 4's jacket references claimed lines 150
5048
+ * and 250 where the form prints 130 and 225; Schedule 33's own result type said
5049
+ * line 690 where the form has 790. Both were plausible, both were wrong, and
5050
+ * neither was caught by a type.
5051
+ *
5052
+ * So a schedule whose result has no recorded line mapping produces NO entry
5053
+ * rather than a guessed one, and the paper view keeps saying "not available"
5054
+ * for it. That is the honest state, and it is visibly incomplete, which is what
5055
+ * makes it safe to extend one verified line at a time.
5056
+ *
5057
+ * ── Identifier shape ────────────────────────────────────────────────────────
5058
+ *
5059
+ * Six characters: the three-digit CRA line, then a three-digit occurrence.
5060
+ * Alberta uses nine (`SSSFFFOOO`) because a TRA line item id names its schedule
5061
+ * too; a federal line number is already unique across the whole return, so the
5062
+ * schedule is carried once on the envelope instead of repeated on every row.
5063
+ * The trailing occurrence exists for the grid forms, where one line number
5064
+ * repeats down a column — Schedule 8 has one row per capital cost allowance
5065
+ * class, all of them line 217.
5066
+ */
5067
+ /** One filed value: the line item id and its figure. */
5068
+ interface T2ScheduleValue {
5069
+ lineItemId: string;
5070
+ value: string | number;
5071
+ }
5072
+ /** One schedule's filed values. `scheduleId` is the form id, e.g. `T2SCH1`. */
5073
+ interface T2ScheduleData {
5074
+ scheduleId: string;
5075
+ values: T2ScheduleValue[];
5076
+ }
5077
+ /** `LLLOOO` — three-digit CRA line, three-digit occurrence. Occurrence is 1-based. */
5078
+ declare function t2LineItemId(line: string, occurrence?: number): string;
5079
+ /**
5080
+ * Split a federal line item id back into its line and occurrence.
5081
+ *
5082
+ * Returns `undefined` for anything that is not six digits, so a caller handed
5083
+ * an Alberta nine-digit id (or a malformed one) drops it rather than reading
5084
+ * the first three characters as a line number and displaying a figure against
5085
+ * a line it does not belong to.
5086
+ */
5087
+ declare function parseT2LineItemId(lineItemId: string): {
5088
+ line: string;
5089
+ occurrence: number;
5090
+ } | undefined;
5091
+ /**
5092
+ * Schedule 1 — the only federal schedule that needs no line table here.
5093
+ *
5094
+ * `Schedule1Line` carries its own `line`, and has since the schedule was built,
5095
+ * precisely because "a reconciling item recorded only as a description with an
5096
+ * amount has nowhere to go on the wire". Reading it back out is the whole job.
5097
+ *
5098
+ * A line may legitimately repeat: the form provides open rows (135, 295, 395,
5099
+ * 495) for items it does not name, and a return can carry several. Those get
5100
+ * successive occurrences rather than being summed, so the paper view can show
5101
+ * each on its own row. A line with no number is skipped — `assertSchedule1Fileable`
5102
+ * is what refuses the return over it, not this.
5103
+ */
5104
+ declare function schedule1Values(r: {
5105
+ additions: readonly {
5106
+ line?: string;
5107
+ amount: number;
5108
+ }[];
5109
+ deductions: readonly {
5110
+ line?: string;
5111
+ amount: number;
5112
+ }[];
5113
+ totalAdditions: number;
5114
+ totalDeductions: number;
5115
+ }): T2ScheduleData;
5116
+ /** Schedule 2 — the donation claim. Only line 210 is a named constant. */
5117
+ declare function schedule2Values(r: {
5118
+ donationsClaimed: number;
5119
+ }): T2ScheduleData;
5120
+ /**
5121
+ * Schedule 7 — the adjusted aggregate investment income that grinds the
5122
+ * business limit. Line 745 is exported by the form module; the rest of Part 2's
5123
+ * working lines are not recorded anywhere, so they are not emitted.
5124
+ */
5125
+ declare function schedule7Values(r: {
5126
+ adjustedAggregateInvestmentIncome: number;
5127
+ }): T2ScheduleData;
5128
+ /**
5129
+ * Schedule 8 — capital cost allowance, one occurrence per class.
5130
+ *
5131
+ * Only the three lines the form module exports are emitted: recapture (213),
5132
+ * terminal loss (215) and the claim (217). The grid's other twenty columns are
5133
+ * either intermediate arithmetic the form shows without numbering, or columns
5134
+ * whose number this package has not recorded — see `SCHEDULE_8_COLUMNS`.
5135
+ */
5136
+ declare function schedule8Values(r: {
5137
+ classes: readonly {
5138
+ recapture: number;
5139
+ terminalLoss: number;
5140
+ ccaClaimed: number;
5141
+ }[];
5142
+ }): T2ScheduleData;
5143
+ /**
5144
+ * Schedule 21 — the two foreign tax credits.
5145
+ *
5146
+ * These land on different jacket lines (632 non-business, 636 business) and the
5147
+ * form module's own doc comment warns that swapping them "is not cosmetic".
5148
+ * Both come from named constants for exactly that reason.
5149
+ */
5150
+ declare function schedule21Values(r: {
5151
+ nonBusinessFtc: number;
5152
+ businessFtc: number;
5153
+ }): T2ScheduleData;
5154
+ /**
5155
+ * Schedule 33 — taxable capital.
5156
+ *
5157
+ * The four figures whose lines the result type states: capital (190), the
5158
+ * investment allowance (490), taxable capital (500) and taxable capital
5159
+ * employed in Canada (790, from the form module's constant — the result type's
5160
+ * comment used to say 690, which is not a line of this form).
5161
+ */
5162
+ declare function schedule33Values(r: {
5163
+ capital: number;
5164
+ investmentAllowance: number;
5165
+ taxableCapital: number;
5166
+ taxableCapitalEmployedInCanada: number;
5167
+ }): T2ScheduleData;
5168
+ /** Schedule 53 — the closing general rate income pool. */
5169
+ declare function schedule53Values(r: {
5170
+ closingGrip: number;
5171
+ }): T2ScheduleData;
5172
+ /**
5173
+ * Schedule 55 — Part III.1 tax.
5174
+ *
5175
+ * The result type states "20% of amount B (s.185.1(1)(a)) — line 190 / line
5176
+ * 290". Two lines for one figure because the form splits by corporation type:
5177
+ * Part 1 (line 190) for CCPCs and deposit insurance corporations, Part 2 (line
5178
+ * 290) for everyone else. Nothing in the result says which part applied, so the
5179
+ * base tax is emitted against BOTH and the paper view shows it under whichever
5180
+ * part the reader is looking at, rather than this file picking one and being
5181
+ * wrong for half of all filers.
5182
+ */
5183
+ declare function schedule55Values(r: {
5184
+ baseTax: number;
5185
+ }): T2ScheduleData;
5186
+ /** The subset of a federal result this file reads. Structural, so it cannot cycle. */
5187
+ interface FederalResultForPayloads {
5188
+ schedule1: Parameters<typeof schedule1Values>[0];
5189
+ netIncomeForTax: number;
5190
+ taxableIncome: number;
5191
+ totalFederalTax: number;
5192
+ donations?: Parameters<typeof schedule2Values>[0];
5193
+ adjustedAggregateInvestmentIncomeSchedule?: Parameters<typeof schedule7Values>[0];
5194
+ cca?: Parameters<typeof schedule8Values>[0];
5195
+ foreignTaxCredit?: Parameters<typeof schedule21Values>[0];
5196
+ taxableCapitalSchedule?: Parameters<typeof schedule33Values>[0];
5197
+ grip?: Parameters<typeof schedule53Values>[0];
5198
+ partIII1?: Parameters<typeof schedule55Values>[0];
5199
+ }
5200
+ /**
5201
+ * Every schedule's filed line items for one computed federal return.
5202
+ *
5203
+ * A schedule that was not computed is ABSENT, not present and empty — the same
5204
+ * rule Alberta's assembler follows. An empty schedule on a return says "this
5205
+ * schedule was completed and everything on it is nil", which is a different
5206
+ * statement from "this schedule does not apply", and only one of them is true.
5207
+ */
5208
+ declare function federalSchedulePayloads(r: FederalResultForPayloads): T2ScheduleData[];
5209
+ //#endregion
6062
5210
  //#region src/t2/rates/corporate-rates.d.ts
6063
5211
  /** The full federal rate/threshold table for one tax year. */
6064
5212
  interface CorpTaxRates {
@@ -6384,33 +5532,374 @@ declare function dayWeightedRate(periodStart: Date | string | number, periodEnd:
6384
5532
  */
6385
5533
  declare function blendProvinceRateTable(baseTable: ProvinceRateTable, changes: ProvincialRateChanges, periodStart: Date | string | number, periodEnd: Date | string | number): ProvinceRateTable;
6386
5534
  //#endregion
6387
- //#region src/t2/schedules/eifel-excluded-entity.d.ts
5535
+ //#region src/t2/schedules/eifel-adjusted-taxable-income.d.ts
6388
5536
  /**
6389
- * EIFELexcessive interest and financing expenses limitation (s.18.2, 18.21).
6390
- *
6391
- * This module determines whether the regime APPLIES. It does not compute the
6392
- * limitation, and that is a deliberate scope decision, not an omission:
5537
+ * ITA subsection 18.2(1) **adjusted taxable income**, the base the EIFEL
5538
+ * ceiling is computed on.
6393
5539
  *
6394
- * · For the overwhelming majority of returns the regime does not apply at
6395
- * all, and establishing that is a complete and correct answer.
6396
- * · For the residual, refusing the return is correct. Computing a restricted
6397
- * amount from a fixed ratio and an adjusted-taxable-income definition we
6398
- * have not built would be worse than refusing — it would be confidently
6399
- * wrong.
5540
+ * `eifel-limitation.ts` took this as a required input because deriving it
5541
+ * partially would produce a plausible figure from an incomplete definition. This
5542
+ * derives it, and is explicit about the components it does and does not cover.
6400
5543
  *
6401
- * ── The excluded-entity test (s.18.2(1)) ─────────────────────────────────
5544
+ * ── What it is ──────────────────────────────────────────────────────────────
6402
5545
  *
6403
- * Three exceptions. Any one of them takes the corporation outside the regime:
5546
+ * An EBITDA-like measure, built from taxable income by adding back the things the
5547
+ * regime is measuring against and removing the things that would double-count.
6404
5548
  *
6405
- * 1. **Small CCPC** a CCPC throughout the year whose taxable capital
6406
- * employed in Canada, TOGETHER WITH associated corporations, is under
6407
- * $50 million. This covers essentially every owner-managed CCPC.
6408
- * 2. **De minimis** — group net interest and financing expenses of
6409
- * $1,000,000 or less.
6410
- * 3. **Domestic** — all or substantially all business carried on in Canada,
6411
- * subject to conditions. Asserted by the preparer; we cannot derive it.
5549
+ * ATI = A + B C
6412
5550
  *
6413
- * Both limbs of test 1 are already in the engine: CCPC status is an existing
5551
+ * A = D E the income base
5552
+ * B the ADD-BACKS
5553
+ * C the REDUCTIONS
5554
+ *
5555
+ * **The add-backs include the interest and financing expenses themselves.** That
5556
+ * is the point of the measure and the thing to hold on to: the ceiling is a
5557
+ * percentage of income computed *before* the very expenses being limited, so a
5558
+ * corporation cannot shrink its own ceiling by borrowing more.
5559
+ *
5560
+ * ── A — the income base (D − E) ─────────────────────────────────────────────
5561
+ *
5562
+ * **D** is taxable income for the year, determined **without regard to** s.18.2(2)
5563
+ * itself, paragraphs 12(1)(l.2) and 111(1)(a.1), and clause 95(2)(f.11)(ii)(D) —
5564
+ * a non-resident uses taxable income earned in Canada on the same basis. The
5565
+ * circularity is deliberate: the limitation cannot be an input to its own base.
5566
+ *
5567
+ * **E** subtracts the year's non-capital loss on the same basis, any amount
5568
+ * claimed under paragraph 111(1)(a) that did not actually reduce taxable income,
5569
+ * and a controlled-foreign-affiliate component (`T × U ÷ V`).
5570
+ *
5571
+ * ── B — the add-backs ───────────────────────────────────────────────────────
5572
+ *
5573
+ * (a) interest and financing expenses for the year
5574
+ * (b) capital cost allowance and resource deductions — paragraph 20(1)(a),
5575
+ * 59.1(a) and subsections 66(4), 66.1(2)/(3), 66.2(2), 66.21(4), 66.4(2),
5576
+ * 66.7(1)-(5)
5577
+ * (c) terminal losses — subsection 20(16)
5578
+ * (d) the taxpayer's share of a partnership's 20(1)(a) and 20(16) deductions
5579
+ * (e) the portion of a paragraph 111(1)(e) limited-partnership-loss claim
5580
+ * attributable to those amounts
5581
+ *
5582
+ * ── C — the reductions ──────────────────────────────────────────────────────
5583
+ *
5584
+ * (a) interest and financing revenues
5585
+ * (b) recapture — subsection 13(1)
5586
+ * (c) the taxpayer's share of a partnership's 13(1) inclusion
5587
+ * (d) resource inclusions — subsections 59(1), 59(3.2), paragraph 59.1(b)
5588
+ * (e) for a corporation, a grossed-up foreign tax credit amount:
5589
+ * **100/28** of what would be deductible under s.126(1), and
5590
+ * the s.126(2) amounts times the relevant factor
5591
+ *
5592
+ * ── Not modelled ────────────────────────────────────────────────────────────
5593
+ *
5594
+ * The trust variant of C(e), and the later paragraphs of B and C dealing with
5595
+ * foreign affiliate income and exempt interest. Each is available as an explicit
5596
+ * `otherAdditions` / `otherReductions` input rather than silently omitted, so a
5597
+ * preparer with one of those amounts can still arrive at the right figure and the
5598
+ * engine does not pretend the definition is shorter than it is.
5599
+ *
5600
+ * Source: `research/sources/legislation/ITA-section-18.2-EIFEL.txt`.
5601
+ *
5602
+ * Pure, whole dollars.
5603
+ */
5604
+ /** C(e)(i) — s.126(1) amounts are grossed up by 100/28. */
5605
+ declare const FOREIGN_TAX_CREDIT_GROSS_UP: number;
5606
+ interface AdjustedTaxableIncomeInput {
5607
+ /**
5608
+ * D — taxable income for the year, determined **without regard to** s.18.2(2),
5609
+ * paragraphs 12(1)(l.2) and 111(1)(a.1), and clause 95(2)(f.11)(ii)(D). For a
5610
+ * non-resident, taxable income earned in Canada on the same basis.
5611
+ *
5612
+ * Signed: a loss year gives a negative figure and the definition permits it.
5613
+ */
5614
+ taxableIncome: number;
5615
+ /** E(a) — the non-capital loss for the year, on the same determinations. */
5616
+ nonCapitalLossForYear?: number;
5617
+ /**
5618
+ * E(a.1) — an amount claimed under paragraph 111(1)(a) **to the extent it did
5619
+ * not reduce** taxable income as determined for D.
5620
+ */
5621
+ lossClaimNotReducingTaxableIncome?: number;
5622
+ /** E(b) — the controlled foreign affiliate component, `T × U ÷ V`. */
5623
+ foreignAccrualPropertyLossComponent?: number;
5624
+ /** B(a) — interest and financing expenses for the year. */
5625
+ interestAndFinancingExpenses?: number;
5626
+ /** B(b) — capital cost allowance, paragraph 20(1)(a). */
5627
+ capitalCostAllowance?: number;
5628
+ /** B(b) — resource deductions under s.59.1(a) and the s.66 series. */
5629
+ resourceDeductions?: number;
5630
+ /** B(c) — terminal losses, subsection 20(16). */
5631
+ terminalLoss?: number;
5632
+ /** B(d) — the taxpayer's share of a partnership's 20(1)(a) / 20(16) deductions. */
5633
+ partnershipCapitalAndTerminalShare?: number;
5634
+ /** B(e) — the attributable portion of a paragraph 111(1)(e) claim. */
5635
+ limitedPartnershipLossPortion?: number;
5636
+ /**
5637
+ * The amount deducted under paragraph 110(1)(k) in computing taxable income —
5638
+ * Schedule 130 Part 2F **line 088**, one of the later B paragraphs this
5639
+ * module's doc comment describes. Named rather than folded into
5640
+ * `otherAdditions` because the engine derives it directly from Schedule 43
5641
+ * (`part-vi-1-deduction.ts`), and a figure the engine computes should be
5642
+ * auditable against its own form line rather than buried in an "other".
5643
+ */
5644
+ partVI1TaxDeduction?: number;
5645
+ /**
5646
+ * Schedule 130 Part 2F **line 089** — the portion of a paragraph 111(1)(a)
5647
+ * loss claim that is derived from IFE (Part 2E amount A). Named for the same
5648
+ * reason as `partVI1TaxDeduction`: `eifel-ife.ts` computes it.
5649
+ */
5650
+ lossPortionDerivedFromIfe?: number;
5651
+ /**
5652
+ * Schedule 130 Part 2F **line 092** — the corporation's loss from activities
5653
+ * funded by a borrowing that produces exempt IFE (Part 1B amount C).
5654
+ */
5655
+ exemptIfeActivityLoss?: number;
5656
+ /** Any further B paragraph this module does not model. */
5657
+ otherAdditions?: number;
5658
+ /** C(a) — interest and financing revenues for the year. */
5659
+ interestAndFinancingRevenues?: number;
5660
+ /** C(b) — recapture included under subsection 13(1). */
5661
+ recapture?: number;
5662
+ /** C(c) — the taxpayer's share of a partnership's 13(1) inclusion. */
5663
+ partnershipRecaptureShare?: number;
5664
+ /** C(d) — inclusions under s.59(1), 59(3.2) or paragraph 59.1(b). */
5665
+ resourceInclusions?: number;
5666
+ /** C(e)(i) — amounts deductible under s.126(1). Grossed up by 100/28 here. */
5667
+ section126_1ForeignTaxCredits?: number;
5668
+ /** C(e)(ii) — amounts deductible under s.126(2), already at the relevant factor. */
5669
+ section126_2GrossedUp?: number;
5670
+ /**
5671
+ * Schedule 130 Part 2F **line 104** — the corporation's income from
5672
+ * activities funded by a borrowing that produces exempt IFE (Part 1B amount
5673
+ * B). The mirror of `exemptIfeActivityLoss` on the reduction side.
5674
+ */
5675
+ exemptIfeActivityIncome?: number;
5676
+ /** Any further C paragraph this module does not model. */
5677
+ otherReductions?: number;
5678
+ }
5679
+ interface AdjustedTaxableIncomeResult {
5680
+ /** A — the income base, D − E. Signed. */
5681
+ incomeBase: number;
5682
+ /** B — total add-backs. */
5683
+ totalAdditions: number;
5684
+ /** C — total reductions. */
5685
+ totalReductions: number;
5686
+ /** A + B − C. **Signed** — the definition permits a negative result. */
5687
+ adjustedTaxableIncome: number;
5688
+ issues: string[];
5689
+ }
5690
+ declare function computeAdjustedTaxableIncome(input: AdjustedTaxableIncomeInput): AdjustedTaxableIncomeResult;
5691
+ //#endregion
5692
+ //#region src/t2/schedules/eifel-capacity.d.ts
5693
+ /**
5694
+ * ITA subsection 18.2(1) — the EIFEL **excess-capacity regime**: excess
5695
+ * capacity, absorbed capacity, cumulative unused excess capacity (CUEC), the
5696
+ * restricted interest and financing expenses (RIFE) deductible under paragraph
5697
+ * 111(1)(a.1), and the RIFE that arises under subsection 111(8).
5698
+ *
5699
+ * The two modules either side of this one were already built and this one was
5700
+ * the gap between them:
5701
+ *
5702
+ * `eifel-adjusted-taxable-income.ts` ATI — Schedule 130 Part 2F
5703
+ * **this module** capacity — Parts 1A, 2G, 2H, 2I, 2J, 2O
5704
+ * `eifel-limitation.ts` the denial — Parts 2K, 2L
5705
+ *
5706
+ * Verified line by line against `research/sources/cra-forms/pdf/T2SCH130-eifel.pdf`
5707
+ * (T2 SCH 130 E, pages 1 and 10-14), rendered with `pdftotext -layout` and read
5708
+ * part by part. Every amount below names the form line it reconstructs.
5709
+ *
5710
+ * ── Why this matters beyond the federal return ───────────────────────────────
5711
+ *
5712
+ * Two of its outputs are the ONLY source for figures other forms ask for by
5713
+ * name, and both were previously typed in by hand because nothing computed
5714
+ * them:
5715
+ *
5716
+ * Part 2G amount F → Schedule 130 line 129 → **AT1 Schedule 21 line 320**
5717
+ * Part 1A amount A → Schedule 130 line 130 → **AT1 Schedule 21 line 330**
5718
+ * Part 2O amount A → **Schedule 4 line 710** → AT1 Schedule 21 line 230
5719
+ *
5720
+ * ── The ordering, which looks circular and is not ───────────────────────────
5721
+ *
5722
+ * The form's cross-references form a strict topological order, not a cycle:
5723
+ *
5724
+ * 2G amount F needs ATI, IFE, IFR (nothing downstream)
5725
+ * 2J amounts A, B need F and received capacity
5726
+ * 2G line 115 needs 2J amount B → excess capacity for the year
5727
+ * 2I amounts A, B need line 115
5728
+ * 2H amount D needs 2I amount B → absorbed capacity
5729
+ * 2I amount C needs 2H amount D → CUEC
5730
+ *
5731
+ * So F is computed BEFORE anything that depends on it, and each later step only
5732
+ * ever reads an earlier one. `computeEifelCapacity` runs them in exactly that
5733
+ * sequence.
5734
+ *
5735
+ * ── The one trap: line 111 reaches around section 257 ───────────────────────
5736
+ *
5737
+ * Line 106 (ATI) is floored at nil — "if negative, enter 0" — and lines 107 and
5738
+ * 119 read that floored figure. Line 111 does **not**: it asks for "the absolute
5739
+ * value of ATI" where "in the absence of section 257, the ATI is a negative
5740
+ * amount". Section 257 is the Act's own no-negative-amounts rule, and the form
5741
+ * deliberately reaches around it here. This module therefore takes the
5742
+ * **signed** ATI and derives both readings, rather than taking the floored one
5743
+ * and losing the information line 111 needs.
5744
+ *
5745
+ * Pure, whole dollars.
5746
+ */
5747
+ /** Part 1A — one eligible group entity the corporation received capacity from. */
5748
+ interface ReceivedCapacityRow {
5749
+ /** Column 1 — name of the eligible group entity. */
5750
+ entityName?: string;
5751
+ /** Column 2 — that entity's account number. */
5752
+ accountNumber?: string;
5753
+ /** Column 3 — that entity's tax year end, ISO `YYYY-MM-DD`. */
5754
+ taxYearEnd?: string;
5755
+ /** 005, column 4 — the amount of capacity received. */
5756
+ amount: number;
5757
+ }
5758
+ /**
5759
+ * Part 2I — one preceding year's excess-capacity vintage. The form provides
5760
+ * exactly three rows (the third, second and first immediately preceding years),
5761
+ * matching the three-year life of unused excess capacity.
5762
+ */
5763
+ interface ExcessCapacityVintage {
5764
+ /** 1 = the first immediately preceding year, 2 = second, 3 = third. */
5765
+ yearsAgo: number;
5766
+ /** 122, column 1 — that year's excess capacity. */
5767
+ excessCapacity: number;
5768
+ /** 123, column 2 — amounts previously transferred under subsection 18.2(4). */
5769
+ previouslyTransferred?: number;
5770
+ /** 124, column 3 — amounts previously absorbed under subsection 18.2(2). */
5771
+ previouslyAbsorbed?: number;
5772
+ }
5773
+ interface EifelCapacityInput {
5774
+ /**
5775
+ * Line 106 from Part 2F — adjusted taxable income, **signed**. Pass
5776
+ * `computeAdjustedTaxableIncome`'s own signed result: lines 107/119 floor it
5777
+ * at nil themselves, and line 111 needs the negative value this would lose.
5778
+ */
5779
+ adjustedTaxableIncome: number;
5780
+ /** Line 045 from Part 2A — the corporation's IFE for the year. */
5781
+ interestAndFinancingExpenses: number;
5782
+ /** Line 072 from Part 2D — the corporation's IFR for the year. */
5783
+ interestAndFinancingRevenues?: number;
5784
+ /** Lines 108/112/120 — the ratio of permissible expenses for the year. */
5785
+ ratioOfPermissibleExpenses: number;
5786
+ /**
5787
+ * Whether a group ratio election under subsection 18.21(2) was made. Part 2G
5788
+ * opens with "If a group ratio election under subsection 18.21(2) has been
5789
+ * made, the excess capacity is nil" — so this suppresses the whole of 2G.
5790
+ */
5791
+ hasGroupRatioElection?: boolean;
5792
+ /** Line 118 — the allocated group ratio amount, where the election was made. */
5793
+ groupRatioAmount?: number;
5794
+ /** Part 1A — the received-capacity table. Its column-4 total is line 130. */
5795
+ receivedCapacity?: readonly ReceivedCapacityRow[];
5796
+ /** Line 128 — RIFE from previous tax years. */
5797
+ rifeFromPreviousYears?: number;
5798
+ /** Part 2I's table — the three preceding years' excess-capacity vintages. */
5799
+ priorYearExcessCapacity?: readonly ExcessCapacityVintage[];
5800
+ /** Line 159 — excess IFE under subsection 18.2(2) (amount B from Part 2L). */
5801
+ excessInterestAndFinancingExpenses?: number;
5802
+ /** Line 160 — partnership IFE add-back under paragraph 12(1)(l.2) (Part 2N). */
5803
+ partnershipIfeAddBack?: number;
5804
+ /** Line 161 — the amount under subclause 95(2)(f.11)(ii)(D)(I) (Part 2M). */
5805
+ clause95FapiAmountI?: number;
5806
+ /** Line 162 — the amount under subclause 95(2)(f.11)(ii)(D)(II) (Part 2M). */
5807
+ clause95FapiAmountII?: number;
5808
+ }
5809
+ interface EifelCapacityResult {
5810
+ /** Amount A — total received capacity. Schedule 130 **line 130**. */
5811
+ receivedCapacity: number;
5812
+ /** Amount A — line 107 × line 108. */
5813
+ permittedAmount: number;
5814
+ /** Line 110 — the amount by which IFR exceeds IFE, floored at nil. */
5815
+ revenueOverExpense: number;
5816
+ /** Line 111 — the absolute value of a negative ATI, otherwise nil. */
5817
+ negativeAtiAbsolute: number;
5818
+ /** Amount B — the lesser of lines 110 and 111. */
5819
+ negativeAtiOffset: number;
5820
+ /** Amount C — amount B × line 112. */
5821
+ negativeAtiOffsetAtRatio: number;
5822
+ /** Amount D — line 109 minus amount C, floored at nil. */
5823
+ revenueCapacity: number;
5824
+ /** Amount E — amount A plus amount D. */
5825
+ totalCapacityBeforeExpenses: number;
5826
+ /**
5827
+ * Amount F — amount E minus line 113, floored at nil. Schedule 130
5828
+ * **line 129**, and the figure AT1 Schedule 21 line 320 asks for by name.
5829
+ */
5830
+ excessCapacityBeforeRife: number;
5831
+ /** Line 115 — excess capacity for the current year (amount F minus line 114). */
5832
+ excessCapacityForYear: number;
5833
+ /** Amount A — line 129 plus line 130. */
5834
+ rifeCapacityAvailable: number;
5835
+ /** Amount B — RIFE deductible under paragraph 111(1)(a.1): lesser of 128 and A. */
5836
+ rifeDeductible: number;
5837
+ /** Amount A — the total of column 4 across the three preceding years. */
5838
+ priorYearUnusedCapacity: number;
5839
+ /** Amount B — CUEC determined as if the year's absorbed capacity were nil. */
5840
+ cumulativeUnusedExcessCapacityBeforeAbsorption: number;
5841
+ /** Amount C — cumulative unused excess capacity. */
5842
+ cumulativeUnusedExcessCapacity: number;
5843
+ /** Amount D — absorbed capacity for the year. */
5844
+ absorbedCapacity: number;
5845
+ /**
5846
+ * Line 136 minus line 137 — received capacity in excess of what was deducted
5847
+ * under paragraph 111(1)(a.1). This is variable **D** of subsection 18.2(2),
5848
+ * which `computeEifelLimitation` takes as `excessReceivedCapacity`.
5849
+ */
5850
+ excessReceivedCapacity: number;
5851
+ /**
5852
+ * Amount A — RIFE for the tax year, the total of lines 159 to 162. The form
5853
+ * directs this to **Schedule 4** (line 710), which AT1 Schedule 21 line 230
5854
+ * then carries in.
5855
+ */
5856
+ rifeForYear: number;
5857
+ issues: string[];
5858
+ }
5859
+ /**
5860
+ * Part 2O on its own — the total of lines 159 to 162.
5861
+ *
5862
+ * Exported separately because of the order the form imposes: line 159 is the
5863
+ * denial from Part 2L, which cannot be computed until Parts 2G-2J have supplied
5864
+ * `excessReceivedCapacity` and `absorbedCapacity` to Part 2K. A caller running
5865
+ * the whole chain therefore computes capacity, then the limitation, then calls
5866
+ * this — rather than computing capacity twice.
5867
+ */
5868
+ declare function computeRifeUnderSubsection111_8(input: {
5869
+ /** Line 159 — excess IFE under subsection 18.2(2) (amount B from Part 2L). */excessInterestAndFinancingExpenses?: number; /** Line 160 — partnership IFE add-back under paragraph 12(1)(l.2). */
5870
+ partnershipIfeAddBack?: number; /** Line 161 — subclause 95(2)(f.11)(ii)(D)(I). */
5871
+ clause95FapiAmountI?: number; /** Line 162 — subclause 95(2)(f.11)(ii)(D)(II). */
5872
+ clause95FapiAmountII?: number;
5873
+ }): number;
5874
+ declare function computeEifelCapacity(input: EifelCapacityInput): EifelCapacityResult;
5875
+ //#endregion
5876
+ //#region src/t2/schedules/eifel-excluded-entity.d.ts
5877
+ /**
5878
+ * EIFEL — excessive interest and financing expenses limitation (s.18.2, 18.21).
5879
+ *
5880
+ * This module determines whether the regime APPLIES. It does not compute the
5881
+ * limitation, and that is a deliberate scope decision, not an omission:
5882
+ *
5883
+ * · For the overwhelming majority of returns the regime does not apply at
5884
+ * all, and establishing that is a complete and correct answer.
5885
+ * · For the residual, refusing the return is correct. Computing a restricted
5886
+ * amount from a fixed ratio and an adjusted-taxable-income definition we
5887
+ * have not built would be worse than refusing — it would be confidently
5888
+ * wrong.
5889
+ *
5890
+ * ── The excluded-entity test (s.18.2(1)) ─────────────────────────────────
5891
+ *
5892
+ * Three exceptions. Any one of them takes the corporation outside the regime:
5893
+ *
5894
+ * 1. **Small CCPC** — a CCPC throughout the year whose taxable capital
5895
+ * employed in Canada, TOGETHER WITH associated corporations, is under
5896
+ * $50 million. This covers essentially every owner-managed CCPC.
5897
+ * 2. **De minimis** — group net interest and financing expenses of
5898
+ * $1,000,000 or less.
5899
+ * 3. **Domestic** — all or substantially all business carried on in Canada,
5900
+ * subject to conditions. Asserted by the preparer; we cannot derive it.
5901
+ *
5902
+ * Both limbs of test 1 are already in the engine: CCPC status is an existing
6414
5903
  * input, and taxable capital comes from Schedule 33. So the common case
6415
5904
  * resolves with no extra preparer input at all.
6416
5905
  *
@@ -6456,7 +5945,13 @@ interface EifelResult {
6456
5945
  exemption: EifelExemption;
6457
5946
  /**
6458
5947
  * True when the regime applies and the limitation is therefore required.
6459
- * The engine does not compute it, so this must block filing.
5948
+ *
5949
+ * `computeFederalT2` computes it — `eifelAdjustedTaxableIncome`,
5950
+ * `eifelCapacity` and `eifelLimitation` on its result — and applies the
5951
+ * denial to Schedule 1 and taxable income. This stays true anyway, because
5952
+ * the computation runs on preparer-supplied figures and several parts of
5953
+ * Schedule 130 are not modelled; `issues` says which. It marks a return for
5954
+ * review, not an uncomputed one.
6460
5955
  */
6461
5956
  requiresLimitation: boolean;
6462
5957
  /** Blocking explanations for the review layer. */
@@ -6470,6 +5965,494 @@ interface EifelThresholds {
6470
5965
  }
6471
5966
  declare function assessEifel(input: EifelInput, thresholds: EifelThresholds): EifelResult;
6472
5967
  //#endregion
5968
+ //#region src/t2/schedules/eifel-ife.d.ts
5969
+ /**
5970
+ * ITA subsection 18.2(1) — **interest and financing expenses** (IFE) and
5971
+ * **interest and financing revenues** (IFR), and the supporting parts that
5972
+ * build them.
5973
+ *
5974
+ * This is the last of the four EIFEL modules, and the one that stops the
5975
+ * regime asking a preparer to hand-total a figure the return already holds:
5976
+ *
5977
+ * `eifel-adjusted-taxable-income.ts` ATI — Part 2F
5978
+ * `eifel-capacity.ts` capacity — Parts 1A, 2G-2J, 2O
5979
+ * `eifel-limitation.ts` the denial — Parts 2K, 2L
5980
+ * **this module** IFE and IFR — Parts 1B-1E, 2A-2E, 2M
5981
+ *
5982
+ * Verified against `research/sources/cra-forms/pdf/T2SCH130-eifel.pdf`
5983
+ * (T2 SCH 130 E, pages 1-8 and 13), rendered with `pdftotext -layout`. Every
5984
+ * amount names the form line it reconstructs.
5985
+ *
5986
+ * ── Why the sub-parts exist at all ──────────────────────────────────────────
5987
+ *
5988
+ * IFE is not "the interest the corporation paid". It reaches into three places
5989
+ * where interest has already been capitalised into something else and pulls it
5990
+ * back out — the capital cost of depreciable property (Part 2B), resource
5991
+ * expense pools (Part 2C), and a partnership's own IFE (Part 1E) — then nets
5992
+ * off the amounts that reduce the cost of funding (variable B). A preparer
5993
+ * totalling "interest expense" from the income statement would miss all three.
5994
+ *
5995
+ * ── The one ordering constraint ─────────────────────────────────────────────
5996
+ *
5997
+ * Part 2M's first table needs amount G from Part 2K — the proportion denied —
5998
+ * so it cannot run until the limitation has. `computeClause95Amounts` therefore
5999
+ * takes that proportion as an argument, the same way Part 2O takes the denial.
6000
+ * Everything else here runs before the limitation, because the limitation is
6001
+ * computed FROM it.
6002
+ *
6003
+ * Whole dollars, pure.
6004
+ */
6005
+ /** Part 1C/1D column 1 — who the other party to the financing is. */
6006
+ type EifelCounterpartyRelationship = 'canadian-arm-length' | 'canadian-non-arm-length' | 'non-resident-arm-length' | 'non-resident-non-arm-length';
6007
+ /**
6008
+ * One public-sector agreement whose borrowing produces exempt IFE. Exempt IFE
6009
+ * is left OUT of the IFE total entirely (see variable A's own opening words),
6010
+ * but the income and losses of the activities it funded still adjust ATI.
6011
+ */
6012
+ interface ExemptIfeRow {
6013
+ /** 007 — the public sector authority the agreement is with. */
6014
+ authorityName?: string;
6015
+ /** 008 — principal amount of the borrowing entered into under the agreement. */
6016
+ principalAmount?: number;
6017
+ /** 009, column 3 — IFE incurred on that amount. */
6018
+ ifeIncurred?: number;
6019
+ /** 010, column 4 — corporation income from the activities it funded. */
6020
+ incomeFromFundedActivities?: number;
6021
+ /** 011, column 5 — corporation loss from those activities, as a positive amount. */
6022
+ lossFromFundedActivities?: number;
6023
+ }
6024
+ interface ExemptIfeResult {
6025
+ /** Amount A — total of column 3. */
6026
+ totalExemptIfe: number;
6027
+ /** Amount B — total of column 4. Part 2F **line 104** (an ATI reduction). */
6028
+ incomeFromExemptActivities: number;
6029
+ /** Amount C — total of column 5. Part 2F **line 092** (an ATI addition). */
6030
+ lossFromExemptActivities: number;
6031
+ }
6032
+ declare function computeExemptIfe(rows: readonly ExemptIfeRow[]): ExemptIfeResult;
6033
+ interface BorrowingRow {
6034
+ relationship?: EifelCounterpartyRelationship;
6035
+ /** 012 — total principal of borrowings at any point in the year. */
6036
+ principalAmount?: number;
6037
+ /** 013 — total notional of derivatives entered in respect of them. */
6038
+ derivativeNotional?: number;
6039
+ /** 014, column 4 — paragraph (a) of variable A. Part 2A **line 027**. */
6040
+ interestPaidOrPayable?: number;
6041
+ /** 015, column 5 — paragraph (e) of variable A. Part 2A **line 033**. */
6042
+ fundingCostAmounts?: number;
6043
+ /** 016, column 6 — paragraph (a) of variable B. Part 2A **line 042**. */
6044
+ costReducingAmounts?: number;
6045
+ }
6046
+ interface BorrowingsResult {
6047
+ /** Amount A → line 027. */
6048
+ interestPaidOrPayable: number;
6049
+ /** Amount B → line 033. */
6050
+ fundingCostAmounts: number;
6051
+ /** Amount C → line 042. */
6052
+ costReducingAmounts: number;
6053
+ }
6054
+ declare function computeBorrowings(rows: readonly BorrowingRow[]): BorrowingsResult;
6055
+ interface LoanRow {
6056
+ relationship?: EifelCounterpartyRelationship;
6057
+ /** 017 — total principal of loans at any point in the year. */
6058
+ principalAmount?: number;
6059
+ /** 018 — total notional of derivatives entered in respect of them. */
6060
+ derivativeNotional?: number;
6061
+ /** 019, column 4 — paragraph (d) of variable A of IFR. Part 2D **line 061**. */
6062
+ returnAmounts?: number;
6063
+ /** 020, column 5 — paragraph (a) of variable B of IFR. Part 2D **line 066**. */
6064
+ returnReducingAmounts?: number;
6065
+ }
6066
+ interface LoansResult {
6067
+ /** Amount A → line 061. */
6068
+ returnAmounts: number;
6069
+ /** Amount B → line 066. */
6070
+ returnReducingAmounts: number;
6071
+ }
6072
+ declare function computeLoans(rows: readonly LoanRow[]): LoansResult;
6073
+ interface PartnershipIfeRow {
6074
+ /** 021 — the partnership's name. */
6075
+ partnershipName?: string;
6076
+ /** 022 — its account number; blank where the partnership is non-resident. */
6077
+ accountNumber?: string;
6078
+ /** 023, column 3 — the corporation's share of variable A of the partnership's IFE. */
6079
+ shareOfPartnershipIfe?: number;
6080
+ /** 024, column 4 — the portion of column 3 to which paragraph 12(1)(l.1) applies. */
6081
+ portionUnderParagraph12_1_l1?: number;
6082
+ /** 025, column 5 — the portion not deductible because of subsection 96(2.1). */
6083
+ portionDeniedBySubsection96_2_1?: number;
6084
+ }
6085
+ interface PartnershipIfeResult {
6086
+ rows: {
6087
+ partnershipName?: string;
6088
+ includedAmount: number;
6089
+ }[];
6090
+ /**
6091
+ * Amount A — total of column 6. Feeds THREE places: Part 2A **line 039**,
6092
+ * Part 2L **line 142** (where it is removed again from the denial base) and
6093
+ * Part 2N **line 156** (the 12(1)(l.2) add-back).
6094
+ */
6095
+ totalIncluded: number;
6096
+ }
6097
+ declare function computePartnershipIfe(rows: readonly PartnershipIfeRow[]): PartnershipIfeResult;
6098
+ interface CapitalizedIfeRow {
6099
+ /** 046 — the CCA class the capitalized interest sits in. */
6100
+ ccaClass?: string;
6101
+ /** 047, column 2 — IFE in the UCC at the beginning of the year. */
6102
+ ifeInOpeningUcc?: number;
6103
+ /** 048, column 3 — IFE in acquisitions, adjustments, transfers and proceeds. */
6104
+ ifeInAcquisitionsAndDispositions?: number;
6105
+ /** 050, column 5 — IFE in the terminal loss (note 2 on the form). */
6106
+ ifeInTerminalLoss?: number;
6107
+ /** 051, column 6 — IFE in the CCA claimed. Capped at column 4. */
6108
+ ifeInCca?: number;
6109
+ }
6110
+ interface CapitalizedIfeResult {
6111
+ rows: {
6112
+ ccaClass?: string;
6113
+ ifeInUcc: number;
6114
+ ifeInCca: number;
6115
+ closingIfeInUcc: number;
6116
+ }[];
6117
+ /** Amount A — total of column 5. Part 2A **line 032** (terminal loss). */
6118
+ totalIfeInTerminalLoss: number;
6119
+ /** Amount B — total of column 6. Part 2A **line 030** (CCA). */
6120
+ totalIfeInCca: number;
6121
+ issues: string[];
6122
+ }
6123
+ declare function computeCapitalizedIfe(rows: readonly CapitalizedIfeRow[]): CapitalizedIfeResult;
6124
+ /** The ten pools Part 2C lists, in the form's own row order. */
6125
+ type ResourceIfePool = 'ccee-regular' | 'ccee-successor' | 'ccde-regular' | 'ccde-successor' | 'ccogpe-regular' | 'ccogpe-successor' | 'fede-regular' | 'fede-successor' | 'cfre-regular' | 'cfre-successor';
6126
+ interface ResourceIfeRow {
6127
+ pool: ResourceIfePool;
6128
+ /** 053, column 2 — IFE in the opening balance. */
6129
+ ifeInOpeningBalance?: number;
6130
+ /** 054, column 3 — IFE added to or deducted from the pool during the year. */
6131
+ ifeAddedOrDeducted?: number;
6132
+ /** 056, column 5 — IFE in the current-year claim. Capped at column 4. */
6133
+ ifeInCurrentYearClaim?: number;
6134
+ }
6135
+ interface ResourceIfeResult {
6136
+ rows: {
6137
+ pool: ResourceIfePool;
6138
+ ifeAvailable: number;
6139
+ ifeClaimed: number;
6140
+ closing: number;
6141
+ }[];
6142
+ /** Amount A — total of column 5. Part 2A **line 031**. */
6143
+ totalIfeInResourceClaims: number;
6144
+ issues: string[];
6145
+ }
6146
+ declare function computeResourceIfe(rows: readonly ResourceIfeRow[]): ResourceIfeResult;
6147
+ interface InterestAndFinancingExpensesInput {
6148
+ /** 027 — interest paid or payable on a borrowing (Part 1C amount A). */
6149
+ interestOnBorrowings?: number;
6150
+ /** 028 — interest paid or payable, other. */
6151
+ otherInterest?: number;
6152
+ /** 029 — amounts deductible under the subsection 20(1)(e) series. */
6153
+ subsection20_1_eAmounts?: number;
6154
+ /** 030 — IFE claimed as CCA (Part 2B amount B). */
6155
+ ifeInCca?: number;
6156
+ /** 031 — IFE claimed as resource expenses (Part 2C amount A). */
6157
+ ifeInResourceExpenses?: number;
6158
+ /** 032 — IFE claimed as a terminal loss (Part 2B amount A). */
6159
+ ifeInTerminalLoss?: number;
6160
+ /** 033 — funding-cost amounts deductible in the year (Part 1C amount B). */
6161
+ fundingCostAmounts?: number;
6162
+ /** 034 — a loss deductible in the year under such an arrangement. */
6163
+ fundingCostLoss?: number;
6164
+ /** 035 — a capital loss reducing paragraph 3(b) or taxable income. */
6165
+ fundingCostCapitalLoss?: number;
6166
+ /** 036 — an expense or fee giving rise to an amount included in IFE. */
6167
+ feeGivingRiseToIfe?: number;
6168
+ /** 037 — an expense or fee giving rise to an amount reducing IFE. */
6169
+ feeReducingIfe?: number;
6170
+ /** 038 — a lease financing amount. */
6171
+ leaseFinancingAmount?: number;
6172
+ /** 039 — the corporation's share of a partnership's IFE (Part 1E amount A). */
6173
+ partnershipShare?: number;
6174
+ /** 040 — a denied 111(1)(e) claim from a preceding year attributable to IFE. */
6175
+ reinstatedPartnershipLoss?: number;
6176
+ /**
6177
+ * 041 — a controlled foreign affiliate's relevant affiliate interest and
6178
+ * financing expenses (RAIFE), to the extent of the specified participating
6179
+ * percentage. Also Part 2L **line 143**, where it is removed again.
6180
+ */
6181
+ affiliateRaife?: number;
6182
+ /** 042 — amounts received or receivable (Part 1C amount C). */
6183
+ costReducingAmounts?: number;
6184
+ /** 043 — a gain included in income. */
6185
+ costReducingGain?: number;
6186
+ /** 044 — the corporation's share of such an amount in a partnership. */
6187
+ costReducingPartnershipShare?: number;
6188
+ }
6189
+ interface InterestAndFinancingExpensesResult {
6190
+ /**
6191
+ * Amount A — the total of lines 027 to 041. Part 2K **line 139** and Part 2L
6192
+ * **line 141**: the denial is a proportion OF THIS, not of the net figure.
6193
+ */
6194
+ variableA: number;
6195
+ /** Amount B — the total of lines 042 to 044. */
6196
+ variableB: number;
6197
+ /** 045 — total IFE, amount A minus amount B, floored at nil. */
6198
+ totalIfe: number;
6199
+ }
6200
+ declare function computeInterestAndFinancingExpenses(input: InterestAndFinancingExpensesInput): InterestAndFinancingExpensesResult;
6201
+ interface InterestAndFinancingRevenuesInput {
6202
+ /** 058 — interest received or receivable. */
6203
+ interestReceived?: number;
6204
+ /** 059 — amounts included under subsection 12(9) or section 17.1. */
6205
+ subsection12_9Amounts?: number;
6206
+ /** 060 — a guarantee or credit-support fee included in income. */
6207
+ guaranteeFees?: number;
6208
+ /** 061 — amounts received under a financing arrangement (Part 1D amount A). */
6209
+ returnAmounts?: number;
6210
+ /** 062 — a gain included in income. */
6211
+ returnGain?: number;
6212
+ /** 063 — a lease financing amount included in income. */
6213
+ leaseFinancingAmount?: number;
6214
+ /** 064 — the corporation's share of a partnership's IFR. */
6215
+ partnershipShare?: number;
6216
+ /** 065 — a controlled foreign affiliate's relevant affiliate IFR. */
6217
+ affiliateRaifr?: number;
6218
+ /** 066 — amounts paid or payable under the arrangement (Part 1D amount B). */
6219
+ returnReducingAmounts?: number;
6220
+ /** 067 — a deductible loss. */
6221
+ returnReducingLoss?: number;
6222
+ /** 068 — a capital loss reducing the paragraph 3(b) amount. */
6223
+ returnReducingCapitalLoss?: number;
6224
+ /** 069 — the corporation's share of such an amount in a partnership. */
6225
+ returnReducingPartnershipShare?: number;
6226
+ /** 070 — IFR sheltered from Canadian tax by a foreign tax credit or deduction. */
6227
+ shelteredByForeignTaxRelief?: number;
6228
+ /** 071 — amounts in variable A that are exempt from Part I tax. */
6229
+ exemptFromPartITax?: number;
6230
+ }
6231
+ interface InterestAndFinancingRevenuesResult {
6232
+ /** Amount A — the total of lines 058 to 065. */
6233
+ variableA: number;
6234
+ /** Amount B — the total of lines 066 to 071. */
6235
+ variableB: number;
6236
+ /** 072 — total IFR, amount A minus amount B, floored at nil. */
6237
+ totalIfr: number;
6238
+ }
6239
+ declare function computeInterestAndFinancingRevenues(input: InterestAndFinancingRevenuesInput): InterestAndFinancingRevenuesResult;
6240
+ /**
6241
+ * The portion of a non-capital loss claimed under paragraph 111(1)(a) that is
6242
+ * attributable to IFE, which is added back to ATI. Per-vintage, because each
6243
+ * loss year carries its own IFE proportion.
6244
+ */
6245
+ interface LossPortionFromIfeRow {
6246
+ /** 073, column 1 — the tax year the non-capital loss arose in. */
6247
+ taxYearOfOrigin?: string;
6248
+ /** 074, column 2 — the non-capital loss, variable J(i). */
6249
+ nonCapitalLoss: number;
6250
+ /** 075, column 3 — the amount determined under (ii) of variable J. */
6251
+ variableJSecondAmount?: number;
6252
+ /** 077, column 5 — the amount actually deducted under paragraph 111(1)(a). */
6253
+ amountDeducted?: number;
6254
+ }
6255
+ interface LossPortionFromIfeResult {
6256
+ rows: {
6257
+ taxYearOfOrigin?: string;
6258
+ variableJ: number;
6259
+ attributableToIfe: number;
6260
+ }[];
6261
+ /** Amount A — total of column 6. Part 2F **line 089**. */
6262
+ totalAttributableToIfe: number;
6263
+ issues: string[];
6264
+ }
6265
+ declare function computeLossPortionFromIfe(rows: readonly LossPortionFromIfeRow[]): LossPortionFromIfeResult;
6266
+ /**
6267
+ * The amount actually denied, and the amount actually added back on Schedule 1
6268
+ * line 251.
6269
+ *
6270
+ * This is NOT simply "the shortfall". Part 2K computes a **proportion** (amount
6271
+ * G) and Part 2L applies it to a base that deliberately excludes two things
6272
+ * already counted elsewhere:
6273
+ *
6274
+ * 141 variable A of IFE
6275
+ * 142 less the partnership share (Part 1E amount A) — denied instead through
6276
+ * the paragraph 12(1)(l.2) add-back in Part 2N
6277
+ * 143 less a CFA's relevant affiliate IFE — denied instead through
6278
+ * clause 95(2)(f.11)(ii)(D) in Part 2M
6279
+ *
6280
+ * With neither of those present the base is variable A and the result equals
6281
+ * the raw shortfall, which is why a simple corporation sees no difference. With
6282
+ * either present, using the shortfall directly double-counts the denial.
6283
+ */
6284
+ declare function computeExcessIfe(input: {
6285
+ /** 141 — variable A of IFE (Part 2A amount A). */variableAOfIfe: number; /** 142 — the partnership share (Part 1E amount A). */
6286
+ partnershipShare?: number; /** 143 — a CFA's relevant affiliate IFE (Part 2A line 041). */
6287
+ affiliateRaife?: number; /** Amount G from Part 2K — the proportion denied. */
6288
+ deniedProportion: number;
6289
+ }): {
6290
+ base: number;
6291
+ excessIfe: number;
6292
+ };
6293
+ /**
6294
+ * Part 2N line 158 — the partnership IFE add-back under paragraph 12(1)(l.2):
6295
+ * the Part 1E total (line 156) at the Part 2K proportion (line 157). Feeds
6296
+ * Schedule 1 **line 252** and Part 2O **line 160**.
6297
+ */
6298
+ declare function computePartnershipIfeAddBack(partnershipShare: number, deniedProportion: number): number;
6299
+ interface Clause95DeniedRow {
6300
+ /** 144 — the controlled foreign affiliate's name. */
6301
+ affiliateName?: string;
6302
+ /** 145, column 2 — variable A of the definition of IFE for the affiliate. */
6303
+ variableAForAffiliate: number;
6304
+ /**
6305
+ * 148, column 5 — the corporation's specified participating percentage for
6306
+ * the affiliate's tax year, as a FRACTION (0.4, not 40).
6307
+ */
6308
+ specifiedParticipatingPercentage?: number;
6309
+ }
6310
+ interface Clause95IncludedRow {
6311
+ /** 151 — the affiliate that is a member of the partnership. */
6312
+ affiliateName?: string;
6313
+ /** 152, column 2 — the amount under subclause 95(2)(f.11)(ii)(D)(II) in the CFA's FAPI. */
6314
+ amountInAffiliateFapi: number;
6315
+ /** 153, column 3 — specified participating percentage, as a FRACTION. */
6316
+ specifiedParticipatingPercentage?: number;
6317
+ }
6318
+ interface Clause95Result {
6319
+ /** 150 — total of the first table's column 6. Part 2O **line 161**. */
6320
+ deniedUnderSubclauseI: number;
6321
+ /** 155 — total of the second table's column 4. Part 2O **line 162**. */
6322
+ includedUnderSubclauseII: number;
6323
+ }
6324
+ /**
6325
+ * @param deniedProportion Amount G from Part 2K — the proportion of each
6326
+ * expense denied under subsection 18.2(2). This is why Part 2M runs after the
6327
+ * limitation rather than before it.
6328
+ */
6329
+ declare function computeClause95Amounts(denied: readonly Clause95DeniedRow[], included: readonly Clause95IncludedRow[], deniedProportion: number): Clause95Result;
6330
+ //#endregion
6331
+ //#region src/t2/schedules/eifel-limitation.d.ts
6332
+ /**
6333
+ * ITA subsection 18.2(2) — the excessive interest and financing expenses
6334
+ * limitation itself.
6335
+ *
6336
+ * `eifel-excluded-entity.ts` decides **whether** the regime applies. This decides
6337
+ * **how much** it denies, which was previously left unbuilt on the grounds that
6338
+ * computing it from an unbuilt definition would be confidently wrong.
6339
+ *
6340
+ * ── The provision ───────────────────────────────────────────────────────────
6341
+ *
6342
+ * s.18.2(2) denies a *proportion* of each interest and financing expense:
6343
+ *
6344
+ * (A − (B + C + D + E)) ÷ F
6345
+ *
6346
+ * A the taxpayer's interest and financing expenses for the year
6347
+ * B the group-ratio amount under s.18.21(2) where that applies, otherwise
6348
+ * **G × H** — the ratio of permissible expenses times adjusted taxable income
6349
+ * C the taxpayer's interest and financing revenues for the year
6350
+ * D received capacity, to the extent it exceeds the amount deductible under
6351
+ * paragraph 111(1)(a.1)
6352
+ * E absorbed capacity
6353
+ * F ordinarily the same figure as A
6354
+ *
6355
+ * Because F is A in the ordinary case, the *amount* denied is simply
6356
+ *
6357
+ * denied = A − (B + C + D + E), floored at nil
6358
+ *
6359
+ * which is the form this module computes, while still reporting the proportion —
6360
+ * the statute denies a fraction of *each* expense, and a preparer allocating the
6361
+ * denial across expense lines needs the fraction rather than the total.
6362
+ *
6363
+ * ── The ratio of permissible expenses ───────────────────────────────────────
6364
+ *
6365
+ * Keyed off when the taxation year **BEGINS**, not when it ends:
6366
+ *
6367
+ * begins on or after 2023-10-01 and before 2024-01-01 → **40%**
6368
+ * begins on or after 2024-01-01 → **30%**
6369
+ *
6370
+ * The 40% band is transitional and narrow — one quarter — and it does **not**
6371
+ * apply when determining cumulative unused excess capacity for a year beginning
6372
+ * on or after 1 January 2024. That carve-out is not modelled; excess-capacity
6373
+ * carry-forward is a separate mechanism this module does not compute.
6374
+ *
6375
+ * ── What this module does NOT compute ───────────────────────────────────────
6376
+ *
6377
+ * **Adjusted taxable income** is an input to THIS module, not a derivation — it
6378
+ * is a build-up from taxable income through a dozen add-backs and reductions,
6379
+ * and deriving it partially here would produce a plausible number from an
6380
+ * incomplete definition. It is therefore **required**, and an absent one denies
6381
+ * nothing while saying so. `eifel-adjusted-taxable-income.ts` derives it
6382
+ * (Schedule 130 Part 2F), and `computeFederalT2` feeds that result in.
6383
+ *
6384
+ * Likewise the received and absorbed capacity amounts, which come from the
6385
+ * excess-capacity regime — `eifel-capacity.ts` computes those (Parts 1A and
6386
+ * 2G-2J), and the engine threads them in as `excessReceivedCapacity` (Part 2K
6387
+ * amount C) and `absorbedCapacity` (Part 2H amount D). The group-ratio election
6388
+ * under s.18.21 remains a preparer assertion.
6389
+ *
6390
+ * Source: `research/sources/legislation/ITA-section-18.2-EIFEL.txt`.
6391
+ *
6392
+ * Pure, whole dollars.
6393
+ */
6394
+ /** The ratio bands, keyed off the taxation year START. */
6395
+ declare const EIFEL_TRANSITIONAL_RATIO = 0.4;
6396
+ declare const EIFEL_STANDARD_RATIO = 0.3;
6397
+ /** The regime's first day — years beginning before this are outside it. */
6398
+ declare const EIFEL_FIRST_YEAR_START = "2023-10-01";
6399
+ /** The transitional 40% band ends when years beginning in 2024 start. */
6400
+ declare const EIFEL_STANDARD_RATIO_FROM = "2024-01-01";
6401
+ interface EifelLimitationInput {
6402
+ /** A — interest and financing expenses for the year. */
6403
+ interestAndFinancingExpenses: number;
6404
+ /**
6405
+ * H — adjusted taxable income. **Required**: the definition is a large build-up
6406
+ * this module does not derive, and an absent one denies nothing rather than
6407
+ * being assumed.
6408
+ */
6409
+ adjustedTaxableIncome?: number;
6410
+ /** C — interest and financing revenues for the year. */
6411
+ interestAndFinancingRevenues?: number;
6412
+ /**
6413
+ * D — received capacity in excess of the amount deducted under paragraph
6414
+ * 111(1)(a.1).
6415
+ */
6416
+ excessReceivedCapacity?: number;
6417
+ /** E — absorbed capacity for the year. */
6418
+ absorbedCapacity?: number;
6419
+ /**
6420
+ * B — the group ratio amount under s.18.21(2), where the election was made.
6421
+ * Supplying it REPLACES the ratio × adjusted taxable income computation, as the
6422
+ * provision directs.
6423
+ */
6424
+ groupRatioAmount?: number;
6425
+ /** Taxation year start, ISO `YYYY-MM-DD` — selects the ratio band. */
6426
+ taxYearStart: string;
6427
+ }
6428
+ interface EifelLimitationResult {
6429
+ /** G — the ratio of permissible expenses that applied. */
6430
+ ratioOfPermissibleExpenses: number;
6431
+ /** B — the permitted amount, however it was arrived at. */
6432
+ permittedAmount: number;
6433
+ /** Whether B came from the group ratio election rather than ratio × income. */
6434
+ usedGroupRatio: boolean;
6435
+ /** B + C + D + E — everything that shelters the expenses. */
6436
+ totalShelter: number;
6437
+ /** The amount denied, floored at nil. */
6438
+ deniedAmount: number;
6439
+ /**
6440
+ * The proportion of EACH expense that is denied. The statute denies a fraction
6441
+ * of every interest and financing expense, so a preparer allocating the denial
6442
+ * across expense lines needs this, not just the total.
6443
+ */
6444
+ deniedProportion: number;
6445
+ /** Interest and financing expenses that remain deductible. */
6446
+ deductibleAmount: number;
6447
+ issues: string[];
6448
+ }
6449
+ /**
6450
+ * The ratio of permissible expenses for a year beginning on `taxYearStart`.
6451
+ * Returns 0 for a year beginning before the regime applies at all.
6452
+ */
6453
+ declare function ratioOfPermissibleExpenses(taxYearStart: string): number;
6454
+ declare function computeEifelLimitation(input: EifelLimitationInput): EifelLimitationResult;
6455
+ //#endregion
6473
6456
  //#region src/t2/schedules/part-vi-1-deduction.d.ts
6474
6457
  /**
6475
6458
  * ITA paragraph 110(1)(k) — the deduction against taxable income for Part VI.1 tax.
@@ -7708,7 +7691,14 @@ interface TaxableCapitalResult {
7708
7691
  investmentAllowance: number;
7709
7692
  /** Line 500 — taxable capital for the year (≥ 0). */
7710
7693
  taxableCapital: number;
7711
- /** Line 690 — taxable capital employed in Canada (feeds the Schedule 7 grind). */
7694
+ /**
7695
+ * Line 790 — taxable capital employed in Canada (feeds the Schedule 7 grind).
7696
+ *
7697
+ * This comment said 690, which is not a line of Schedule 33 at all. The form
7698
+ * prints "Taxable capital employed in Canada (line 701 minus amount E)"
7699
+ * against 790, and `SCHEDULE_33_TAXABLE_CAPITAL_IN_CANADA_LINE` has always
7700
+ * said so — the two disagreed and nothing checked.
7701
+ */
7712
7702
  taxableCapitalEmployedInCanada: number;
7713
7703
  /** True when > $10M — Schedule 33 must be filed (large-corporation test). */
7714
7704
  filingRequired: boolean;
@@ -7748,14 +7738,19 @@ declare function computeTaxableCapital(input?: TaxableCapitalInput): TaxableCapi
7748
7738
  * short-term preferred dividends first (the statutory order — which is also
7749
7739
  * the highest band, so it is taxpayer-favourable; the two do not conflict).
7750
7740
  *
7751
- * ── Not yet modelled ─────────────────────────────────────────────────────
7741
+ * ── The s.110(1)(k) deduction lives next door ─────────────────────────────
7742
+ *
7743
+ * Part VI.1 tax paid is deductible in computing taxable income at a statutory
7744
+ * multiple of the tax. That multiple is not applied HERE, but it is applied:
7745
+ * `part-vi-1-deduction.ts` carries the three bands with the Act quoted beside
7746
+ * each, and `computeFederalT2` runs it on this schedule's `partVI1Tax` and
7747
+ * files the result on jacket line 325.
7752
7748
  *
7753
- * Part VI.1 tax paid is deductible in computing taxable income (s.110(1)(k))
7754
- * at a statutory multiple of the tax. That multiple is NOT applied here: it
7755
- * has not been transcribed from the Act, and guessing it would misstate
7756
- * taxable income in the opposite direction from the error this schedule fixes.
7757
- * `deductionPending` is returned true so the caller can surface it. See
7758
- * `research/cra-schedules/S43-part-vi-1.md` [PIN].
7749
+ * This section used to say the multiple "has not been transcribed from the Act"
7750
+ * and that the deduction was not applied. Both were true once and neither is
7751
+ * now. The stale note propagated: a paper Form View repeated it to preparers as
7752
+ * a live gap, which invites someone to claim the deduction by hand on top of
7753
+ * the one the engine already took. See `research/cra-schedules/S43-part-vi-1.md`.
7759
7754
  *
7760
7755
  * Whole dollars, pure, no I/O.
7761
7756
  */
@@ -7799,8 +7794,15 @@ interface Schedule43Result {
7799
7794
  /** Total Part VI.1 tax payable. */
7800
7795
  partVI1Tax: number;
7801
7796
  /**
7802
- * True when tax is payable and the s.110(1)(k) deduction has therefore been
7803
- * earned but is not yet reflected in taxable income.
7797
+ * True when Part VI.1 tax is payable, and therefore a s.110(1)(k) deduction
7798
+ * has been earned on it.
7799
+ *
7800
+ * The name is historical: it meant "earned but NOT yet applied" back when the
7801
+ * statutory multiple had not been transcribed. It is applied now, by
7802
+ * `computePartVI1Deduction` on jacket line 325, so this reads as "there is a
7803
+ * deduction to apply", not "something is outstanding". Kept rather than
7804
+ * renamed because it is published API; treat it as a signal that the
7805
+ * deduction path should have run, not as a warning to a preparer.
7804
7806
  */
7805
7807
  deductionPending: boolean;
7806
7808
  /** Blocking/advisory problems — e.g. an associated group with no agreement. */
@@ -8527,6 +8529,64 @@ interface FederalT2Input {
8527
8529
  */
8528
8530
  eifel?: Omit<EifelInput, 'taxYearStart' | 'isCcpc'> & {
8529
8531
  isCcpc?: boolean;
8532
+ /**
8533
+ * Schedule 130 Part 2A line 045 — the corporation's gross interest and
8534
+ * financing expenses. Distinct from `netInterestAndFinancingExpenses`,
8535
+ * which is the group's NET figure used only for the de-minimis
8536
+ * excluded-entity test. Without this the limitation has no base to work
8537
+ * on and nothing is denied.
8538
+ */
8539
+ interestAndFinancingExpenses?: number; /** Part 2D line 072 — the corporation's interest and financing revenues. */
8540
+ interestAndFinancingRevenues?: number;
8541
+ /**
8542
+ * Part 2F line 106 — adjusted taxable income, supplied directly. Wins over
8543
+ * the derivation below, same explicit-over-detail precedence as Schedule 7's
8544
+ * `aaii`/`aaiiDetail` pair.
8545
+ */
8546
+ adjustedTaxableIncome?: number;
8547
+ /**
8548
+ * Part 2F — the components of the ATI build-up this engine cannot derive
8549
+ * from the return (partnership shares, foreign affiliate amounts, exempt-IFE
8550
+ * activity, foreign tax credit gross-ups). Taxable income, the year's
8551
+ * non-capital loss, IFE, CCA, resource deductions, terminal loss, the
8552
+ * 110(1)(k) deduction, IFR and recapture are all derived from the return
8553
+ * itself and must NOT be repeated here.
8554
+ */
8555
+ adjustedTaxableIncomeDetail?: Omit<AdjustedTaxableIncomeInput, 'taxableIncome' | 'nonCapitalLossForYear' | 'lossClaimNotReducingTaxableIncome' | 'interestAndFinancingExpenses' | 'capitalCostAllowance' | 'resourceDeductions' | 'terminalLoss' | 'partVI1TaxDeduction' | 'interestAndFinancingRevenues' | 'recapture'>; /** Whether a group ratio election under subsection 18.21(2) was made. */
8556
+ hasGroupRatioElection?: boolean; /** Part 2G line 118 / Part 2K line 132 — the allocated group ratio amount. */
8557
+ groupRatioAmount?: number; /** Part 1A — the received-capacity table; its total is line 130. */
8558
+ receivedCapacity?: readonly ReceivedCapacityRow[]; /** Part 2J line 128 — restricted interest and financing expenses carried forward. */
8559
+ rifeFromPreviousYears?: number; /** Part 2I — the three preceding years' excess-capacity vintages. */
8560
+ priorYearExcessCapacity?: readonly ExcessCapacityVintage[];
8561
+ /**
8562
+ * Part 2N line 158 — partnership IFE add-back (Schedule 1 line 252).
8563
+ * DERIVED from `partnershipIfe` below × the Part 2K proportion when that
8564
+ * table is supplied; this overrides the derivation.
8565
+ */
8566
+ partnershipIfeAddBack?: number; /** Part 2M line 150 — subclause 95(2)(f.11)(ii)(D)(I). Derived from `clause95Denied`. */
8567
+ clause95FapiAmountI?: number; /** Part 2M line 155 — subclause 95(2)(f.11)(ii)(D)(II). Derived from `clause95Included`. */
8568
+ clause95FapiAmountII?: number; /** Part 1B — borrowings under a public-sector agreement producing exempt IFE. */
8569
+ exemptIfe?: readonly ExemptIfeRow[]; /** Part 1C — borrowings and other financings. Feeds lines 027/033/042. */
8570
+ borrowings?: readonly BorrowingRow[]; /** Part 1D — loans and other financings. Feeds lines 061/066. */
8571
+ loans?: readonly LoanRow[]; /** Part 1E — IFE allocated from a partnership. Feeds lines 039/142/156. */
8572
+ partnershipIfe?: readonly PartnershipIfeRow[]; /** Part 2B — IFE capitalized into depreciable property. Feeds lines 030/032. */
8573
+ capitalizedIfe?: readonly CapitalizedIfeRow[]; /** Part 2C — IFE inside resource expense pools. Feeds line 031. */
8574
+ resourceIfe?: readonly ResourceIfeRow[]; /** Part 2E — the IFE-derived portion of a 111(1)(a) loss claim. Feeds line 089. */
8575
+ lossPortionFromIfe?: readonly LossPortionFromIfeRow[];
8576
+ /**
8577
+ * Part 2A lines 027-044 — the IFE build-up. Lines fed by the sub-part
8578
+ * tables above (027, 030, 031, 032, 033, 039, 042) are filled in from them
8579
+ * and must NOT be repeated here. `interestAndFinancingExpenses` above
8580
+ * overrides the whole derivation.
8581
+ */
8582
+ ifeDetail?: InterestAndFinancingExpensesInput;
8583
+ /**
8584
+ * Part 2D lines 058-071 — the IFR build-up. Lines 061 and 066 come from
8585
+ * `loans` above. `interestAndFinancingRevenues` overrides the derivation.
8586
+ */
8587
+ ifrDetail?: InterestAndFinancingRevenuesInput; /** Part 2M, first table — amounts denied under subclause 95(2)(f.11)(ii)(D)(I). */
8588
+ clause95Denied?: readonly Clause95DeniedRow[]; /** Part 2M, second table — amounts included under subclause 95(2)(f.11)(ii)(D)(II). */
8589
+ clause95Included?: readonly Clause95IncludedRow[];
8530
8590
  };
8531
8591
  internetBusiness?: Schedule88Input;
8532
8592
  firstReturn?: Schedule101Input;
@@ -8668,11 +8728,43 @@ interface FederalT2Result {
8668
8728
  */
8669
8729
  partVI1Deduction?: PartVI1DeductionResult;
8670
8730
  /**
8671
- * EIFEL excluded-entity assessment. `requiresLimitation` true means the
8672
- * regime applies and the restriction is NOT computed — the return must not
8673
- * be filed.
8731
+ * EIFEL excluded-entity assessment whether the regime applies at all.
8732
+ * When `requiresLimitation` is true, `eifelAdjustedTaxableIncome`,
8733
+ * `eifelLimitation` and `eifelCapacity` below carry the computation itself.
8674
8734
  */
8675
8735
  eifel?: EifelResult;
8736
+ /** Schedule 130 Part 2F — adjusted taxable income (present when the regime applies). */
8737
+ eifelAdjustedTaxableIncome?: AdjustedTaxableIncomeResult;
8738
+ /**
8739
+ * Schedule 130 Parts 2K/2L — the subsection 18.2(2) denial itself.
8740
+ *
8741
+ * `deniedAmount` IS folded into `schedule1` (line 251) and therefore into
8742
+ * `netIncomeForTax` and `taxableIncome`. Because adjusted taxable income is
8743
+ * defined from taxable income "determined without regard to subsection
8744
+ * 18.2(2)", the engine runs the Schedule 1 → taxable income sequence twice:
8745
+ * once to give the limitation its base, once to apply what it produced. See
8746
+ * `runIncomeSequence` in this module.
8747
+ */
8748
+ eifelLimitation?: EifelLimitationResult;
8749
+ /**
8750
+ * Schedule 130 Parts 1A/2G/2H/2I/2J/2O — the excess-capacity regime.
8751
+ *
8752
+ * Three of its outputs are what other forms ask for by name:
8753
+ * `excessCapacityBeforeRife` is line 129, `receivedCapacity` is line 130,
8754
+ * and `rifeForYear` is Schedule 4 line 710. AT1 Schedule 21's own RIFE
8755
+ * section carries all three across.
8756
+ */
8757
+ eifelCapacity?: EifelCapacityResult;
8758
+ /**
8759
+ * Schedule 130 Part 2A — interest and financing expenses, built from the
8760
+ * borrowing, partnership, capitalized-interest and resource-pool tables
8761
+ * rather than typed in as one figure. `totalIfe` is line 045; `variableA` is
8762
+ * the gross figure lines 139/141 read, which is what the denial is a
8763
+ * proportion OF.
8764
+ */
8765
+ eifelIfe?: InterestAndFinancingExpensesResult;
8766
+ /** Schedule 130 Part 2D — interest and financing revenues; `totalIfr` is line 072. */
8767
+ eifelIfr?: InterestAndFinancingRevenuesResult;
8676
8768
  /** Schedule 88 — internet business activities (information; present when filed). */
8677
8769
  internetBusiness?: Schedule88Result;
8678
8770
  /** Schedule 101 / 24 — first return (information; present when this is a first return). */
@@ -8702,6 +8794,37 @@ interface FederalT2Result {
8702
8794
  totalFederalTax: number;
8703
8795
  /** Total tax = federal + provincial/territorial (Schedule 5). */
8704
8796
  totalTax: number;
8797
+ /**
8798
+ * Anything a schedule wants the preparer to see: a fail-closed default that
8799
+ * suppressed a claim, an amount capped by a shared ceiling, an input the
8800
+ * engine could not derive.
8801
+ *
8802
+ * Alberta has surfaced these since its schedules were built. Federal
8803
+ * schedules RAISED them and nothing collected them, so the most important
8804
+ * one this engine produces — "several parts of the schedule are not modelled
8805
+ * at all… have this return reviewed by a qualified practitioner before
8806
+ * filing", on every EIFEL-restricted return — was computed and then dropped
8807
+ * on the floor.
8808
+ *
8809
+ * Gathered from every sub-result that carries an `issues` array rather than
8810
+ * from a hand-written list, so a schedule that starts raising them is
8811
+ * surfaced without anyone remembering to add it here.
8812
+ */
8813
+ issues: string[];
8814
+ /**
8815
+ * Each schedule's computed figures, keyed by the CRA line they belong on.
8816
+ *
8817
+ * The counterpart of Alberta's `schedulePayloads`. Everything else on this
8818
+ * result is keyed by a name the engine chose — `netIncomeForTax`, `cca` — and
8819
+ * a form cannot be rendered from those, which is why every federal paper Form
8820
+ * View showed "not available" against every computed line. This carries the
8821
+ * same figures under the numbers the return is filed by.
8822
+ *
8823
+ * Deliberately PARTIAL: a schedule appears only where the line each figure
8824
+ * belongs on is recorded in code rather than inferred. See
8825
+ * `t2-schedule-line-items.ts` for why that restraint is the point.
8826
+ */
8827
+ schedulePayloads: T2ScheduleData[];
8705
8828
  }
8706
8829
  declare function computeFederalT2(input: FederalT2Input): FederalT2Result;
8707
8830
  //#endregion
@@ -9238,260 +9361,6 @@ interface T2SettlementResult {
9238
9361
  }
9239
9362
  declare function computeT2Settlement(input: T2SettlementInput): T2SettlementResult;
9240
9363
  //#endregion
9241
- //#region src/t2/schedules/eifel-adjusted-taxable-income.d.ts
9242
- /**
9243
- * ITA subsection 18.2(1) — **adjusted taxable income**, the base the EIFEL
9244
- * ceiling is computed on.
9245
- *
9246
- * `eifel-limitation.ts` took this as a required input because deriving it
9247
- * partially would produce a plausible figure from an incomplete definition. This
9248
- * derives it, and is explicit about the components it does and does not cover.
9249
- *
9250
- * ── What it is ──────────────────────────────────────────────────────────────
9251
- *
9252
- * An EBITDA-like measure, built from taxable income by adding back the things the
9253
- * regime is measuring against and removing the things that would double-count.
9254
- *
9255
- * ATI = A + B − C
9256
- *
9257
- * A = D − E the income base
9258
- * B the ADD-BACKS
9259
- * C the REDUCTIONS
9260
- *
9261
- * **The add-backs include the interest and financing expenses themselves.** That
9262
- * is the point of the measure and the thing to hold on to: the ceiling is a
9263
- * percentage of income computed *before* the very expenses being limited, so a
9264
- * corporation cannot shrink its own ceiling by borrowing more.
9265
- *
9266
- * ── A — the income base (D − E) ─────────────────────────────────────────────
9267
- *
9268
- * **D** is taxable income for the year, determined **without regard to** s.18.2(2)
9269
- * itself, paragraphs 12(1)(l.2) and 111(1)(a.1), and clause 95(2)(f.11)(ii)(D) —
9270
- * a non-resident uses taxable income earned in Canada on the same basis. The
9271
- * circularity is deliberate: the limitation cannot be an input to its own base.
9272
- *
9273
- * **E** subtracts the year's non-capital loss on the same basis, any amount
9274
- * claimed under paragraph 111(1)(a) that did not actually reduce taxable income,
9275
- * and a controlled-foreign-affiliate component (`T × U ÷ V`).
9276
- *
9277
- * ── B — the add-backs ───────────────────────────────────────────────────────
9278
- *
9279
- * (a) interest and financing expenses for the year
9280
- * (b) capital cost allowance and resource deductions — paragraph 20(1)(a),
9281
- * 59.1(a) and subsections 66(4), 66.1(2)/(3), 66.2(2), 66.21(4), 66.4(2),
9282
- * 66.7(1)-(5)
9283
- * (c) terminal losses — subsection 20(16)
9284
- * (d) the taxpayer's share of a partnership's 20(1)(a) and 20(16) deductions
9285
- * (e) the portion of a paragraph 111(1)(e) limited-partnership-loss claim
9286
- * attributable to those amounts
9287
- *
9288
- * ── C — the reductions ──────────────────────────────────────────────────────
9289
- *
9290
- * (a) interest and financing revenues
9291
- * (b) recapture — subsection 13(1)
9292
- * (c) the taxpayer's share of a partnership's 13(1) inclusion
9293
- * (d) resource inclusions — subsections 59(1), 59(3.2), paragraph 59.1(b)
9294
- * (e) for a corporation, a grossed-up foreign tax credit amount:
9295
- * **100/28** of what would be deductible under s.126(1), and
9296
- * the s.126(2) amounts times the relevant factor
9297
- *
9298
- * ── Not modelled ────────────────────────────────────────────────────────────
9299
- *
9300
- * The trust variant of C(e), and the later paragraphs of B and C dealing with
9301
- * foreign affiliate income and exempt interest. Each is available as an explicit
9302
- * `otherAdditions` / `otherReductions` input rather than silently omitted, so a
9303
- * preparer with one of those amounts can still arrive at the right figure and the
9304
- * engine does not pretend the definition is shorter than it is.
9305
- *
9306
- * Source: `research/sources/legislation/ITA-section-18.2-EIFEL.txt`.
9307
- *
9308
- * Pure, whole dollars.
9309
- */
9310
- /** C(e)(i) — s.126(1) amounts are grossed up by 100/28. */
9311
- declare const FOREIGN_TAX_CREDIT_GROSS_UP: number;
9312
- interface AdjustedTaxableIncomeInput {
9313
- /**
9314
- * D — taxable income for the year, determined **without regard to** s.18.2(2),
9315
- * paragraphs 12(1)(l.2) and 111(1)(a.1), and clause 95(2)(f.11)(ii)(D). For a
9316
- * non-resident, taxable income earned in Canada on the same basis.
9317
- *
9318
- * Signed: a loss year gives a negative figure and the definition permits it.
9319
- */
9320
- taxableIncome: number;
9321
- /** E(a) — the non-capital loss for the year, on the same determinations. */
9322
- nonCapitalLossForYear?: number;
9323
- /**
9324
- * E(a.1) — an amount claimed under paragraph 111(1)(a) **to the extent it did
9325
- * not reduce** taxable income as determined for D.
9326
- */
9327
- lossClaimNotReducingTaxableIncome?: number;
9328
- /** E(b) — the controlled foreign affiliate component, `T × U ÷ V`. */
9329
- foreignAccrualPropertyLossComponent?: number;
9330
- /** B(a) — interest and financing expenses for the year. */
9331
- interestAndFinancingExpenses?: number;
9332
- /** B(b) — capital cost allowance, paragraph 20(1)(a). */
9333
- capitalCostAllowance?: number;
9334
- /** B(b) — resource deductions under s.59.1(a) and the s.66 series. */
9335
- resourceDeductions?: number;
9336
- /** B(c) — terminal losses, subsection 20(16). */
9337
- terminalLoss?: number;
9338
- /** B(d) — the taxpayer's share of a partnership's 20(1)(a) / 20(16) deductions. */
9339
- partnershipCapitalAndTerminalShare?: number;
9340
- /** B(e) — the attributable portion of a paragraph 111(1)(e) claim. */
9341
- limitedPartnershipLossPortion?: number;
9342
- /** Any further B paragraph this module does not model. */
9343
- otherAdditions?: number;
9344
- /** C(a) — interest and financing revenues for the year. */
9345
- interestAndFinancingRevenues?: number;
9346
- /** C(b) — recapture included under subsection 13(1). */
9347
- recapture?: number;
9348
- /** C(c) — the taxpayer's share of a partnership's 13(1) inclusion. */
9349
- partnershipRecaptureShare?: number;
9350
- /** C(d) — inclusions under s.59(1), 59(3.2) or paragraph 59.1(b). */
9351
- resourceInclusions?: number;
9352
- /** C(e)(i) — amounts deductible under s.126(1). Grossed up by 100/28 here. */
9353
- section126_1ForeignTaxCredits?: number;
9354
- /** C(e)(ii) — amounts deductible under s.126(2), already at the relevant factor. */
9355
- section126_2GrossedUp?: number;
9356
- /** Any further C paragraph this module does not model. */
9357
- otherReductions?: number;
9358
- }
9359
- interface AdjustedTaxableIncomeResult {
9360
- /** A — the income base, D − E. Signed. */
9361
- incomeBase: number;
9362
- /** B — total add-backs. */
9363
- totalAdditions: number;
9364
- /** C — total reductions. */
9365
- totalReductions: number;
9366
- /** A + B − C. **Signed** — the definition permits a negative result. */
9367
- adjustedTaxableIncome: number;
9368
- issues: string[];
9369
- }
9370
- declare function computeAdjustedTaxableIncome(input: AdjustedTaxableIncomeInput): AdjustedTaxableIncomeResult;
9371
- //#endregion
9372
- //#region src/t2/schedules/eifel-limitation.d.ts
9373
- /**
9374
- * ITA subsection 18.2(2) — the excessive interest and financing expenses
9375
- * limitation itself.
9376
- *
9377
- * `eifel-excluded-entity.ts` decides **whether** the regime applies. This decides
9378
- * **how much** it denies, which was previously left unbuilt on the grounds that
9379
- * computing it from an unbuilt definition would be confidently wrong.
9380
- *
9381
- * ── The provision ───────────────────────────────────────────────────────────
9382
- *
9383
- * s.18.2(2) denies a *proportion* of each interest and financing expense:
9384
- *
9385
- * (A − (B + C + D + E)) ÷ F
9386
- *
9387
- * A the taxpayer's interest and financing expenses for the year
9388
- * B the group-ratio amount under s.18.21(2) where that applies, otherwise
9389
- * **G × H** — the ratio of permissible expenses times adjusted taxable income
9390
- * C the taxpayer's interest and financing revenues for the year
9391
- * D received capacity, to the extent it exceeds the amount deductible under
9392
- * paragraph 111(1)(a.1)
9393
- * E absorbed capacity
9394
- * F ordinarily the same figure as A
9395
- *
9396
- * Because F is A in the ordinary case, the *amount* denied is simply
9397
- *
9398
- * denied = A − (B + C + D + E), floored at nil
9399
- *
9400
- * which is the form this module computes, while still reporting the proportion —
9401
- * the statute denies a fraction of *each* expense, and a preparer allocating the
9402
- * denial across expense lines needs the fraction rather than the total.
9403
- *
9404
- * ── The ratio of permissible expenses ───────────────────────────────────────
9405
- *
9406
- * Keyed off when the taxation year **BEGINS**, not when it ends:
9407
- *
9408
- * begins on or after 2023-10-01 and before 2024-01-01 → **40%**
9409
- * begins on or after 2024-01-01 → **30%**
9410
- *
9411
- * The 40% band is transitional and narrow — one quarter — and it does **not**
9412
- * apply when determining cumulative unused excess capacity for a year beginning
9413
- * on or after 1 January 2024. That carve-out is not modelled; excess-capacity
9414
- * carry-forward is a separate mechanism this module does not compute.
9415
- *
9416
- * ── What this module does NOT compute ───────────────────────────────────────
9417
- *
9418
- * **Adjusted taxable income** is an input, not a derivation. Its definition is a
9419
- * build-up from taxable income through a dozen add-backs and reductions —
9420
- * interest and financing expenses, capital cost allowance, resource deductions,
9421
- * loss claims with their own nested formulas — each with its own defined term. A
9422
- * partial implementation would produce a plausible number from an incomplete
9423
- * definition, which is precisely the failure this module was deferred to avoid.
9424
- * It is therefore **required**, and an absent one denies nothing while saying so.
9425
- *
9426
- * Likewise the group-ratio election under s.18.21, and the received/absorbed
9427
- * capacity amounts, which come from the excess-capacity regime.
9428
- *
9429
- * Source: `research/sources/legislation/ITA-section-18.2-EIFEL.txt`.
9430
- *
9431
- * Pure, whole dollars.
9432
- */
9433
- /** The ratio bands, keyed off the taxation year START. */
9434
- declare const EIFEL_TRANSITIONAL_RATIO = 0.4;
9435
- declare const EIFEL_STANDARD_RATIO = 0.3;
9436
- /** The regime's first day — years beginning before this are outside it. */
9437
- declare const EIFEL_FIRST_YEAR_START = "2023-10-01";
9438
- /** The transitional 40% band ends when years beginning in 2024 start. */
9439
- declare const EIFEL_STANDARD_RATIO_FROM = "2024-01-01";
9440
- interface EifelLimitationInput {
9441
- /** A — interest and financing expenses for the year. */
9442
- interestAndFinancingExpenses: number;
9443
- /**
9444
- * H — adjusted taxable income. **Required**: the definition is a large build-up
9445
- * this module does not derive, and an absent one denies nothing rather than
9446
- * being assumed.
9447
- */
9448
- adjustedTaxableIncome?: number;
9449
- /** C — interest and financing revenues for the year. */
9450
- interestAndFinancingRevenues?: number;
9451
- /**
9452
- * D — received capacity in excess of the amount deducted under paragraph
9453
- * 111(1)(a.1).
9454
- */
9455
- excessReceivedCapacity?: number;
9456
- /** E — absorbed capacity for the year. */
9457
- absorbedCapacity?: number;
9458
- /**
9459
- * B — the group ratio amount under s.18.21(2), where the election was made.
9460
- * Supplying it REPLACES the ratio × adjusted taxable income computation, as the
9461
- * provision directs.
9462
- */
9463
- groupRatioAmount?: number;
9464
- /** Taxation year start, ISO `YYYY-MM-DD` — selects the ratio band. */
9465
- taxYearStart: string;
9466
- }
9467
- interface EifelLimitationResult {
9468
- /** G — the ratio of permissible expenses that applied. */
9469
- ratioOfPermissibleExpenses: number;
9470
- /** B — the permitted amount, however it was arrived at. */
9471
- permittedAmount: number;
9472
- /** Whether B came from the group ratio election rather than ratio × income. */
9473
- usedGroupRatio: boolean;
9474
- /** B + C + D + E — everything that shelters the expenses. */
9475
- totalShelter: number;
9476
- /** The amount denied, floored at nil. */
9477
- deniedAmount: number;
9478
- /**
9479
- * The proportion of EACH expense that is denied. The statute denies a fraction
9480
- * of every interest and financing expense, so a preparer allocating the denial
9481
- * across expense lines needs this, not just the total.
9482
- */
9483
- deniedProportion: number;
9484
- /** Interest and financing expenses that remain deductible. */
9485
- deductibleAmount: number;
9486
- issues: string[];
9487
- }
9488
- /**
9489
- * The ratio of permissible expenses for a year beginning on `taxYearStart`.
9490
- * Returns 0 for a year beginning before the regime applies at all.
9491
- */
9492
- declare function ratioOfPermissibleExpenses(taxYearStart: string): number;
9493
- declare function computeEifelLimitation(input: EifelLimitationInput): EifelLimitationResult;
9494
- //#endregion
9495
9364
  //#region src/t2/schedules/schedule27-mp.d.ts
9496
9365
  /**
9497
9366
  * T2 Schedule 27 — Canadian Manufacturing and Processing Profits Deduction
@@ -9667,4 +9536,4 @@ interface CanadianMPProfitsResult {
9667
9536
  declare function computeCanadianMPProfits(input: CanadianMPProfitsInput): CanadianMPProfitsResult;
9668
9537
  declare function computeMpDeduction(input: MpDeductionInput, rates?: MpDeductionRates): MpDeductionResult;
9669
9538
  //#endregion
9670
- export { computeQuebecReturn as $, CeeSuccessorOverride as $a, computeIeg as $c, RSI_WORD_GAP as $i, AlbertaCcaOverride as $l, PermanentEstablishment as $n, ALBERTA_SRED_PROGRAM_START as $o, TaxableIncomeResult as $r, At1ScheduleDataLike$5 as $s, computeTaxableCapital as $t, LossCarrybackYear as $u, T2SettlementInput as A, AlbertaSchedule15Result as Aa, schedule17Values as Ac, Schedule12Adjustment as Ai, AlbertaSchedule18Input as Al, DepletionResult as An, SfedeCountryRegularResult as Ao, PartVI1DeductionBand as Ar, RoyaltyTaxCreditShelterAllocationResult as As, Schedule88Input as At, computeClass13 as Au, T2GifiLine as B, CdeRegularInput as Ba, IegAgreementMemberResult as Bc, albertaRecaptureDifference as Bi, AT1_RESERVE_LINES as Bl, computeCumulativeForeignResource as Bn, computeCeeRegular as Bo, ProvincialRateChange as Br, schedule5Values as Bs, Schedule54Input as Bt, At4970Input as Bu, EifelLimitationResult as C, xmlEscape as Ca, Schedule2FilingInput as Cc, CORP_TAX_2024 as Ci, DonationMaximumResult as Cl, CdeInput as Cn, FedeSuccessorInput as Co, deferredIncomeTaxProvisionAddBack as Cr, computeAlbertaSchedule7 as Cs, FederalT2Result as Ct, Class14Property as Cu, AdjustedTaxableIncomeResult as D, AlbertaReturnResult as Da, schedule12Values as Dc, LossScheduleInput as Di, Schedule20Result as Dl, CogpeInput as Dn, SfedeCountryRegularFederal as Do, recaptureAddBack as Dr, RoyaltyTaxCreditLongestAssociatedYear as Ds, Schedule101Result as Dt, LeaseholdLayerResult as Du, AdjustedTaxableIncomeInput as E, AlbertaReturnInput as Ea, schedule12LossDeductions as Ec, resolveCorpTaxRates as Ei, Schedule20Input as El, CeeResult as En, Schedule15FilingResult as Eo, mealsAndEntertainmentAddBack as Er, AlbertaSchedule6Result as Es, Schedule101Input as Et, LeaseholdLayer as Eu, T2CifGifi as F, CcogpeSuccessorFederal as Fa, schedule29Values as Fc, albertaCapitalGainDifference as Fi, At1CategoryTotals as Fl, Schedule12ResourceDeductionsInput as Fn, computeAlbertaSchedule15 as Fo, EifelExemption as Fr, At1Schedule5PoolTransfer as Fs, computeSchedule55 as Ft, CCA_DECLINING_BALANCE_RATES_2024 as Fu, Co17Certification as G, CdeSuccessorOverride as Ga, IegLimitAllocation as Gc, reconcileAlbertaNetIncome as Gi, At1ReserveKind as Gl, CapitalDisposition as Gn, computeEdaRegular as Go, PROVINCE_RATE_BOOK as Gr, computeSchedule4 as Gs, computeGrip as Gt, At4970Totals as Gu, T2ReturnInput as H, CdeRegularResult as Ha, IegAllocationResult as Hc, albertaResourceDeductionDifference as Hi, AlbertaSchedule17Input as Hl, computeForeignExploration as Hn, computeCfreRegular as Ho, blendProvinceRateTable as Hr, ForeignInvestmentCountryResult as Hs, computeSchedule54 as Ht, At4970ProjectRow as Hu, T2CifPartI as I, CcogpeSuccessorInput as Ia, schedule2Values as Ic, albertaCcaDifference as Ii, At1DispositionCategory as Il, Schedule12ResourceDeductionsResult as In, computeCcogpeRegular as Io, EifelInput as Ir, At1Schedule5PredecessorTransfer as Is, LRIP_INVESTMENT_CORPORATION_MULTIPLE as It, CCA_RATE_BOOK as Iu, renderCo17DraftReturn as J, CeeRegularInput as Ja, computeIegAgreement as Jc, toRsiLineItems as Ji, computeAlbertaSchedule17 as Jl, computeSchedule6 as Jn, computeFedeSuccessor as Jo, ProvincialRate as Jr, AgriProcessingCurrentYearInput as Js, Schedule43Result as Jt, LossContinuityResult as Ju, Co17Identity as K, CdeSuccessorResult as Ka, allocateIegEvenly as Kc, toRsiHeader as Ki, At1ReserveRowResult as Kl, DispositionResult as Kn, computeEdaSuccessor as Ko, ProvinceCode as Kr, schedule4Values as Ks, Schedule43Input as Kt, computeAt4970 as Ku, T2CifQuestionnaire as L, CcogpeSuccessorOverride as La, schedule4970Values as Lc, albertaCcaScheduleAdjustments as Li, SECTION_34_2_GROSS_UP as Ll, computeCde as Ln, computeCcogpeSuccessor as Lo, EifelResult as Lr, At1Schedule5SuccessoredPoolEntry as Ls, LRIP_INVESTMENT_INCOME_FACTOR as Lt, CcaRateTable as Lu, computeT2Settlement as M, CcogpeRegularInput as Ma, schedule1Values as Mc, Schedule12Line as Mi, At1AbilEntry as Ml, ForeignExplorationResult as Mn, SfedeCountrySuccessorInput as Mo, computePartVI1Deduction as Mr, schedule6Values as Ms, normalizeSchedule88 as Mt, computeClass141AdditionalAllowance as Mu, T2CifAddress as N, CcogpeRegularOverride as Na, schedule20Values as Nc, Schedule12Result as Ni, At1AbilResult as Nl, ForeignPerCountryInput as Nn, SfedeCountrySuccessorOverride as No, partVI1DeductionMultiple as Nr, AlbertaSchedule5Input as Ns, Schedule55Input as Nt, computeClass141RecaptureReduction as Nu, FOREIGN_TAX_CREDIT_GROSS_UP as O, computeAlbertaReturn as Oa, schedule13Values as Oc, LossScheduleResult as Oi, computeSchedule20 as Ol, CogpeResult as On, SfedeCountryRegularInput as Oo, terminalLossDeduction as Or, RoyaltyTaxCreditQuarter as Os, computeSchedule101 as Ot, MAX_LEASEHOLD_PERIODS as Ou, T2CifData as P, CcogpeRegularResult as Pa, schedule21Values as Pc, albertaAbilDifference as Pi, At1CategoryResult as Pl, ForeignPerCountryResult as Pn, SfedeCountrySuccessorResult as Po, EIFEL_EFFECTIVE_FROM as Pr, AlbertaSchedule5Result as Ps, Schedule55Result as Pt, leaseholdPeriods as Pu, QuebecReturnResult as Q, CeeSuccessorInput as Qa, IegResult as Qc, RSI_NEGATIVE_PREFIX as Qi, computeAlbertaSchedule16 as Ql, AllocatedProvince as Qn, ALBERTA_SRED_EXPENDITURE_CUTOFF as Qo, TaxableIncomeLine as Qr, AgriProcessingVintageResult as Qs, TaxableCapitalResult as Qt, LossCarrybackResult as Qu, T2CifSettlement as R, CcogpeSuccessorResult as Ra, IegAgreementInput as Rc, albertaCurrentYearLoss as Ri, computeAlbertaSchedule18 as Rl, computeCee as Rn, computeCdeRegular as Ro, EifelThresholds as Rr, At1Schedule5SuccessoredPoolEntryResult as Rs, LripDividendEvent as Rt, isDecliningBalanceClass as Ru, EifelLimitationInput as S, at1YesNo as Sa, Schedule21FilingInput as Sc, resolveRates as Sd, computeSBD as Si, DonationMaximumInput as Sl, computeSchedule13 as Sn, FedeSuccessorFederal as So, computeSchedule1 as Sr, RoyaltySupplementalPriorYearAdjustmentResult as Ss, FederalT2Input as St, Class14Input as Su, ratioOfPermissibleExpenses as T, at1Engine as Ta, schedule10Values as Tc, CorpTaxRates as Ti, AlbertaGiftCarryforward as Tl, CeeInput as Tn, FedeSuccessorResult as To, incomeTaxProvisionAddBack as Tr, AlbertaSchedule6Input as Ts, FirstReturnEvent as Tt, Class14Result as Tu, t2Engine as U, CdeSuccessorFederal as Ua, IegGroupMember as Uc, albertaTerminalLossDifference as Ui, AlbertaSchedule17Result as Ul, computeSchedule12ResourceDeductions as Un, computeCfreSuccessor as Uo, dayWeightedRate as Ur, Schedule4Input$1 as Us, GripInput as Ut, At4970ProjectRowResult as Uu, renderT2DraftReturn as V, CdeRegularOverride as Va, IegAgreementResult as Vc, albertaReserveDifference as Vi, AT1_RESERVE_TOTAL_LINES as Vl, computeDepletion as Vn, computeCeeSuccessor as Vo, ProvincialRateChanges as Vr, ForeignInvestmentCountryInput as Vs, Schedule54Result as Vt, At4970JurisdictionAmount as Vu, Co17Address as W, CdeSuccessorInput as Wa, IegGroupResult as Wc, computeSchedule12 as Wi, At1ReserveBalances as Wl, computeSpecifiedForeignExploration as Wn, computeCmedb as Wo, PROVINCE_RATES_2024 as Wr, Schedule4Result$1 as Ws, GripResult as Wt, At4970Result as Wu, co17Engine as X, CeeRegularResult as Xa, IEG_2024 as Xc, RSI_COLUMN_GAP as Xi, AlbertaSchedule16Result as Xl, Schedule5Result as Xn, computeSfedeCountrySuccessor as Xo, resolveProvinceRates as Xr, AgriProcessingTaxCreditResult as Xs, LARGE_CORPORATION_THRESHOLD as Xt, LossCarrybackError as Xu, Co17ReturnInput as Y, CeeRegularOverride as Ya, computeIegGroupFigures as Yc, toRsiSchedule as Yi, AlbertaSchedule16Input as Yl, Schedule5Input as Yn, computeSfedeCountryRegular as Yo, isSchedule5Province as Yr, AgriProcessingTaxCreditInput as Ys, computeSchedule43 as Yt, computeLossContinuity as Yu, QuebecReturnInput as Z, CeeSuccessorFederal as Za, IegInput as Zc, RSI_DELIMITER as Zi, assistanceFrom as Zl, computeSchedule5 as Zn, schedule15Values as Zo, TaxableIncomeInput as Zr, AgriProcessingVintageInput as Zs, TaxableCapitalInput as Zt, LossCarrybackInput as Zu, computeSmallManufacturerTest as _, albertaBalanceUnpaid as _a, At1ScheduleValue as _c, RateBookEntry as _d, SbdInput as _i, LimitedPartnershipLossesResult as _l, Schedule21Input as _n, EdaSuccessorResult as _o, Schedule1NotFileableError as _r, AlbertaSchedule7Input as _s, T2_LINE_META as _t, Class13Input as _u, MP_RATES_2024 as a, formatRsiDate as aa, MaximumAllowableDeductionInput as ac, AlbertaSbdInput as ad, CcpcActiveBusinessTaxInput as ai, iegT661SourceLine as al, ItcRecaptureItemResult as an, CfreCountrySuccessorFederal as ao, computeSchedule4Losses as ar, Schedule9AllocationResult as as, computeQuebecTax as at, CcaClassInput as au, EIFEL_STANDARD_RATIO_FROM as b, assertCriticalFields as ba, Schedule1FilingInput as bc, hasExactRateYear as bd, computeAggregateInvestmentIncome as bi, AT1_DONATION_GAIN_RATE as bl, ReserveContinuityResult as bn, FedeRegularOverride as bo, assertSchedule1Fileable as br, RoyaltySupplementalPartnershipResult as bs, runConformance as bt, Class141AdditionalAllowanceResult as bu, MpDeductionResult as c, renderRsiHeader as ca, Schedule3Result as cc, AB_GENERAL_RATE_BANDS as cd, PartITaxResult as ci, NonCapitalLossByYearOfOriginInput as cl, ZetmInput as cn, CfreCountrySuccessorResult as co, Part4RdtohResult as cr, allocateSchedule9ExpenditureLimit as cs, QuebecTaxRates as ct, Schedule8Entry as cu, SMALL_MANUFACTURER_INCOME_THRESHOLD as d, AT1_CRITICAL_MANDATORY_FIELDS as da, AllocationFactorInput as dc, computeDayWeightedGeneralTax as dd, AdjustedAggregateInvestmentIncomeInput as di, OtherLossVintageEntry as dl, AssociatedMemberInput as dn, CmedbResult as do, Schedule2Input as dr, schedule9Values as ds, CertificationFixture as dt, computeCcaClass as du, RsiHeaderInput as ea, At1ScheduleValueLike$5 as ec, computeLossCarryback as ed, charitableDonationsDeduction as ei, computeIegBaseAmount as el, Schedule31Input as en, CeeSuccessorResult as eo, ProvincialAllocationInput as er, ALBERTA_SRED_TAX_CREDIT_RATE as es, QuebecAllocationResult as et, AlbertaSchedule13ClassResult as eu, SmallManufacturerTestInput as f, At1CriticalFieldMissingError as fa, SINGLE_JURISDICTION_ALBERTA_FACTOR as fc, AB_TAX_2024 as fd, AdjustedAggregateInvestmentIncomeResult as fi, OtherLossVintageRowResult as fl, AssociatedMemberResult as fn, EdaRegularFederal as fo, Schedule2Result as fr, PoliticalContributionInput as fs, ConformanceResult as ft, computeCcaSchedule as fu, computePart2MPProfits as g, At1TransmitterInfo as ga, At1ScheduleData as gc, RateBook as gd, BusinessLimitResult as gi, LimitedPartnershipLossRowResult as gl, computeBusinessLimitAllocation as gn, EdaSuccessorInput as go, Schedule1LineDefect as gr, schedule8Values as gs, T2LineKey as gt, CLASS_14_1_TRANSITIONAL_RATE as gu, computeMpDeduction as h, At1TaxPayableMismatchError as ha, AT1_SCHEDULES_WITH_BUILDERS as hc, resolveAlbertaTaxRates as hd, BusinessLimitInput as hi, LimitedPartnershipLossRow as hl, allocateEvenly as hn, EdaSuccessorFederal as ho, Schedule1Line as hr, computeSchedule8 as hs, LineCheck as ht, CLASS_14_1_RECAPTURE_REDUCTION_RATE as hu, MP_GROSS_REVENUE_THRESHOLD as i, formatRsiAmount as ia, InvestorTaxCreditResult as ic, AlbertaCorporationStatus as id, nonCapitalLossApplied as ii, computeIegEligibleExpenditures as il, ItcRecaptureItem as in, CfreCountryRegularResult as io, Schedule4Result as ir, Schedule9AllocationMemberResult as is, QuebecTaxResult as it, computeAlbertaSchedule13 as iu, T2SettlementResult as j, CcogpeRegularFederal as ja, schedule18Values as jc, Schedule12Input as ji, AlbertaSchedule18Result as jl, ForeignExplorationInput as jn, SfedeCountrySuccessorFederal as jo, PartVI1DeductionResult as jr, computeAlbertaSchedule6 as js, Schedule88Result as jt, computeClass14 as ju, computeAdjustedTaxableIncome as k, AlbertaSchedule15Input as ka, schedule16Values as kc, computeLossSchedule as ki, AT1_DISPOSITION_CATEGORIES as kl, DepletionInput as kn, SfedeCountryRegularOverride as ko, PART_VI_1_DEDUCTION_BANDS as kr, RoyaltyTaxCreditShelterAllocation as ks, SCHEDULE_88_MAX_URLS as kt, MIN_LEASEHOLD_PERIODS as ku, Part2MPProfitsInput as l, renderRsiLineItem as la, computeSchedule3 as lc, DayWeightedRateResult as ld, computeCcpcActiveBusinessTax as li, NonCapitalLossByYearOfOriginResult as ll, ZetmResult as ln, CmedbFederal as lo, REFUNDABLE_PART_I_RATE as lr, computeAlbertaSchedule9 as ls, resolveQuebecTaxRates as lt, Schedule8Result$1 as lu, computeCanadianMPProfits as m, At1MandatoryFieldMissingError as ma, AT1_SCHEDULES_WITHOUT_BUILDERS as mc, AlbertaTaxRates as md, AggregateInvestmentIncomeResult as mi, computeOtherLossByYearOfOrigin as ml, BusinessLimitAllocationResult as mn, EdaRegularResult as mo, Schedule1Input as mr, Schedule8Result as ms, ExpectedSource as mt, CLASS_14_1_MINIMUM_DEDUCTION as mu, CanadianMPProfitsResult as n, RsiLineItemError as na, CapitalInvestmentTaxCreditResult as nc, AlbertaTaxResult as nd, dividendsDeductibleS112 as ni, IegEligibleExpendituresInput as nl, computeSchedule31 as nn, CfreCountryRegularInput as no, computeProvincialAllocation as nr, AlbertaSchedule9Result as ns, computeQuebecAllocationFactor as nt, AlbertaSchedule13Result as nu, MpDeductionInput as o, formatRsiText as oa, MaximumAllowableDeductionResult as oc, AlbertaSbdResult as od, CcpcActiveBusinessTaxResult as oi, LossVintageEntry as ol, ItcRecaptureResult as on, CfreCountrySuccessorInput as oo, PART_IV_RATE as or, Schedule9FieldOfScience as os, QC_TAX_2024 as ot, CcaClassResult as ou, SmallManufacturerTestResult as p, At1FilingData as pa, computeAllocationFactor as pc, AB_TAX_RATE_BOOK as pd, AggregateInvestmentIncomeInput as pi, computeNonCapitalLossByYearOfOrigin as pl, BusinessLimitAllocationInput as pn, EdaRegularInput as po, computeSchedule2 as pr, Schedule8Input as ps, ConformanceSummary as pt, computeSchedule8$1 as pu, Co17ReturnData as q, CeeRegularFederal as qa, allocateIegExpenditureLimit as qc, toRsiJacketSchedules as qi, At1ReserveTable as ql, Schedule6Result as qn, computeFedeRegular as qo, ProvinceRateTable as qr, AgriProcessingCombinedVintageInput as qs, Schedule43Rates as qt, LossContinuityInput as qu, MP_EXCLUDED_ACTIVITIES as r, RsiScheduleInput as ra, InvestorTaxCreditInput as rc, computeAlbertaTax as rd, netCapitalLossApplied as ri, IegEligibleExpendituresResult as rl, ITC_RECAPTURE_PERIOD_YEARS as rn, CfreCountryRegularOverride as ro, Schedule4Input as rr, Schedule9AllocationMember as rs, QuebecTaxInput as rt, FederalCcaClass as ru, MpDeductionRates as s, renderAt1Rsi as sa, Schedule3Input as sc, computeAlbertaSbd as sd, PartITaxInput as si, LossVintageRowResult as sl, computeItcRecapture as sn, CfreCountrySuccessorOverride as so, Part4RdtohInput as sr, Schedule9GroupFilingInput as ss, QC_TAX_RATE_BOOK as st, CcaScheduleResult as su, CanadianMPProfitsInput as t, RsiLineItem as ta, CapitalInvestmentTaxCreditInput as tc, AlbertaTaxInput as td, computeTaxableIncome as ti, computeIegReductionFactor as tl, Schedule31Result as tn, CfreCountryRegularFederal as to, ProvincialAllocationResult as tr, AlbertaSchedule9Input as ts, QuebecEstablishment as tt, AlbertaSchedule13Input as tu, Part2MPProfitsResult as u, renderAt1NetFile as ua, schedule3Values as uc, GeneralRateBand as ud, computePartITax as ui, OtherLossByYearOfOriginResult as ul, computeZetm as un, CmedbInput as uo, computePart4Rdtoh as ur, computeSchedule9MaximumExpenditureLimit as us, T2_CERTIFICATION_FIXTURES as ut, UnsupportedCcaClassError as uu, EIFEL_FIRST_YEAR_START as v, assertAt1MandatoryComplete as va, Schedule10FilingInput as vc, earliestRateYear as vd, SbdResult as vi, computeLimitedPartnershipLossRow as vl, Schedule21Result as vn, FedeRegularFederal as vo, Schedule1Result as vr, AlbertaSchedule7Result as vs, foldT2Lines as vt, Class13Result as vu, computeEifelLimitation as w, At1ReturnInput as wa, at1LineItemId as wc, CORP_TAX_RATE_BOOK as wi, computeDonationMaximum as wl, CdeResult as wn, FedeSuccessorOverride as wo, findSchedule1LineDefects as wr, schedule7Values as ws, computeFederalT2 as wt, Class14PropertyResult as wu, EIFEL_TRANSITIONAL_RATIO as x, at1TaxPayableDeductions as xa, Schedule20FilingInput as xc, latestRateYear as xd, computeBusinessLimit as xi, AT1_DONATION_INCOME_RATE as xl, ReserveContinuityRow as xn, FedeRegularResult as xo, ccaDeduction as xr, RoyaltySupplementalPriorYearAdjustment as xs, runConformanceSuite as xt, Class141RecaptureReductionInput as xu, EIFEL_STANDARD_RATIO as y, assertAt1TaxPayableReconciles as ya, Schedule12FilingInput as yc, extendRateBook as yd, computeAdjustedAggregateInvestmentIncome as yi, computeLimitedPartnershipLosses as yl, computeSchedule21 as yn, FedeRegularInput as yo, amortizationAddBack as yr, RoyaltySupplementalPartnership as ys, formatConformanceReport as yt, Class141AdditionalAllowanceInput as yu, T2CifShareholder as z, CdeRegularFederal as za, IegAgreementMember as zc, albertaDispositionAdjustments as zi, AT1_RESERVE_KINDS as zl, computeCogpe as zn, computeCdeSuccessor as zo, assessEifel as zr, computeAlbertaSchedule5 as zs, LripEventResult as zt, resolveCcaRates as zu };
9539
+ export { CertificationFixture as $, RsiScheduleInput as $a, allocateIegEvenly as $c, AdjustedAggregateInvestmentIncomeResult as $i, AlbertaSchedule17Result as $l, Schedule2Input as $n, CfreCountryRegularOverride as $o, computeBorrowings as $r, schedule4Values as $s, AssociatedMemberInput as $t, At4970ProjectRowResult as $u, T2ReturnInput as A, albertaCurrentYearLoss as Aa, Schedule2FilingInput as Ac, hasExactRateYear as Ad, dayWeightedRate as Ai, AT1_DONATION_GAIN_RATE as Al, computeForeignExploration as An, CcogpeRegularResult as Ao, BorrowingRow as Ar, SfedeCountrySuccessorResult as As, computeSchedule54 as At, Class141AdditionalAllowanceResult as Au, QuebecReturnResult as B, assertAt1TransmitterValid as Ba, schedule20Values as Bc, TaxableIncomeResult as Bi, AlbertaSchedule18Input as Bl, AllocatedProvince as Bn, CdeSuccessorInput as Bo, InterestAndFinancingExpensesInput as Br, computeCmedb as Bs, TaxableCapitalResult as Bt, computeClass13 as Bu, T2CifGifi as C, Schedule12Input as Ca, At1ScheduleData as Cc, AB_TAX_RATE_BOOK as Cd, AdjustedTaxableIncomeInput as Ci, RifeContinuityResult as Cl, Schedule12ResourceDeductionsInput as Cn, AlbertaReturnResult as Co, EIFEL_STANDARD_RATIO as Cr, SfedeCountryRegularFederal as Cs, computeSchedule55 as Ct, computeSchedule8 as Cu, T2CifShareholder as D, albertaCapitalGainDifference as Da, Schedule1FilingInput as Dc, RateBookEntry as Dd, ProvincialRateChange as Di, LimitedPartnershipLossesResult as Dl, computeCogpe as Dn, CcogpeRegularFederal as Do, EifelLimitationResult as Dr, SfedeCountrySuccessorFederal as Ds, LripEventResult as Dt, Class13Input as Du, T2CifSettlement as E, albertaAbilDifference as Ea, Schedule12FilingInput as Ec, RateBook as Ed, computeAdjustedTaxableIncome as Ei, LimitedPartnershipLossRowResult as El, computeCee as En, AlbertaSchedule15Result as Eo, EifelLimitationInput as Er, SfedeCountryRegularResult as Es, LripDividendEvent as Et, CLASS_14_1_TRANSITIONAL_RATE as Eu, Co17ReturnData as F, albertaTerminalLossDifference as Fa, schedule13Values as Fc, ProvincialRate as Fi, AlbertaGiftCarryforward as Fl, Schedule6Result as Fn, CdeRegularFederal as Fo, Clause95IncludedRow as Fr, computeCdeSuccessor as Fs, Schedule43Rates as Ft, Class14Result as Fu, QuebecTaxInput as G, toRsiSchedule as Ga, IegAgreementInput as Gc, nonCapitalLossApplied as Gi, At1CategoryTotals as Gl, Schedule4Input as Gn, CeeRegularOverride as Go, LoansResult as Gr, computeSfedeCountryRegular as Gs, ITC_RECAPTURE_PERIOD_YEARS as Gt, CCA_DECLINING_BALANCE_RATES_2024 as Gu, QuebecAllocationResult as H, toRsiHeader as Ha, schedule29Values as Hc, computeTaxableIncome as Hi, At1AbilEntry as Hl, ProvincialAllocationInput as Hn, CdeSuccessorResult as Ho, InterestAndFinancingRevenuesInput as Hr, computeEdaSuccessor as Hs, Schedule31Input as Ht, computeClass141AdditionalAllowance as Hu, renderCo17DraftReturn as I, computeSchedule12 as Ia, schedule16Values as Ic, isSchedule5Province as Ii, Schedule20Input as Il, computeSchedule6 as In, CdeRegularInput as Io, Clause95Result as Ir, computeCeeRegular as Is, Schedule43Result as It, LeaseholdLayer as Iu, QC_TAX_2024 as J, RSI_NEGATIVE_PREFIX as Ja, IegAgreementResult as Jc, PartITaxInput as Ji, computeAlbertaSchedule18 as Jl, PART_IV_RATE as Jn, CeeSuccessorInput as Jo, PartnershipIfeResult as Jr, ForeignInvestmentCountryInput as Js, ItcRecaptureResult as Jt, isDecliningBalanceClass as Ju, QuebecTaxResult as K, RSI_COLUMN_GAP as Ka, IegAgreementMember as Kc, CcpcActiveBusinessTaxInput as Ki, At1DispositionCategory as Kl, Schedule4Result as Kn, CeeRegularResult as Ko, LossPortionFromIfeResult as Kr, computeSfedeCountrySuccessor as Ks, ItcRecaptureItem as Kt, CCA_RATE_BOOK as Ku, Co17ReturnInput as L, reconcileAlbertaNetIncome as La, schedule17Values as Lc, resolveProvinceRates as Li, Schedule20Result as Ll, Schedule5Input as Ln, CdeRegularOverride as Lo, EifelCounterpartyRelationship as Lr, computeCeeSuccessor as Ls, computeSchedule43 as Lt, LeaseholdLayerResult as Lu, Co17Address as M, albertaRecaptureDifference as Ma, schedule10Values as Mc, resolveRates as Md, PROVINCE_RATE_BOOK as Mi, DonationMaximumInput as Ml, computeSpecifiedForeignExploration as Mn, CcogpeSuccessorInput as Mo, CapitalizedIfeResult as Mr, computeCcogpeRegular as Ms, GripResult as Mt, Class14Input as Mu, Co17Certification as N, albertaReserveDifference as Na, schedule12LossDeductions as Nc, ProvinceCode as Ni, DonationMaximumResult as Nl, CapitalDisposition as Nn, CcogpeSuccessorOverride as No, CapitalizedIfeRow as Nr, computeCcogpeSuccessor as Ns, computeGrip as Nt, Class14Property as Nu, T2GifiLine as O, albertaCcaDifference as Oa, Schedule20FilingInput as Oc, earliestRateYear as Od, ProvincialRateChanges as Oi, computeLimitedPartnershipLossRow as Ol, computeCumulativeForeignResource as On, CcogpeRegularInput as Oo, computeEifelLimitation as Or, SfedeCountrySuccessorInput as Os, Schedule54Input as Ot, Class13Result as Ou, Co17Identity as P, albertaResourceDeductionDifference as Pa, schedule12Values as Pc, ProvinceRateTable as Pi, computeDonationMaximum as Pl, DispositionResult as Pn, CcogpeSuccessorResult as Po, Clause95DeniedRow as Pr, computeCdeRegular as Ps, Schedule43Input as Pt, Class14PropertyResult as Pu, T2_CERTIFICATION_FIXTURES as Q, RsiLineItemError as Qa, IegLimitAllocation as Qc, AdjustedAggregateInvestmentIncomeInput as Qi, AlbertaSchedule17Input as Ql, computePart4Rdtoh as Qn, CfreCountryRegularInput as Qo, ResourceIfeRow as Qr, computeSchedule4 as Qs, computeZetm as Qt, At4970ProjectRow as Qu, co17Engine as R, At1TransmitterDefect as Ra, schedule18Values as Rc, TaxableIncomeInput as Ri, computeSchedule20 as Rl, Schedule5Result as Rn, CdeRegularResult as Ro, ExemptIfeResult as Rr, computeCfreRegular as Rs, LARGE_CORPORATION_THRESHOLD as Rt, MAX_LEASEHOLD_PERIODS as Ru, T2CifData as S, Schedule12Adjustment as Sa, AT1_SCHEDULES_WITH_BUILDERS as Sc, AB_TAX_2024 as Sd, computeRifeUnderSubsection111_8 as Si, RifeContinuityInput as Sl, ForeignPerCountryResult as Sn, AlbertaReturnInput as So, EIFEL_FIRST_YEAR_START as Sr, Schedule15FilingResult as Ss, Schedule55Result as St, computeCcaSchedule as Su, T2CifQuestionnaire as T, Schedule12Result as Ta, Schedule10FilingInput as Tc, resolveAlbertaTaxRates as Td, FOREIGN_TAX_CREDIT_GROSS_UP as Ti, LimitedPartnershipLossRow as Tl, computeCde as Tn, AlbertaSchedule15Input as To, EIFEL_TRANSITIONAL_RATIO as Tr, SfedeCountryRegularOverride as Ts, LRIP_INVESTMENT_INCOME_FACTOR as Tt, CLASS_14_1_RECAPTURE_REDUCTION_RATE as Tu, QuebecEstablishment as U, toRsiJacketSchedules as Ua, schedule2Values$1 as Uc, dividendsDeductibleS112 as Ui, At1AbilResult as Ul, ProvincialAllocationResult as Un, CeeRegularFederal as Uo, InterestAndFinancingRevenuesResult as Ur, computeFedeRegular as Us, Schedule31Result as Ut, computeClass141RecaptureReduction as Uu, computeQuebecReturn as V, validateAt1Transmitter as Va, schedule21Values$1 as Vc, charitableDonationsDeduction as Vi, AlbertaSchedule18Result as Vl, PermanentEstablishment as Vn, CdeSuccessorOverride as Vo, InterestAndFinancingExpensesResult as Vr, computeEdaRegular as Vs, computeTaxableCapital as Vt, computeClass14 as Vu, computeQuebecAllocationFactor as W, toRsiLineItems as Wa, schedule4970Values as Wc, netCapitalLossApplied as Wi, At1CategoryResult as Wl, computeProvincialAllocation as Wn, CeeRegularInput as Wo, LoanRow as Wr, computeFedeSuccessor as Ws, computeSchedule31 as Wt, leaseholdPeriods as Wu, QuebecTaxRates as X, RsiHeaderInput as Xa, IegGroupMember as Xc, computeCcpcActiveBusinessTax as Xi, AT1_RESERVE_LINES as Xl, Part4RdtohResult as Xn, CeeSuccessorResult as Xo, ResourceIfePool as Xr, Schedule4Input$1 as Xs, ZetmInput as Xt, At4970Input as Xu, QC_TAX_RATE_BOOK as Y, RSI_WORD_GAP as Ya, IegAllocationResult as Yc, PartITaxResult as Yi, AT1_RESERVE_KINDS as Yl, Part4RdtohInput as Yn, CeeSuccessorOverride as Yo, PartnershipIfeRow as Yr, ForeignInvestmentCountryResult as Ys, computeItcRecapture as Yt, resolveCcaRates as Yu, resolveQuebecTaxRates as Z, RsiLineItem as Za, IegGroupResult as Zc, computePartITax as Zi, AT1_RESERVE_TOTAL_LINES as Zl, REFUNDABLE_PART_I_RATE as Zn, CfreCountryRegularFederal as Zo, ResourceIfeResult as Zr, Schedule4Result$1 as Zs, ZetmResult as Zt, At4970JurisdictionAmount as Zu, computeSmallManufacturerTest as _, parseT2LineItemId as _a, schedule3Values as _c, computeAlbertaSbd as _d, EifelCapacityInput as _i, OtherLossByYearOfOriginResult as _l, DepletionInput as _n, at1TaxPayableDeductions as _o, PART_VI_1_DEDUCTION_BANDS as _r, FedeRegularResult as _s, SCHEDULE_88_MAX_URLS as _t, CcaScheduleResult as _u, MP_RATES_2024 as a, SbdResult as aa, AgriProcessingVintageResult as ac, computeLossContinuity as ad, computeInterestAndFinancingRevenues as ai, IegResult as al, Schedule21Input as an, renderRsiLineItem as ao, Schedule1NotFileableError as ar, CmedbFederal as as, T2_LINE_META as at, AlbertaSchedule16Input as au, computeT2Settlement as b, LossScheduleResult as ba, computeAllocationFactor as bc, GeneralRateBand as bd, ReceivedCapacityRow as bi, computeNonCapitalLossByYearOfOrigin as bl, ForeignExplorationResult as bn, At1ReturnInput as bo, computePartVI1Deduction as br, FedeSuccessorOverride as bs, normalizeSchedule88 as bt, UnsupportedCcaClassError as bu, MpDeductionResult as c, computeBusinessLimit as ca, CapitalInvestmentTaxCreditInput as cc, LossCarrybackResult as cd, computePartnershipIfe as ci, computeIegReductionFactor as cl, ReserveContinuityResult as cn, At1CriticalFieldMissingError as co, assertSchedule1Fileable as cr, EdaRegularFederal as cs, runConformance as ct, computeAlbertaSchedule16 as cu, SMALL_MANUFACTURER_INCOME_THRESHOLD as d, CORP_TAX_RATE_BOOK as da, InvestorTaxCreditResult as dc, AlbertaTaxInput as dd, EIFEL_EFFECTIVE_FROM as di, computeIegEligibleExpenditures as dl, CdeInput as dn, At1TaxPayableMismatchError as do, deferredIncomeTaxProvisionAddBack as dr, EdaSuccessorFederal as ds, FederalT2Result as dt, AlbertaSchedule13Input as du, AggregateInvestmentIncomeInput as ea, AgriProcessingCombinedVintageInput as ec, At4970Result as ed, computeCapitalizedIfe as ei, allocateIegExpenditureLimit as el, AssociatedMemberResult as en, formatRsiAmount as eo, Schedule2Result as er, CfreCountryRegularResult as es, ConformanceResult as et, At1ReserveBalances as eu, SmallManufacturerTestInput as f, CorpTaxRates as fa, MaximumAllowableDeductionInput as fc, AlbertaTaxResult as fd, EifelExemption as fi, iegT661SourceLine as fl, CdeResult as fn, At1TransmitterInfo as fo, findSchedule1LineDefects as fr, EdaSuccessorInput as fs, computeFederalT2 as ft, AlbertaSchedule13Result as fu, computePart2MPProfits as g, federalSchedulePayloads as ga, computeSchedule3 as gc, AlbertaSbdResult as gd, assessEifel as gi, NonCapitalLossByYearOfOriginResult as gl, CogpeResult as gn, assertCriticalFields as go, terminalLossDeduction as gr, FedeRegularOverride as gs, computeSchedule101 as gt, CcaClassResult as gu, computeMpDeduction as h, T2ScheduleValue as ha, Schedule3Result as hc, AlbertaSbdInput as hd, EifelThresholds as hi, NonCapitalLossByYearOfOriginInput as hl, CogpeInput as hn, assertAt1TaxPayableReconciles as ho, recaptureAddBack as hr, FedeRegularInput as hs, Schedule101Result as ht, CcaClassInput as hu, MP_GROSS_REVENUE_THRESHOLD as i, SbdInput as ia, AgriProcessingVintageInput as ic, LossContinuityResult as id, computeInterestAndFinancingExpenses as ii, IegInput as il, computeBusinessLimitAllocation as in, renderRsiHeader as io, Schedule1LineDefect as ir, CfreCountrySuccessorResult as is, T2LineKey as it, computeAlbertaSchedule17 as iu, t2Engine as j, albertaDispositionAdjustments as ja, at1LineItemId as jc, latestRateYear as jd, PROVINCE_RATES_2024 as ji, AT1_DONATION_INCOME_RATE as jl, computeSchedule12ResourceDeductions as jn, CcogpeSuccessorFederal as jo, BorrowingsResult as jr, computeAlbertaSchedule15 as js, GripInput as jt, Class141RecaptureReductionInput as ju, renderT2DraftReturn as k, albertaCcaScheduleAdjustments as ka, Schedule21FilingInput as kc, extendRateBook as kd, blendProvinceRateTable as ki, computeLimitedPartnershipLosses as kl, computeDepletion as kn, CcogpeRegularOverride as ko, ratioOfPermissibleExpenses as kr, SfedeCountrySuccessorOverride as ks, Schedule54Result as kt, Class141AdditionalAllowanceInput as ku, Part2MPProfitsInput as l, computeSBD as la, CapitalInvestmentTaxCreditResult as lc, LossCarrybackYear as ld, computePartnershipIfeAddBack as li, IegEligibleExpendituresInput as ll, ReserveContinuityRow as ln, At1FilingData as lo, ccaDeduction as lr, EdaRegularInput as ls, runConformanceSuite as lt, AlbertaCcaOverride as lu, computeCanadianMPProfits as m, T2ScheduleData as ma, Schedule3Input as mc, AlbertaCorporationStatus as md, EifelResult as mi, LossVintageRowResult as ml, CeeResult as mn, assertAt1MandatoryComplete as mo, mealsAndEntertainmentAddBack as mr, FedeRegularFederal as ms, Schedule101Input as mt, computeAlbertaSchedule13 as mu, CanadianMPProfitsResult as n, BusinessLimitInput as na, AgriProcessingTaxCreditInput as nc, computeAt4970 as nd, computeExcessIfe as ni, computeIegGroupFigures as nl, BusinessLimitAllocationResult as nn, formatRsiText as no, Schedule1Input as nr, CfreCountrySuccessorInput as ns, ExpectedSource as nt, At1ReserveRowResult as nu, MpDeductionInput as o, computeAdjustedAggregateInvestmentIncome as oa, At1ScheduleDataLike$1 as oc, LossCarrybackError as od, computeLoans as oi, computeIeg as ol, Schedule21Result as on, renderAt1NetFile as oo, Schedule1Result as or, CmedbInput as os, foldT2Lines as ot, AlbertaSchedule16Result as ou, SmallManufacturerTestResult as p, resolveCorpTaxRates as pa, MaximumAllowableDeductionResult as pc, computeAlbertaTax as pd, EifelInput as pi, LossVintageEntry as pl, CeeInput as pn, albertaBalanceUnpaid as po, incomeTaxProvisionAddBack as pr, EdaSuccessorResult as ps, FirstReturnEvent as pt, FederalCcaClass as pu, computeQuebecTax as q, RSI_DELIMITER as qa, IegAgreementMemberResult as qc, CcpcActiveBusinessTaxResult as qi, SECTION_34_2_GROSS_UP as ql, computeSchedule4Losses as qn, CeeSuccessorFederal as qo, LossPortionFromIfeRow as qr, schedule15Values as qs, ItcRecaptureItemResult as qt, CcaRateTable as qu, MP_EXCLUDED_ACTIVITIES as r, BusinessLimitResult as ra, AgriProcessingTaxCreditResult as rc, LossContinuityInput as rd, computeExemptIfe as ri, IEG_2024 as rl, allocateEvenly as rn, renderAt1Rsi as ro, Schedule1Line as rr, CfreCountrySuccessorOverride as rs, LineCheck as rt, At1ReserveTable as ru, MpDeductionRates as s, computeAggregateInvestmentIncome as sa, At1ScheduleValueLike$1 as sc, LossCarrybackInput as sd, computeLossPortionFromIfe as si, computeIegBaseAmount as sl, computeSchedule21 as sn, AT1_CRITICAL_MANDATORY_FIELDS as so, amortizationAddBack as sr, CmedbResult as ss, formatConformanceReport as st, assistanceFrom as su, CanadianMPProfitsInput as t, AggregateInvestmentIncomeResult as ta, AgriProcessingCurrentYearInput as tc, At4970Totals as td, computeClause95Amounts as ti, computeIegAgreement as tl, BusinessLimitAllocationInput as tn, formatRsiDate as to, computeSchedule2 as tr, CfreCountrySuccessorFederal as ts, ConformanceSummary as tt, At1ReserveKind as tu, Part2MPProfitsResult as u, CORP_TAX_2024 as ua, InvestorTaxCreditInput as uc, computeLossCarryback as ud, computeResourceIfe as ui, IegEligibleExpendituresResult as ul, computeSchedule13 as un, At1MandatoryFieldMissingError as uo, computeSchedule1 as ur, EdaRegularResult as us, FederalT2Input as ut, AlbertaSchedule13ClassResult as uu, T2SettlementInput as v, t2LineItemId as va, AllocationFactorInput as vc, AB_GENERAL_RATE_BANDS as vd, EifelCapacityResult as vi, OtherLossVintageEntry as vl, DepletionResult as vn, at1YesNo as vo, PartVI1DeductionBand as vr, FedeSuccessorFederal as vs, Schedule88Input as vt, Schedule8Entry as vu, T2CifPartI as w, Schedule12Line as wa, At1ScheduleValue as wc, AlbertaTaxRates as wd, AdjustedTaxableIncomeResult as wi, computeRifeContinuity as wl, Schedule12ResourceDeductionsResult as wn, computeAlbertaReturn as wo, EIFEL_STANDARD_RATIO_FROM as wr, SfedeCountryRegularInput as ws, LRIP_INVESTMENT_CORPORATION_MULTIPLE as wt, CLASS_14_1_MINIMUM_DEDUCTION as wu, T2CifAddress as x, computeLossSchedule as xa, AT1_SCHEDULES_WITHOUT_BUILDERS as xc, computeDayWeightedGeneralTax as xd, computeEifelCapacity as xi, computeOtherLossByYearOfOrigin as xl, ForeignPerCountryInput as xn, at1Engine as xo, partVI1DeductionMultiple as xr, FedeSuccessorResult as xs, Schedule55Input as xt, computeCcaClass as xu, T2SettlementResult as y, LossScheduleInput as ya, SINGLE_JURISDICTION_ALBERTA_FACTOR as yc, DayWeightedRateResult as yd, ExcessCapacityVintage as yi, OtherLossVintageRowResult as yl, ForeignExplorationInput as yn, xmlEscape as yo, PartVI1DeductionResult as yr, FedeSuccessorInput as ys, Schedule88Result as yt, Schedule8Result as yu, QuebecReturnInput as z, At1TransmitterInvalidError as za, schedule1Values$1 as zc, TaxableIncomeLine as zi, AT1_DISPOSITION_CATEGORIES as zl, computeSchedule5 as zn, CdeSuccessorFederal as zo, ExemptIfeRow as zr, computeCfreSuccessor as zs, TaxableCapitalInput as zt, MIN_LEASEHOLD_PERIODS as zu };