<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/test/ruby/test_object.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>Make the SHAPE_TOO_COMPLEX performance warning more actionable</title>
<updated>2023-12-18T09:33:18+00:00</updated>
<author>
<name>Jean Boussier</name>
<email>byroot@ruby-lang.org</email>
</author>
<published>2023-12-18T08:59:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=ba1d1522d35a7dd2595603ead57cd0fa8b21ba8b'/>
<id>ba1d1522d35a7dd2595603ead57cd0fa8b21ba8b</id>
<content type='text'>
As suggested by Mame, we should try to help users fix the issues
without having to lookup the meaning of the warning.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As suggested by Mame, we should try to help users fix the issues
without having to lookup the meaning of the warning.
</pre>
</div>
</content>
</entry>
<entry>
<title>Re-embed when removing Object instance variables</title>
<updated>2023-12-06T16:34:07+00:00</updated>
<author>
<name>Peter Zhu</name>
<email>peter@peterzhu.ca</email>
</author>
<published>2023-12-06T12:37:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=12e3b07455fea0e99e6aaf1893a7883fb2b0197e'/>
<id>12e3b07455fea0e99e6aaf1893a7883fb2b0197e</id>
<content type='text'>
Objects with the same shape must always have the same "embeddedness"
(either embedded or heap allocated) because YJIT assumes so. However,
using remove_instance_variable, it's possible that some objects are
embedded and some are heap allocated because it does not re-embed heap
allocated objects.

This commit changes remove_instance_variable to re-embed Object
instance variables when it becomes small enough.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Objects with the same shape must always have the same "embeddedness"
(either embedded or heap allocated) because YJIT assumes so. However,
using remove_instance_variable, it's possible that some objects are
embedded and some are heap allocated because it does not re-embed heap
allocated objects.

