From: ngotogenome@... Date: 2015-12-21T09:38:05+00:00 Subject: [ruby-dev:49448] [Ruby trunk - Bug #11853] [Open] "variable.c line 43: warning: modification of typedef with int ignored" on Solaris Issue #11853 has been reported by Naohisa Goto. ---------------------------------------- Bug #11853: "variable.c line 43: warning: modification of typedef with int ignored" on Solaris https://bugs.ruby-lang.org/issues/11853 * Author: Naohisa Goto * Status: Open * Priority: Normal * Assignee: * ruby -v: - * Backport: 2.0.0: UNKNOWN, 2.1: UNKNOWN, 2.2: UNKNOWN ---------------------------------------- おそらく r50678 以降、Solaris 10 上の Oracle Solaris Studio 12.x にて、以下のWarningが出ています。 ~~~ "variable.c", line 43: warning: modification of typedef with "int" ignored (E_MODIFY_TYPEDEF_IGNORED) ~~~ 該当行周辺は以下のとおりです。(先頭コメントは行番号) ~~~ /* 37: */ struct ivar_update { /* 38: */ union { /* 39: */ st_table *iv_index_tbl; /* 40: */ struct gen_ivtbl *ivtbl; /* 41: */ } u; /* 42: */ st_data_t index; /* 43: */ int extended; /* 44: */ }; ~~~ cc -E でプリプロセッサ出力を出して調べてみると、 標準ヘッダ /usr/include/floatingpoint.h (/usr/include/math.h 内から #include されている) の以下の記述と衝突していることがわかりました。 ~~~ typedef unsigned extended[3]; ~~~ Illumos (旧OpenSolaris)でも同様のようです。 https://github.com/illumos/illumos-gate/blob/master/usr/src/head/floatingpoint.h#L84 幸い、元の構造体は variable.c 内部でしか使われていないので、 メンバ名を変更するだけで良さそうです。 -- https://bugs.ruby-lang.org/