Size of st_data_t

e\$B\$3\$s\$K\$A\$O!"\$J\$+\$`\$ie(B(e\$B\$&e(B)e\$B\$G\$9!#e(B

st.he\$B\$NCf\$K!“e(B
typedef unsigned long st_data_t;
e\$B\$H\$\$\$&5-=R\$,\$”\$j\$^\$9\$,!“e(Brubye\$BK\BN\$N%3!<%I\$K\$Oe(Bst_data_te\$B\$,e(BVALUE
e\$B\$HF1\$8Bg\$-\$5\$G\$”\$k\$3\$H\$r4|BT\$9\$k5-=R\$,B??t\$"\$j\$^\$9!#e(B

e\$B\$7\$+\$7!"@\$\$NCf\$K\$Oe(BVALUEe\$B\$,e(Bunsigned
longe\$B\$G\$O\$J\$\$4D6-\$b\$"\$C\$F!"e(B
e\$B\$3\$l\$,860x\$GF0:n\$5\$;\$k\$3\$H\$,\$G\$-\$^\$;\$s!#e(B
e\$B\$I\$&\$7\$?\$b\$N\$G\$7\$g\$&e(B?

e\$B\$=\$l\$G\$O!#e(B

e\$B\$^\$D\$b\$He(B e\$B\$f\$-\$R\$m\$G\$9e(B

In message “Re: [ruby-dev:28988] size of st_data_t”
on Sun, 9 Jul 2006 00:45:31 +0900, “U.Nakamura”
[email protected] writes:

|st.he\$B\$NCf\$K!“e(B
| typedef unsigned long st_data_t;
|e\$B\$H\$\$\$&5-=R\$,\$”\$j\$^\$9\$,!“e(Brubye\$BK\BN\$N%3!<%I\$K\$Oe(Bst_data_te\$B\$,e(BVALUE
|e\$B\$HF1\$8Bg\$-\$5\$G\$”\$k\$3\$H\$r4|BT\$9\$k5-=R\$,B??t\$“\$j\$^\$9!#e(B
|
|e\$B\$7\$+\$7!”@\$\$NCf\$K\$Oe(BVALUEe\$B\$,e(Bunsigned longe\$B\$G\$O\$J\$\$4D6-\$b\$"\$C\$F!"e(B
|e\$B\$3\$l\$,860x\$GF0:n\$5\$;\$k\$3\$H\$,\$G\$-\$^\$;\$s!#e(B
|e\$B\$I\$&\$7\$?\$b\$N\$G\$7\$g\$&e(B?

e\$B0lHV4JC1\$J\$N\$Oe(Bst_data_te\$B\$re(Bvoid*e\$B\$K\$7\$F\$7\$^\$&\$3\$H\$J\$s\$G\$9\$,!“Bge(B
e\$BNL\$Ne(Bwarninge\$B\$,=P\$k\$3\$H\$K\$J\$j\$^\$9\$M\$(!#%]%\$%s%?\$HF1\$8%5%\$%:\$Ne(B
e\$B@0?t\$r%]!<%?%V%k\$KF@\$kJ}K!\$,\$”\$l\$P4JC1\$J\$N\$G\$9\$,!#e(B

C99e\$B\$“\$?\$j\$J\$i\$”\$j\$=\$&!)e(B

e\$B\$^\$D\$b\$He(B e\$B\$f\$-\$R\$m\$G\$9e(B

In message “Re: [ruby-dev:28989] Re: size of st_data_t”
on Sun, 9 Jul 2006 01:38:24 +0900, Yukihiro M.
[email protected] writes:

|e\$B0lHV4JC1\$J\$N\$Oe(Bst_data_te\$B\$re(Bvoid*e\$B\$K\$7\$F\$7\$^\$&\$3\$H\$J\$s\$G\$9\$,!“Bge(B
|e\$BNL\$Ne(Bwarninge\$B\$,=P\$k\$3\$H\$K\$J\$j\$^\$9\$M\$(!#%]%\$%s%?\$HF1\$8%5%\$%:\$Ne(B
|e\$B@0?t\$r%]!<%?%V%k\$KF@\$kJ}K!\$,\$”\$l\$P4JC1\$J\$N\$G\$9\$,!#e(B
|
|# C99e\$B\$“\$?\$j\$J\$i\$”\$j\$=\$&!)e(B

e\$B7k6I!"\$3\$s\$J46\$8\$G\$I\$&\$G\$7\$g\$&!#e(B

— st.h 14 Sep 2005 06:32:32 -0000 1.15
+++ st.h 8 Jul 2006 16:46:50 -0000
@@ -8,3 +8,10 @@

+#if SIZEOF_LONG == SIZEOF_VOIDP
typedef unsigned long st_data_t;
+#elif SIZEOF_LONG_LONG == SIZEOF_VOIDP
+typedef unsigned LONG_LONG st_data_t;
+#else
+# error ---->> st.c requires sizeof(void*) == sizeof(long) to be
compiled. <<—
±
+#endif
#define ST_DATA_T_DEFINED

e\$B\$3\$s\$K\$A\$O!"\$J\$+\$`\$ie(B(e\$B\$&e(B)e\$B\$G\$9!#e(B

In message “[ruby-dev:28990] Re: size of st_data_t”
on Jul.09,2006 01:47:02, [email protected] wrote:
| e\$B7k6I!"\$3\$s\$J46\$8\$G\$I\$&\$G\$7\$g\$&!#e(B

e\$B\$b\$A\$m\$s!"\$=\$l\$G\$\$\$\$\$H;W\$&\$s\$G\$9\$,!"e(Bst.[ch]e\$B\$,e(Brubye\$BK\BN\$N%3!<%Ie(B
e\$B\$K0MB8\$9\$k\$3\$H\$rHr\$1\$F\$k\$s\$8\$c\$J\$+\$C\$?\$G\$7\$?\$C\$1e(B?

e\$BKNIt\$5\$s\$,=q\$\$\$F\$*\$i\$l\$k\$h\$&\$Ke(Bintptr_te\$B\$,;H\$(\$l\$P\$\$\$\$\$s\$G\$9\$,!"e(B
C89(C90)e\$B\$K\$O\$J\$\$\$s\$G\$9\$h\$M\$(!#e(B

e\$B\$=\$l\$G\$O!#e(B

e\$BKNIt\$G\$9e(B

Yukihiro M. wrote:

C99e\$B\$"\$?\$j\$J\$i\$"\$j\$=\$&!)e(B

C99e\$B\$J\$ie(Bintptr_te\$B\$r;H\$(\$P\$h\$\$\$G\$7\$g\$&e(B(e\$B%5%\$%:\$,F1\$8\$H\$O7h\$^\$C\$F\$^\$;\$s\$,!"\$=e(B
e\$B\$NE@\$OLdBj\$G\$O\$J\$\$\$H;W\$\$\$^\$9e(B)e\$B!#e(B

e\$B\$^\$D\$b\$He(B e\$B\$f\$-\$R\$m\$G\$9e(B

In message “Re: [ruby-dev:28992] Re: size of st_data_t”
on Mon, 10 Jul 2006 05:04:51 +0900, “U.Nakamura”
[email protected] writes:

|| e\$B7k6I!“\$3\$s\$J46\$8\$G\$I\$&\$G\$7\$g\$&!#e(B
|
|e\$B\$b\$A\$m\$s!”\$=\$l\$G\$\$\$\$\$H;W\$&\$s\$G\$9\$,!"e(Bst.[ch]e\$B\$,e(Brubye\$BK\BN\$N%3!<%Ie(B
|e\$B\$K0MB8\$9\$k\$3\$H\$rHr\$1\$F\$k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B\$O\$:\$J\$N\$G!"e(Bconfig.he\$B\$,\$J\$/\$F\$bDL\$k\$H\$\$\$&\$3\$H\$G\$\$\$\$\$s\$8\$c\$J\$\$\$Ge(B
e\$B\$7\$g\$&\$+!#e(B

e\$B\$3\$s\$K\$A\$O!"\$J\$+\$`\$ie(B(e\$B\$&e(B)e\$B\$G\$9!#e(B

In message “[ruby-dev:28993] Re: size of st_data_t”
on Jul.10,2006 08:20:20, [email protected] wrote:
| e\$B\$=\$&\$J\$s\$G\$9\$h!#\$H\$O\$\$\$(!"LdBj\$N=EMW\$5\$r9M\$(\$k\$H>/\$J\$/\$H\$be(B
| config.he\$B\$K\$OMj\$i\$6\$k\$r\$(\$J\$\$5\$\$,\$7\$^\$9!#e(B

e\$B\$H\$\$\$&\$o\$1\$G!"F~\$C\$?\$N\$G;n\$7\$F\$_\$?\$H\$3\$m!“e(Bconfig.he\$B\$@\$1\$G\$OB-e(B
e\$B\$j\$F\$^\$;\$s\$G\$7\$?!#e(B
LONG_LONGe\$B\$NDj5A\$,\$”\$k\$N\$Oe(Bdefines.he\$B\$J\$N\$G!"e(Bst.ce\$B\$G\$Oe(Bdefines.he\$B\$be(B
e\$BI,MW\$K\$J\$j\$^\$9!#\$&!<\$s!#e(B

e\$B\$“\$H!“e(Bintern.he\$B\$K\$”\$ke(Bst_foreach_safee\$B\$N@k8@\$,e(Bhash.ce\$B\$K\$”\$kDj5A\$He(B
e\$B?)\$\$0c\$&\$3\$H\$K\$J\$k\$N\$G!"\$3\$l\$^\$?BP=h\$,I,MW\$K\$J\$j\$^\$9!#e(B

e\$B\$H\$\$\$&\$o\$1\$G!“%Q%C%A\$J\$s\$G\$9\$,!”\$3\$l\$G\$\$\$\$\$b\$N\$d\$i!#e(B

Index: intern.h

RCS file: /home/cvs/ruby/intern.h,v
retrieving revision 1.195
diff -u -1 -p -r1.195 intern.h
— intern.h 9 Jun 2006 21:20:12 -0000 1.195
+++ intern.h 10 Jul 2006 21:30:32 -0000
@@ -22,2 +22,3 @@
#endif
+#include <st.h>

@@ -316,3 +317,3 @@ VALUE rb_gc_start(void); /* hash.c / -void st_foreach_safe(struct st_table , int ()(ANYARGS), unsigned long); +void st_foreach_safe(struct st_table , int ()(ANYARGS), st_data_t); void rb_hash_foreach(VALUE, int ()(ANYARGS), VALUE); Index: st.c

RCS file: /home/cvs/ruby/st.c,v
retrieving revision 1.41
diff -u -1 -p -r1.41 st.c
— st.c 3 Jul 2006 20:07:09 -0000 1.41
+++ st.c 10 Jul 2006 21:30:32 -0000
@@ -14,2 +14,3 @@
#endif
+#include “defines.h”

e\$B\$=\$l\$G\$O!#e(B