This commit introduces an "inline ivar cache" struct. The reason we
need this is so compaction can differentiate from an ivar cache and a
regular inline cache. Regular inline caches contain references to
`VALUE` and ivar caches just contain references to the ivar index. With
this new struct we can easily update references for inline caches (but
not inline var caches as they just contain an int)
```
.../gems/did_you_mean-1.3.1/lib/did_you_mean/version.rb:2: warning: already initialized constant DidYouMean::VERSION
.../lib/did_you_mean/version.rb:2: warning: previous definition of VERSION was here
```
I'm not entirely sure why, but test_set_winsize_console gets stuck on
Solaris (and if I recall, macOS). I found a hack for FreeBSD, so I want
to give it a try on Solaris too.
Introduce new RUBY_DEBUG option 'ci' to inform Ruby interpreter
that an interpreter is running on CI environment.
With this option, `rb_bug()` shows more information includes
method entry information, local variables information for each
control frame.
It fails to build on Solaris:
```
ossl_cipher.c: 関数 ‘ossl_cipher_init’ 内:
ossl_cipher.c:228:2: エラー: ‘EVP_md5’ is deprecated [-Werror=deprecated-declarations]
228 | EVP_BytesToKey(EVP_CIPHER_CTX_cipher(ctx), EVP_md5(), iv,
| ^~~~~~~~~~~~~~
In file included from /usr/include/openssl/x509.h:73,
from /usr/include/openssl/x509v3.h:63,
from ossl.h:23,
from ossl_cipher.c:10:
/usr/include/openssl/evp.h:732:26: 備考: ここで宣言されています
732 | DEPRECATED const EVP_MD *EVP_md5(void);
| ^~~~~~~
```
I agree that `-Werror=` is a good habit, but adding it by default is too
aggressive.
This issue happened when `libc.so` and `libm.so` path were not found
and `ldd ruby` command also failed to print the shared dependencies
in `test/fiddle/helper.rb`.
See https://travis-ci.org/ruby/ruby/jobs/611483288#L3018
/home/travis/build/ruby/ruby/build/.ext/common/fiddle/import.rb:299:in `import_function': cannot find the function: strcpy() (Fiddle::DLError)
* Set libc6:armhf as a installing dependency explicitly.
* Remove arm32 from allow_failures.
When debugging some local code, specifying a breakpoint to a local
filename does not work, i.e.
break lib/foo.rb:10
Expanding the filename makes it work. FWIW byebug has the same behavior.
jump-jump optimization ignores the event flags of the jump instruction
being skipped, which leads to overlook of line events.
This changeset stops the wrong optimization when coverage measurement is
neabled and when the jump instruction has any event flag.
Note that this issue is not only for coverage but also for TracePoint,
and this change does not fix TracePoint.
However, fixing it fundamentally is tough (which requires revamp of
the compiler). This issue is critical in terms of coverage measurement,
but minor for TracePoint (ko1 said), so we here choose a stopgap
measurement.
[Bug #15980] [Bug #16397]
Note for backporters: this changeset can be viewed by `git diff -w`.
To only emit the warnings in correct cases would require tracking
local variable usage in ripper, which ripper currently does not do.
Fixes [Bug #15188]
Previously, lambdas were converted to procs because of how
rb_block_call works. Switch to rb_funcall_with_block, which
handles procs as procs and lambdas as lambdas.
Fixes [Bug #15613]
This copies the private/deprecate constant visibility across the
autoload. It still is backwards compatible with setting the
private/deprecate constant visibility in the autoloaded file.
However, if you explicitly set public constant in the autoloaded
file, that will be reset after the autoload.
Fixes [Bug #11055]