Commit f41a7a3
test(rust): the errors/ac_base pair is not the pair kotlin and swift had
Same two file names, same symptom in the CI matrix, different problem
underneath — worth writing down before someone ports the kotlin fix and
finds it does nothing.
kotlin and swift transpile `active_record/errors.rb` and only needed
`X < StandardError` rendered as a relation check. rust doesn't transpile
the file at all: `RecordNotFound` is an `errors_ext::FrameworkError`
const, so `RecordNotFound.new("…").message` has no type to reach.
Wiring the runtime entry was tried and measured; the note now records
what came out — the parent is dropped so there's no `message` field and
no Display/Error, `super(message)` hits an `ExprNode::Super` arm rust2's
expr emit doesn't have, optional params are dropped so the bare
`RecordNotFound.new()` the test calls has no constructor, and the
`raise(KIND, payload)` consts at ~11 sites in `active_record_base.rs`
collide with real structs of the same names. That last one is a design
call about how rust represents a raise, not a wiring fix.
ac_base is likewise a rust2 test-emit shape rather than a typing gap:
rust2 is the only per-target test emit that doesn't seed `test_extras`
from `app.rbs_signatures`, so the parent-signature adoption that greened
kotlin and swift never reaches it; the test class lowers to free
`#[test]` fns, so `@controller` from `setup` emits as `self.controller`
in a function with no `self` (all 54 E0424s, one cause); and the same
Instance→Class rewrite strips `&self` off the hoisted `TestController`,
whose base state rust would have to compose rather than inherit.
Refs #34.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>1 parent 083b870 commit f41a7a3
1 file changed
Lines changed: 53 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
167 | 167 | | |
168 | 168 | | |
169 | 169 | | |
170 | | - | |
171 | | - | |
172 | | - | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
173 | 175 | | |
174 | 176 | | |
175 | 177 | | |
| |||
186 | 188 | | |
187 | 189 | | |
188 | 190 | | |
189 | | - | |
190 | | - | |
191 | | - | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
192 | 220 | | |
193 | | - | |
194 | | - | |
195 | | - | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
196 | 240 | | |
197 | 241 | | |
198 | 242 | | |
| |||
0 commit comments