Age | Commit message (Collapse) | Author |
|
This fixes instance_exec and similar methods. It also fixes
Enumerator::Yielder#yield, rb_yield_block, and a couple of cases
with Proc#{<<,>>}.
This support requires the addition of rb_yield_values_kw, similar to
rb_yield_values2, for passing the keyword flag.
Unlike earlier attempts at this, this does not modify the rb_block_call_func
type or add a separate function type. The functions of type
rb_block_call_func are called by Ruby with a separate VM frame, and we can
get the keyword flag information from the VM frame flags, so it doesn't need
to be passed as a function argument.
These changes require the following VM functions accept a keyword flag:
* vm_yield_with_cref
* vm_yield
* vm_yield_with_block
Notes:
Merged: https://github.com/ruby/ruby/pull/2493
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/2453
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/2484
|
|
OpenSSL::SSL::SSLSocket#sys{read,write}_nonblock
It's unlikely anyone would actually hit these. The methods are
private, you only hit this code path if calling these methods
before performing the SSL connection, and there is already a
verbose warning issued.
Notes:
Merged: https://github.com/ruby/ruby/pull/2484
|
|
https://github.com/ruby/io-console/commit/3d69c577a4
|
|
https://github.com/ruby/io-console/commit/77ed8d5a06
|
|
Cfuncs that use rb_scan_args with the : entry suffer similar keyword
argument separation issues that Ruby methods suffer if the cfuncs
accept optional or variable arguments.
This makes the following changes to : handling.
* Treats as **kw, prompting keyword argument separation warnings
if called with a positional hash.
* Do not look for an option hash if empty keywords are provided.
For backwards compatibility, treat an empty keyword splat as a empty
mandatory positional hash argument, but emit a a warning, as this
behavior will be removed in Ruby 3. The argument number check
needs to be moved lower so it can correctly handle an empty
positional argument being added.
* If the last argument is nil and it is necessary to treat it as an option
hash in order to make sure all arguments are processed, continue to
treat the last argument as the option hash. Emit a warning in this case,
as this behavior will be removed in Ruby 3.
* If splitting the keyword hash into two hashes, issue a warning, as we
will not be splitting hashes in Ruby 3.
* If the keyword argument is required to fill a mandatory positional
argument, continue to do so, but emit a warning as this behavior will
be going away in Ruby 3.
* If keyword arguments are provided and the last argument is not a hash,
that indicates something wrong. This can happen if a cfunc is calling
rb_scan_args multiple times, and providing arguments that were not
passed to it from Ruby. Callers need to switch to the new
rb_scan_args_kw function, which allows passing of whether keywords
were provided.
This commit fixes all warnings caused by the changes above.
It switches some function calls to *_kw versions with appropriate
kw_splat flags. If delegating arguments, RB_PASS_CALLED_KEYWORDS
is used. If creating new arguments, RB_PASS_KEYWORDS is used if
the last argument is a hash to be treated as keywords.
In open_key_args in io.c, use rb_scan_args_kw.
In this case, the arguments provided come from another C
function, not Ruby. The last argument may or may not be a hash,
so we can't set keyword argument mode. However, if it is a
hash, we don't want to warn when treating it as keywords.
In Ruby files, make sure to appropriately use keyword splats
or literal keywords when calling Cfuncs that now issue keyword
argument separation warnings through rb_scan_args. Also, make
sure not to pass nil in place of an option hash.
Work around Kernel#warn warnings due to problems in the Rubygems
override of the method. There is an open pull request to fix
these issues in Rubygems, but part of the Rubygems tests for
their override fail on ruby-head due to rb_scan_args not
recognizing empty keyword splats, which this commit fixes.
Implementation wise, adding rb_scan_args_kw is kind of a pain,
because rb_scan_args takes a variable number of arguments.
In order to not duplicate all the code, the function internals need
to be split into two functions taking a va_list, and to avoid passing
in a ton of arguments, a single struct argument is used to handle
the variables previously local to the function.
Notes:
Merged-By: jeremyevans <code@jeremyevans.net>
|
|
IO#ready? returns true or false only, since r50262(1baa57b0033).
|
|
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/2431
|
|
https://github.com/ruby/io-console/commit/9377e37295
|
|
To be consistent with `winsize`, changed the cursor position
format from `[x, y]` to `[row, column]`.
https://github.com/ruby/io-console/commit/d1f5ae9286
|
|
https://github.com/ruby/io-console/commit/b8017509ef
|
|
https://github.com/ruby/io-console/commit/a54b6e4dd1
|
|
This is how Kernel#{Array,String,Float,Integer,Hash,Rational} work.
BigDecimal and Complex instances are always frozen, so this should
not cause backwards compatibility issues for those. Pathname
instances are not frozen, so potentially this could cause backwards
compatibility issues by not returning a new object.
Based on a patch from Joshua Ballanco, some minor changes by me.
Fixes [Bug #7522]
Notes:
Merged: https://github.com/ruby/ruby/pull/2473
|
|
|
|
|
|
NMAKE sets MAKE to the full path name, which includes spaces by
the default installation.
|
|
* Removed excess backslashes
* Fixed the target name to try failure.cpp
|
|
To substitute suffixes and VPATH for nmake.
|
|
|
|
This reverts commit 69e209a3450bd6b281dcad1d96a34e9cab184845.
The debug has finishted.
|
|
|
|
|
|
|
|
|
|
|
|
Look up language module with `MakeMakefile.[]`, insted of a
accessing constant under that module directly, to get rid of
expose the constant to the toplevel inadvertently.
|
|
|
|
|
|
This makes method_missing take a flag for whether keyword arguments
were passed.
Adds tests both for rb_call_super_kw usage as well as general usage
of super calling method_missing in Ruby methods.
Notes:
Merged: https://github.com/ruby/ruby/pull/2462
|
|
Enters raw-mode but enable interrupts.
https://github.com/ruby/io-console/commit/7cba76561a
Notes:
Merged: https://github.com/ruby/ruby/pull/2459
|
|
https://github.com/ruby/io-console/commit/4e17c90788
|
|
About unused variables and a function.
https://github.com/ruby/io-console/commit/32baf54e7a
|
|
Addrinfo.getaddrinfo and .foreach now accepts :timeout in seconds as
a keyword argument. If getaddrinfo_a(3) is available, the timeout will be
applied for name resolution. Otherwise, it will be ignored.
Socket.tcp accepts :resolv_timeout to use this feature.
This commit is retry of 6382f5cc91ac9e36776bc854632d9a1237250da7.
Test was failed on Solaris machines which don't have "http" in
/etc/services. In this commit, use "ssh" instead.
|
|
https://github.com/ruby/io-console/commit/ee648fa8bb
Notes:
Merged: https://github.com/ruby/ruby/pull/2440
|
|
https://github.com/ruby/io-console/commit/83e70de8ab
Notes:
Merged: https://github.com/ruby/ruby/pull/2440
|
|
https://github.com/ruby/io-console/commit/e6344108a1
Notes:
Merged: https://github.com/ruby/ruby/pull/2440
|
|
https://github.com/ruby/io-console/commit/143a9d5764
Notes:
Merged: https://github.com/ruby/ruby/pull/2440
|
|
https://github.com/ruby/io-console/commit/21d340e4a2
Notes:
Merged: https://github.com/ruby/ruby/pull/2440
|
|
https://github.com/ruby/io-console/commit/7f2b1b473d
Notes:
Merged: https://github.com/ruby/ruby/pull/2440
|
|
https://github.com/ruby/io-console/commit/41a6a6cace
Notes:
Merged: https://github.com/ruby/ruby/pull/2440
|
|
A function to query console info.
https://github.com/ruby/io-console/commit/db75a07fa3
Notes:
Merged: https://github.com/ruby/ruby/pull/2440
|
|
https://github.com/ruby/io-console/commit/972ceb081d
Notes:
Merged: https://github.com/ruby/ruby/pull/2440
|
|
This is a test extension so we basically want test failures rather
than a configure breakage but if there is no C++ compiler, we need
no test at all because there will be no chance for the tested
header file to be used later.
This makes it possible to build the ruby binary without any C++
compiler installed in a build environment.
Notes:
Merged: https://github.com/ruby/ruby/pull/2434
|
|
These variables then get their room for storage.
See also https://github.com/ruby/ruby/runs/214042030
Notes:
Merged: https://github.com/ruby/ruby/pull/2434
|
|
This reverts commit 53d21087da078cf999cc4757b03b2ff0fab4c2cf.
Notes:
Merged: https://github.com/ruby/ruby/pull/2434
|
|
This reverts commit 6382f5cc91ac9e36776bc854632d9a1237250da7.
test failed on Solaris.
|
|
Addrinfo.getaddrinfo and .foreach now accepts :timeout in seconds as
a keyword argument. If getaddrinfo_a(3) is available, the timeout will be
applied for name resolution. Otherwise, it will be ignored.
Socket.tcp accepts :resolv_timeout to use this feature.
|
|
and NODE_ZARRAY to NODE_ZLIST.
NODE_ARRAY is used not only by an Array literal, but also the contents
of Hash literals, method call arguments, dynamic string literals, etc.
In addition, the structure of NODE_ARRAY is a linked list, not an array.
This is very confusing, so I believe `NODE_LIST` is a better name.
|