Commit 2ce6679
authored
avm2: Store PropertyClass in
Calling `get_trait` copies the returned `Property`, so the caching
we performed in `PropertyClass` was never actually getting used.
Instead, we now store our `PropertyClass` values in a `Vec`
indexed by slot id. `set_property` and `init_property` now perform
coercions by going through the `VTable,` which writes the updated
`PropertyClass` back into the array.VtableData
1 parent 01a0d70 commit 2ce6679
3 files changed
+90
-56
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
145 | | - | |
146 | | - | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
147 | 148 | | |
148 | 149 | | |
149 | 150 | | |
| |||
197 | 198 | | |
198 | 199 | | |
199 | 200 | | |
200 | | - | |
201 | | - | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
202 | 206 | | |
203 | 207 | | |
204 | 208 | | |
| |||
247 | 251 | | |
248 | 252 | | |
249 | 253 | | |
250 | | - | |
251 | | - | |
252 | | - | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
253 | 259 | | |
254 | 260 | | |
255 | 261 | | |
| |||
303 | 309 | | |
304 | 310 | | |
305 | 311 | | |
306 | | - | |
307 | | - | |
| 312 | + | |
308 | 313 | | |
309 | 314 | | |
310 | 315 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
30 | 19 | | |
31 | 20 | | |
32 | 21 | | |
| |||
42 | 31 | | |
43 | 32 | | |
44 | 33 | | |
45 | | - | |
| 34 | + | |
46 | 35 | | |
47 | 36 | | |
48 | 37 | | |
| |||
61 | 50 | | |
62 | 51 | | |
63 | 52 | | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
64 | 57 | | |
65 | 58 | | |
66 | 59 | | |
67 | 60 | | |
68 | | - | |
69 | | - | |
70 | | - | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
71 | 64 | | |
72 | 65 | | |
73 | 66 | | |
74 | 67 | | |
75 | 68 | | |
76 | 69 | | |
77 | | - | |
| 70 | + | |
78 | 71 | | |
79 | 72 | | |
80 | 73 | | |
81 | | - | |
| 74 | + | |
82 | 75 | | |
83 | 76 | | |
84 | 77 | | |
| |||
103 | 96 | | |
104 | 97 | | |
105 | 98 | | |
106 | | - | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
107 | 102 | | |
108 | 103 | | |
109 | 104 | | |
| |||
115 | 110 | | |
116 | 111 | | |
117 | 112 | | |
118 | | - | |
| 113 | + | |
119 | 114 | | |
120 | 115 | | |
121 | 116 | | |
122 | | - | |
| 117 | + | |
123 | 118 | | |
124 | 119 | | |
125 | 120 | | |
126 | | - | |
| 121 | + | |
127 | 122 | | |
128 | 123 | | |
129 | 124 | | |
| |||
191 | 186 | | |
192 | 187 | | |
193 | 188 | | |
194 | | - | |
| 189 | + | |
195 | 190 | | |
196 | 191 | | |
197 | 192 | | |
| |||
210 | 205 | | |
211 | 206 | | |
212 | 207 | | |
213 | | - | |
214 | | - | |
| 208 | + | |
| 209 | + | |
215 | 210 | | |
216 | 211 | | |
217 | | - | |
218 | | - | |
| 212 | + | |
| 213 | + | |
219 | 214 | | |
220 | 215 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
30 | | - | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
31 | 35 | | |
32 | 36 | | |
33 | 37 | | |
| |||
54 | 58 | | |
55 | 59 | | |
56 | 60 | | |
| 61 | + | |
57 | 62 | | |
58 | 63 | | |
59 | 64 | | |
| |||
64 | 69 | | |
65 | 70 | | |
66 | 71 | | |
67 | | - | |
| 72 | + | |
68 | 73 | | |
69 | 74 | | |
70 | 75 | | |
71 | 76 | | |
72 | 77 | | |
73 | 78 | | |
74 | 79 | | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
75 | 100 | | |
76 | 101 | | |
77 | 102 | | |
| |||
175 | 200 | | |
176 | 201 | | |
177 | 202 | | |
| 203 | + | |
178 | 204 | | |
179 | 205 | | |
180 | 206 | | |
| |||
195 | 221 | | |
196 | 222 | | |
197 | 223 | | |
198 | | - | |
| 224 | + | |
199 | 225 | | |
200 | 226 | | |
201 | 227 | | |
| 228 | + | |
202 | 229 | | |
203 | 230 | | |
204 | 231 | | |
| |||
299 | 326 | | |
300 | 327 | | |
301 | 328 | | |
302 | | - | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
303 | 336 | | |
304 | 337 | | |
305 | | - | |
306 | | - | |
| 338 | + | |
| 339 | + | |
307 | 340 | | |
308 | 341 | | |
309 | | - | |
310 | | - | |
| 342 | + | |
| 343 | + | |
311 | 344 | | |
312 | 345 | | |
313 | 346 | | |
314 | 347 | | |
315 | | - | |
316 | | - | |
| 348 | + | |
| 349 | + | |
317 | 350 | | |
318 | 351 | | |
319 | | - | |
320 | | - | |
| 352 | + | |
| 353 | + | |
321 | 354 | | |
322 | 355 | | |
323 | 356 | | |
324 | 357 | | |
325 | 358 | | |
326 | 359 | | |
| 360 | + | |
327 | 361 | | |
328 | 362 | | |
329 | 363 | | |
| |||
379 | 413 | | |
380 | 414 | | |
381 | 415 | | |
382 | | - | |
383 | | - | |
384 | | - | |
385 | | - | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
386 | 420 | | |
387 | 421 | | |
388 | 422 | | |
| |||
0 commit comments