Repository navigation
Commit 7c86f75
committed
Read the instructions array patterns use from persisted IR
Array patterns compile to instructions that IRReaderStream couldn't
read back: TemporaryIntVariable operands, b_int, int_math and
as_fixnum. Each class already had a decode method, but the reader's
switches never called them, so loading a jrubyc-compiled file with an
array pattern failed with a NullPointerException.
IntegerMathInstr also didn't write its operands, so it couldn't have
been read back even with a reader case. It now writes them in the order
its decode method reads them.
Fixes jruby#98341 parent 32d3e80 commit 7c86f75
4 files changed
Lines changed: 13 additions & 0 deletions
File tree
- core/src/main/java/org/jruby/ir
- instructions
- operands
- persistence
- spec/compiler
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| 50 | + | |
| 51 | + | |
50 | 52 | | |
51 | 53 | | |
52 | 54 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
90 | 90 | | |
91 | 91 | | |
92 | 92 | | |
| 93 | + | |
93 | 94 | | |
94 | 95 | | |
95 | 96 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
252 | 252 | | |
253 | 253 | | |
254 | 254 | | |
| 255 | + | |
255 | 256 | | |
256 | 257 | | |
| 258 | + | |
257 | 259 | | |
258 | 260 | | |
259 | 261 | | |
| |||
301 | 303 | | |
302 | 304 | | |
303 | 305 | | |
| 306 | + | |
304 | 307 | | |
305 | 308 | | |
306 | 309 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
964 | 964 | | |
965 | 965 | | |
966 | 966 | | |
| 967 | + | |
| 968 | + | |
| 969 | + | |
| 970 | + | |
| 971 | + | |
| 972 | + | |
| 973 | + | |
967 | 974 | | |
968 | 975 | | |
969 | 976 | | |
| |||
0 commit comments