ruby-dev (Japanese) list archive (unofficial mirror)
 help / color / mirror / Atom feed
* [ruby-dev:51128] [Ruby master Bug#18433] 「‘rb_cData’ is deprecated: by: rb_cObject.  Will be removed in 3.1.」が 3.1 でも出力される
@ 2021-12-26  3:07 tommy (Masahiro Tomita)
  2021-12-26  4:51 ` [ruby-dev:51129] " nobu (Nobuyoshi Nakada)
  0 siblings, 1 reply; 2+ messages in thread
From: tommy (Masahiro Tomita) @ 2021-12-26  3:07 UTC (permalink / raw)
  To: ruby-dev

Issue #18433 has been reported by tommy (Masahiro Tomita).

----------------------------------------
Bug #18433: 「‘rb_cData’ is deprecated: by: rb_cObject.  Will be removed in 3.1.」が 3.1 でも出力される
https://bugs.ruby-lang.org/issues/18433

* Author: tommy (Masahiro Tomita)
* Status: Open
* Priority: Normal
* ruby -v: ruby 3.1.0p0 (2021-12-25 revision fb4df44d16) [x86_64-linux]
* Backport: 2.6: UNKNOWN, 2.7: UNKNOWN, 3.0: UNKNOWN
----------------------------------------
拡張ライブラリ内で rb_cData を使うと
```
‘rb_cData’ is deprecated: by: rb_cObject.  Will be removed in 3.1.
```
という warning が出力されますが、これが 3.1 でも出ます。
別に害はないのですが、メッセージとしては妙な感じです。

```
/tmp/hoge% cat hoge.c 
#include <ruby.h>
void Init_hoge(void)
{
  rb_cData;
}

/tmp/hoge% cat extconf.rb 
require 'mkmf'
create_makefile('hoge')

/tmp/hoge% ruby -v extconf.rb 
ruby 3.1.0p0 (2021-12-25 revision fb4df44d16) [x86_64-linux]
creating Makefile

/tmp/hoge% make
compiling hoge.c
hoge.c: In function ‘Init_hoge’:
hoge.c:4:3: warning: ‘rb_cData’ is deprecated: by: rb_cObject.  Will be removed in 3.1. [-Wdeprecated-declarations]
    4 |   rb_cData;
      |   ^~~~~~~~
In file included from /home/tommy/ruby31/include/ruby-3.1.0/ruby/internal/core.h:27,
                 from /home/tommy/ruby31/include/ruby-3.1.0/ruby/ruby.h:28,
                 from /home/tommy/ruby31/include/ruby-3.1.0/ruby.h:38,
                 from hoge.c:1:
/home/tommy/ruby31/include/ruby-3.1.0/ruby/internal/core/rdata.h:382:1: note: declared here
  382 | rb_cData(void)
      | ^~~~~~~~
hoge.c: At top level:
cc1: note: unrecognized command-line option ‘-Wno-self-assign’ may have been intended to silence earlier diagnostics
cc1: note: unrecognized command-line option ‘-Wno-parentheses-equality’ may have been intended to silence earlier diagnostics
cc1: note: unrecognized command-line option ‘-Wno-constant-logical-operand’ may have been intended to silence earlier diagnostics
linking shared-object hoge.so
/tmp/hoge% 
```



-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [ruby-dev:51129] [Ruby master Bug#18433] 「‘rb_cData’ is deprecated: by: rb_cObject.  Will be removed in 3.1.」が 3.1 でも出力される
  2021-12-26  3:07 [ruby-dev:51128] [Ruby master Bug#18433] 「‘rb_cData’ is deprecated: by: rb_cObject. Will be removed in 3.1.」が 3.1 でも出力される tommy (Masahiro Tomita)
@ 2021-12-26  4:51 ` nobu (Nobuyoshi Nakada)
  0 siblings, 0 replies; 2+ messages in thread
From: nobu (Nobuyoshi Nakada) @ 2021-12-26  4:51 UTC (permalink / raw)
  To: ruby-dev

Issue #18433 has been updated by nobu (Nobuyoshi Nakada).


忘れてました。
予定は未定ということで、3.2になったら消します(たぶん)。

----------------------------------------
Bug #18433: 「‘rb_cData’ is deprecated: by: rb_cObject.  Will be removed in 3.1.」が 3.1 でも出力される
https://bugs.ruby-lang.org/issues/18433#change-95634

* Author: tommy (Masahiro Tomita)
* Status: Open
* Priority: Normal
* ruby -v: ruby 3.1.0p0 (2021-12-25 revision fb4df44d16) [x86_64-linux]
* Backport: 2.6: UNKNOWN, 2.7: UNKNOWN, 3.0: UNKNOWN
----------------------------------------
拡張ライブラリ内で rb_cData を使うと
```
‘rb_cData’ is deprecated: by: rb_cObject.  Will be removed in 3.1.
```
という warning が出力されますが、これが 3.1 でも出ます。
別に害はないのですが、メッセージとしては妙な感じです。

```
/tmp/hoge% cat hoge.c 
#include <ruby.h>
void Init_hoge(void)
{
  rb_cData;
}

/tmp/hoge% cat extconf.rb 
require 'mkmf'
create_makefile('hoge')

/tmp/hoge% ruby -v extconf.rb 
ruby 3.1.0p0 (2021-12-25 revision fb4df44d16) [x86_64-linux]
creating Makefile

/tmp/hoge% make
compiling hoge.c
hoge.c: In function ‘Init_hoge’:
hoge.c:4:3: warning: ‘rb_cData’ is deprecated: by: rb_cObject.  Will be removed in 3.1. [-Wdeprecated-declarations]
    4 |   rb_cData;
      |   ^~~~~~~~
In file included from /home/tommy/ruby31/include/ruby-3.1.0/ruby/internal/core.h:27,
                 from /home/tommy/ruby31/include/ruby-3.1.0/ruby/ruby.h:28,
                 from /home/tommy/ruby31/include/ruby-3.1.0/ruby.h:38,
                 from hoge.c:1:
/home/tommy/ruby31/include/ruby-3.1.0/ruby/internal/core/rdata.h:382:1: note: declared here
  382 | rb_cData(void)
      | ^~~~~~~~
hoge.c: At top level:
cc1: note: unrecognized command-line option ‘-Wno-self-assign’ may have been intended to silence earlier diagnostics
cc1: note: unrecognized command-line option ‘-Wno-parentheses-equality’ may have been intended to silence earlier diagnostics
cc1: note: unrecognized command-line option ‘-Wno-constant-logical-operand’ may have been intended to silence earlier diagnostics
linking shared-object hoge.so
/tmp/hoge% 
```



-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-12-26  4:52 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-26  3:07 [ruby-dev:51128] [Ruby master Bug#18433] 「‘rb_cData’ is deprecated: by: rb_cObject. Will be removed in 3.1.」が 3.1 でも出力される tommy (Masahiro Tomita)
2021-12-26  4:51 ` [ruby-dev:51129] " nobu (Nobuyoshi Nakada)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).