<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/test/ruby/test_iseq.rb, branch v3_3_11</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>merge revision(s) 992596fb7af18a7f472589a607d0eb3fbb03b49a: [Backport #20344]</title>
<updated>2024-09-02T10:10:19+00:00</updated>
<author>
<name>Takashi Kokubun</name>
<email>takashikkbn@gmail.com</email>
</author>
<published>2024-09-02T10:10:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=d83b5633b16f4ddcece4ff924f21c5a5851470cf'/>
<id>d83b5633b16f4ddcece4ff924f21c5a5851470cf</id>
<content type='text'>
	Fix next inside block argument stack underflow

	[Bug #20344]
	Fix compile_next adding removable adjust label
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	Fix next inside block argument stack underflow

	[Bug #20344]
	Fix compile_next adding removable adjust label
</pre>
</div>
</content>
</entry>
<entry>
<title>merge revision(s) 1870505f478cc75993b296b7144a45137ace6937: [Backport #20651]</title>
<updated>2024-09-02T09:56:18+00:00</updated>
<author>
<name>Takashi Kokubun</name>
<email>takashikkbn@gmail.com</email>
</author>
<published>2024-09-02T09:56:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=6a4e79533b4454392f3afdfa0c4d35b763b68466'/>
<id>6a4e79533b4454392f3afdfa0c4d35b763b68466</id>
<content type='text'>
	Fix wrong unreachable chunk remove when jump destination label is unremovable
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
	Fix wrong unreachable chunk remove when jump destination label is unremovable
</pre>
</div>
</content>
</entry>
<entry>
<title>[3.3 backport] compile.c: use putspecialobject for RubyVM::FrozenCore (#10962)</title>
<updated>2024-06-11T18:08:31+00:00</updated>
<author>
<name>Jean byroot Boussier</name>
<email>jean.boussier+github@shopify.com</email>
</author>
<published>2024-06-11T18:08:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=8951040aadca57fce633b0f714248de78a962c22'/>
<id>8951040aadca57fce633b0f714248de78a962c22</id>
<content type='text'>
compile.c: use putspecialobject for RubyVM::FrozenCore

[Bug #20569]

`putobject RubyVM::FrozenCore`, is not serializable, we
have to use `putspecialobject VM_SPECIAL_OBJECT_VMCORE`.

Co-authored-by: Jean Boussier &lt;jean.boussier@gmail.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
compile.c: use putspecialobject for RubyVM::FrozenCore

[Bug #20569]

`putobject RubyVM::FrozenCore`, is not serializable, we
have to use `putspecialobject VM_SPECIAL_OBJECT_VMCORE`.

Co-authored-by: Jean Boussier &lt;jean.boussier@gmail.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>[PRISM] Fix `compile_prism` when src is a file</title>
<updated>2023-12-15T15:27:44+00:00</updated>
<author>
<name>eileencodes</name>
<email>eileencodes@gmail.com</email>
</author>
<published>2023-12-13T17:49:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=049a9bd62f0907caa8d2eca6337cd2542a5c7726'/>
<id>049a9bd62f0907caa8d2eca6337cd2542a5c7726</id>
<content type='text'>
`compile_prism` can take a source and file (and other arguments) or a
file as the source. `compile` checks if the source is a file and if it
is converts it. `compile_prism` is now doing the same thing.

On the Ruby side `compile` handles a file
[here](https://github.com/ruby/ruby/blob/master/iseq.c#L1159-L1162).

Before:

```
"********* Ruby *************"
== disasm: #&lt;ISeq:&lt;compiled&gt;@&lt;compiled&gt;:1 (1,0)-(26,21)&gt;
local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1])
[ 1] name@0
0000 putstring                              "Prism"                   (  25)[Li]
0002 setlocal                               name@0, 0
0005 putself                                                          (  26)[Li]
0006 putobject                              "hello, "
0008 getlocal                               name@0, 0
0011 dup
0012 objtostring                            &lt;calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE&gt;
0014 anytostring
0015 concatstrings                          2
0017 send                                   &lt;calldata!mid:puts, argc:1, FCALL|ARGS_SIMPLE&gt;, nil
0020 leave
hello, Prism

"********* PRISM *************"
./test.rb:13:in `compile_prism': wrong argument type File (expected String) (TypeError)
	from ./test.rb:13:in `&lt;main&gt;'
make: *** [run] Error 1
```

After:

```
"********* Ruby *************"
== disasm: #&lt;ISeq:&lt;compiled&gt;@&lt;compiled&gt;:1 (1,0)-(26,21)&gt;
local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1])
[ 1] name@0
0000 putstring                              "Prism"                   (  25)[Li]
0002 setlocal                               name@0, 0
0005 putself                                                          (  26)[Li]
0006 putobject                              "hello, "
0008 getlocal                               name@0, 0
0011 dup
0012 objtostring                            &lt;calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE&gt;
0014 anytostring
0015 concatstrings                          2
0017 send                                   &lt;calldata!mid:puts, argc:1, FCALL|ARGS_SIMPLE&gt;, nil
0020 leave

"********* PRISM *************"
== disasm: #&lt;ISeq:&lt;compiled&gt;@test_code.rb:24 (24,0)-(25,21)&gt;
local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1])
[ 1] name@0
0000 putstring                              "Prism"                   (  24)[Li]
0002 setlocal                               name@0, 0
0005 putself                                                          (  25)[Li]
0006 putobject                              "hello, "
0008 getlocal                               name@0, 0
0011 dup
0012 objtostring                            &lt;calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE&gt;
0014 anytostring
0015 concatstrings                          2
0017 send                                   &lt;calldata!mid:puts, argc:1, FCALL|ARGS_SIMPLE&gt;, nil
0020 leave                                                            (  24)
```

Fixes ruby/prism#1609
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
`compile_prism` can take a source and file (and other arguments) or a
file as the source. `compile` checks if the source is a file and if it
is converts it. `compile_prism` is now doing the same thing.

On the Ruby side `compile` handles a file
[here](https://github.com/ruby/ruby/blob/master/iseq.c#L1159-L1162).

Before:

```
"********* Ruby *************"
== disasm: #&lt;ISeq:&lt;compiled&gt;@&lt;compiled&gt;:1 (1,0)-(26,21)&gt;
local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1])
[ 1] name@0
0000 putstring                              "Prism"                   (  25)[Li]
0002 setlocal                               name@0, 0
0005 putself                                                          (  26)[Li]
0006 putobject                              "hello, "
0008 getlocal                               name@0, 0
0011 dup
0012 objtostring                            &lt;calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE&gt;
0014 anytostring
0015 concatstrings                          2
0017 send                                   &lt;calldata!mid:puts, argc:1, FCALL|ARGS_SIMPLE&gt;, nil
0020 leave
hello, Prism

"********* PRISM *************"
./test.rb:13:in `compile_prism': wrong argument type File (expected String) (TypeError)
	from ./test.rb:13:in `&lt;main&gt;'
make: *** [run] Error 1
```

After:

```
"********* Ruby *************"
== disasm: #&lt;ISeq:&lt;compiled&gt;@&lt;compiled&gt;:1 (1,0)-(26,21)&gt;
local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1])
[ 1] name@0
0000 putstring                              "Prism"                   (  25)[Li]
0002 setlocal                               name@0, 0
0005 putself                                                          (  26)[Li]
0006 putobject                              "hello, "
0008 getlocal                               name@0, 0
0011 dup
0012 objtostring                            &lt;calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE&gt;
0014 anytostring
0015 concatstrings                          2
0017 send                                   &lt;calldata!mid:puts, argc:1, FCALL|ARGS_SIMPLE&gt;, nil
0020 leave

"********* PRISM *************"
== disasm: #&lt;ISeq:&lt;compiled&gt;@test_code.rb:24 (24,0)-(25,21)&gt;
local table (size: 1, argc: 0 [opts: 0, rest: -1, post: 0, block: -1, kw: -1@-1, kwrest: -1])
[ 1] name@0
0000 putstring                              "Prism"                   (  24)[Li]
0002 setlocal                               name@0, 0
0005 putself                                                          (  25)[Li]
0006 putobject                              "hello, "
0008 getlocal                               name@0, 0
0011 dup
0012 objtostring                            &lt;calldata!mid:to_s, argc:0, FCALL|ARGS_SIMPLE&gt;
0014 anytostring
0015 concatstrings                          2
0017 send                                   &lt;calldata!mid:puts, argc:1, FCALL|ARGS_SIMPLE&gt;, nil
0020 leave                                                            (  24)
```

Fixes ruby/prism#1609
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix portability of bignum in ISeq Binary Format</title>
<updated>2023-11-26T02:42:02+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2023-11-25T15:28:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=7fe7b7bc5a7a3d79280c9dbf2a2383d386386b0f'/>
<id>7fe7b7bc5a7a3d79280c9dbf2a2383d386386b0f</id>
<content type='text'>
- Unless `sizeof(BDIGIT) == 4`, (8-byte integer not available), the
  size to be loaded was wrong.
- Since `BDIGIT`s are dumped as raw binary, the loaded byte order was
  inverted unless little-endian.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- Unless `sizeof(BDIGIT) == 4`, (8-byte integer not available), the
  size to be loaded was wrong.
- Since `BDIGIT`s are dumped as raw binary, the loaded byte order was
  inverted unless little-endian.
</pre>
</div>
</content>
</entry>
<entry>
<title>[Bug #19906] Add the test</title>
<updated>2023-10-01T14:58:24+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2023-10-01T14:58:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=ec3d81629ff193e847dcab9afb20dffa14f2582a'/>
<id>ec3d81629ff193e847dcab9afb20dffa14f2582a</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Suppress an unused variable warning</title>
<updated>2023-09-13T01:24:55+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2023-09-13T01:24:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=435b243978995237f7d4c386bb312d8cdae8b50b'/>
<id>435b243978995237f7d4c386bb312d8cdae8b50b</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[Bug #19862] Skip compiled result of never reachable expression</title>
<updated>2023-09-12T23:30:37+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2023-09-05T15:44:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=6e64d4370456190541705ec4c6cf3af6bf4ac647'/>
<id>6e64d4370456190541705ec4c6cf3af6bf4ac647</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>support `rescue` event for TracePoint</title>
<updated>2023-08-01T13:46:17+00:00</updated>
<author>
<name>Koichi Sasada</name>
<email>ko1@atdot.net</email>
</author>
<published>2023-08-01T08:25:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=d68c01fd314ebd6dc1d89c95a2734fad4f0953b0'/>
<id>d68c01fd314ebd6dc1d89c95a2734fad4f0953b0</id>
<content type='text'>
fix [Feature #19572]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
fix [Feature #19572]
</pre>
</div>
</content>
</entry>
<entry>
<title>[Bug #19611] Remove never-reachable branch in logical expression</title>
<updated>2023-04-27T05:52:22+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2023-04-24T13:21:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=c7bacf84f04201787d26e4a4be8aca61ff1e454b'/>
<id>c7bacf84f04201787d26e4a4be8aca61ff1e454b</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