This commit changes remove_instance_variable to re-embed Object
instance variables when it becomes small enough.
</pre>
</div>
</content>
</entry>
<entry>
<title>Make the maximum shapes variation warning non-verbose</title>
<updated>2023-05-03T08:43:46+00:00</updated>
<author>
<name>Jean Boussier</name>
<email>byroot@ruby-lang.org</email>
</author>
<published>2023-04-18T10:36:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=04ee666aab071cb6fd9a8b356b22d73250ca6b9b'/>
<id>04ee666aab071cb6fd9a8b356b22d73250ca6b9b</id>
<content type='text'>
[Feature #19538]

Since that category is not enabled by default, making it a
verbose warning is redundant. Enabling performance warning should
work with the default verbosity level.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[Feature #19538]

Since that category is not enabled by default, making it a
verbose warning is redundant. Enabling performance warning should
work with the default verbosity level.
</pre>
</div>
</content>
</entry>
<entry>
<title>Emit a performance warning when a class reached max variations</title>
<updated>2023-04-13T14:36:17+00:00</updated>
<author>
<name>Jean Boussier</name>
<email>byroot@ruby-lang.org</email>
</author>
<published>2023-04-13T10:11:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=ac123f167a364c3d7a43eca78d564e41f6dbb91e'/>
<id>ac123f167a364c3d7a43eca78d564e41f6dbb91e</id>
<content type='text'>
[Feature #19538]

This new `peformance` warning category is disabled by default.
It needs to be specifically enabled via `-W:performance` or `Warning[:performance] = true`
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[Feature #19538]

This new `peformance` warning category is disabled by default.
It needs to be specifically enabled via `-W:performance` or `Warning[:performance] = true`
</pre>
</div>
</content>
</entry>
<entry>
<title>Use rb_inspect instead of +PRIsVALUE for Object.inspect</title>
<updated>2022-12-09T13:11:00+00:00</updated>
<author>
<name>Matt Valentine-House</name>
<email>matt@eightbitraptor.com</email>
</author>
<published>2022-12-07T16:01:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=181d4bee5e03a30596e78b2d7aa0396887a53881'/>
<id>181d4bee5e03a30596e78b2d7aa0396887a53881</id>
<content type='text'>
In order to preserve the values when TrueClass, FalseClass or NilClass
are stored in ivars
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In order to preserve the values when TrueClass, FalseClass or NilClass
are stored in ivars
</pre>
</div>
</content>
</entry>
<entry>
<title>Freeze singleton class, not its origin</title>
<updated>2022-12-08T20:58:26+00:00</updated>
<author>
<name>Alan Wu</name>
<email>XrXr@users.noreply.github.com</email>
</author>
<published>2022-12-06T17:06:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=bb8afd7265af41a75e8889774aa26f157f146380'/>
<id>bb8afd7265af41a75e8889774aa26f157f146380</id>
<content type='text'>
Previously, when we froze an object, we froze
`RCLASS_ORIGIN(object.singleton_class)`, which didn't freeze
`object.singleton_class` when it has some prepended modules.

Origin iclass are internal objects and users can't interact with
them through Kernel#freeze?, Kernel#freeze, or any mutation method
that checks the frozen status. So we shouldn't touch the origin
iclasses when the frozen status should be visible.

[Bug #19169]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously, when we froze an object, we froze
`RCLASS_ORIGIN(object.singleton_class)`, which didn't freeze
`object.singleton_class` when it has some prepended modules.

Origin iclass are internal objects and users can't interact with
them through Kernel#freeze?, Kernel#freeze, or any mutation method
that checks the frozen status. So we shouldn't touch the origin
iclasses when the frozen status should be visible.

[Bug #19169]
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "Revert "This commit implements the Object Shapes technique in CRuby.""</title>
<updated>2022-10-11T15:40:56+00:00</updated>
<author>
<name>Jemma Issroff</name>
<email>jemmaissroff@gmail.com</email>
</author>
<published>2022-10-03T15:14:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=ad63b668e22e21c352b852f3119ae98a7acf99f1'/>
<id>ad63b668e22e21c352b852f3119ae98a7acf99f1</id>
<content type='text'>
This reverts commit 9a6803c90b817f70389cae10d60b50ad752da48f.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit 9a6803c90b817f70389cae10d60b50ad752da48f.
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "This commit implements the Object Shapes technique in CRuby."</title>
<updated>2022-09-30T23:01:50+00:00</updated>
<author>
<name>Aaron Patterson</name>
<email>tenderlove@ruby-lang.org</email>
</author>
<published>2022-09-30T23:01:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=9a6803c90b817f70389cae10d60b50ad752da48f'/>
<id>9a6803c90b817f70389cae10d60b50ad752da48f</id>
<content type='text'>
This reverts commit 68bc9e2e97d12f80df0d113e284864e225f771c2.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit 68bc9e2e97d12f80df0d113e284864e225f771c2.
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix frozen object inspect</title>
<updated>2022-09-30T20:57:59+00:00</updated>
<author>
<name>eileencodes</name>
<email>eileencodes@gmail.com</email>
</author>
<published>2022-09-30T19:37:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=0ab0229c1162308509b36cafbf6eaafd7ae054d7'/>
<id>0ab0229c1162308509b36cafbf6eaafd7ae054d7</id>
<content type='text'>
In the rails/rails CI build for Ruby master we found that some tests
were failing due to inspect on a frozen object being incorrect.

An object's instance variable count was incorrect when frozen causing
the object's inspect to not splat out the object.

This fixes the issue and adds a test for inspecting frozen objects.

Co-Authored-By: Jemma Issroff &lt;jemmaissroff@gmail.com&gt;
Co-Authored-By: Aaron Patterson &lt;tenderlove@ruby-lang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In the rails/rails CI build for Ruby master we found that some tests
were failing due to inspect on a frozen object being incorrect.

An object's instance variable count was incorrect when frozen causing
the object's inspect to not splat out the object.

This fixes the issue and adds a test for inspecting frozen objects.

Co-Authored-By: Jemma Issroff &lt;jemmaissroff@gmail.com&gt;
Co-Authored-By: Aaron Patterson &lt;tenderlove@ruby-lang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[WIP] add error_squiggle gem</title>
<updated>2021-06-29T14:45:49+00:00</updated>
<author>
<name>Yusuke Endoh</name>
<email>mame@ruby-lang.org</email>
</author>
<published>2021-06-18T08:11:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=e94604966572bb43fc887856d54aa54b8e9f7719'/>
<id>e94604966572bb43fc887856d54aa54b8e9f7719</id>
<content type='text'>
```
$ ./local/bin/ruby -e '1.time {}'
-e:1:in `&lt;main&gt;': undefined method `time' for 1:Integer (NoMethodError)

1.time {}
 ^^^^^
Did you mean?  times
```

https://bugs.ruby-lang.org/issues/17930
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
```
$ ./local/bin/ruby -e '1.time {}'
-e:1:in `&lt;main&gt;': undefined method `time' for 1:Integer (NoMethodError)

1.time {}
 ^^^^^
Did you mean?  times
```

https://bugs.ruby-lang.org/issues/17930
</pre>
</div>
</content>
</entry>
</feed>
