mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
merge revision(s) 6ca3d1af33
: [Backport #17552]
objspace_dump.c: Handle allocation path and line missing --- ext/objspace/objspace_dump.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-)
This commit is contained in:
parent
7899046315
commit
c09f5ee344
2 changed files with 10 additions and 5 deletions
|
@ -471,10 +471,15 @@ dump_object(VALUE obj, struct dump_config *dc)
|
|||
dump_append(dc, "]");
|
||||
|
||||
if (ainfo) {
|
||||
dump_append(dc, ", \"file\":\"");
|
||||
dump_append(dc, ainfo->path);
|
||||
dump_append(dc, "\", \"line\":");
|
||||
dump_append_lu(dc, ainfo->line);
|
||||
if (ainfo->path) {
|
||||
dump_append(dc, ", \"file\":\"");
|
||||
dump_append(dc, ainfo->path);
|
||||
dump_append(dc, "\"");
|
||||
}
|
||||
if (ainfo->line) {
|
||||
dump_append(dc, ", \"line\":");
|
||||
dump_append_lu(dc, ainfo->line);
|
||||
}
|
||||
if (RTEST(ainfo->mid)) {
|
||||
VALUE m = rb_sym2str(ainfo->mid);
|
||||
dump_append(dc, ", \"method\":");
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
# define RUBY_VERSION_MINOR RUBY_API_VERSION_MINOR
|
||||
#define RUBY_VERSION_TEENY 0
|
||||
#define RUBY_RELEASE_DATE RUBY_RELEASE_YEAR_STR"-"RUBY_RELEASE_MONTH_STR"-"RUBY_RELEASE_DAY_STR
|
||||
#define RUBY_PATCHLEVEL 25
|
||||
#define RUBY_PATCHLEVEL 26
|
||||
|
||||
#define RUBY_RELEASE_YEAR 2021
|
||||
#define RUBY_RELEASE_MONTH 2
|
||||
|
|
Loading…
Add table
Reference in a new issue