General

Profile

silverhammermba (Max Anselm)

Issues

open closed Total
Assigned issues 0 0 0
Reported issues 0 6 6

Activity

11/02/2014

03:39 PM Ruby Bug #10466 (Closed): rb_eval_string_wrap does not actually wrap in a module binding
`rb_eval_string_wrap` says that it "evaluates the given string under a module binding in an isolated binding", but this isn't true.
Run the following:
~~~
#include <ruby.h>
int main(int argc, char* argv[])
{
ruby_init();
...
silverhammermba (Max Anselm)

11/01/2014

03:49 PM Ruby Bug #10454: %i doesn't have any special behavior in rb_sprintf et al.
Ah, I see now. I needed to use `%li`. It seems like README.EXT should mention `PRIsVALUE` instead of `%i`. silverhammermba (Max Anselm)
02:37 AM Ruby Feature #10463: :~@ and :!@ are not parsed correctly
That's because bash is trying to interpolate the string.
$ ruby -e 'p :!@'
:!
silverhammermba (Max Anselm)

10/31/2014

08:51 PM Ruby Bug #10454: %i doesn't have any special behavior in rb_sprintf et al.
Well I can't get it to work for some reason. When I run this code:
~~~C
#include <ruby.h>
VALUE func(VALUE arg)
{
VALUE str = rb_sprintf("%i %+i : %d %+d", Qtrue, Qtrue, Qtrue, Qtrue);
rb_funcall(rb_mKernel, rb_intern("puts")...
silverhammermba (Max Anselm)
08:33 PM Ruby Bug #10453: NUM2CHR() does not perform additional bounds checks
I would expect it to raise `RangeError` if the num exceeds the size of a `char`. That is the behavior of the all of the other `NUM2*` macros. silverhammermba (Max Anselm)

10/29/2014

08:56 PM Ruby Bug #10454 (Closed): %i doesn't have any special behavior in rb_sprintf et al.
README.EXT claims:
> In the format string, `%i` is used for `Object#to_s` (or `Object#inspect` if ‘+’ flag is set) output (and related argument must be a VALUE).
But if you look at the code, this isn't true. %d and %i are handled t...
silverhammermba (Max Anselm)
08:25 PM Ruby Bug #10453 (Rejected): NUM2CHR() does not perform additional bounds checks
`NUM2CHR()` just calls `rb_num2int_inline()` and masks off the high bytes. Consequently, passing any value larger than a `char` and no bigger than an `int` will return some garbage value (rather than raising `RangeError`).
To reproduc...
silverhammermba (Max Anselm)

05/14/2014

07:14 PM Ruby Bug #9836: Bad Implementation of Time.strptime
Sorry for the unclear wording. I would expect that it behaves similar to `DateTime`'s implementation and to not ignore any fields returned by `Date._strptime`. At the very least the documentation should reflect the fact that it will only... silverhammermba (Max Anselm)

05/13/2014

07:59 PM Ruby Bug #9836 (Closed): Bad Implementation of Time.strptime
According to the documentation, `Time.strptime` "parses +date+ using `Date._strptime` and converts it to a Time object." However this conversion is extremely naive, using only certain fields return by `Date._strptime` and ignoring the re... silverhammermba (Max Anselm)

04/04/2014

04:02 PM Ruby Bug #9703 (Closed): Inconsistent profile output
The output of the profile lib seems to be partially dependent on how it is required. For example,
~~~
ruby -rprofile -e '0==1'
~~~
shows one call to Fixnum#== as expected
~~~
ruby -e 'require "profile"; 0==1'
~~~
does not sho...
silverhammermba (Max Anselm)

Also available in: Atom