>>>>> "K" == Kent Dahl <kentda / stud.ntnu.no> writes: K> Does this mean it was GC'd or something, while I wasn't looking? yes, K> Now, first I did this: K> rb_define_readonly_variable("$STATICEXT", &rb_static_ext_hash ); K> in Init_load in eval.c. K> I'd assume that this variable now was accessible to my scripts, but it K> just returns nil. It must work pigeon% diff -u eval.c~ eval.c --- eval.c~ Sun Nov 18 12:47:14 2001 +++ eval.c Sat Dec 8 16:43:00 2001 @@ -6006,6 +6006,7 @@ } VALUE rb_f_autoload(); +static VALUE rb_tt; void Init_load() @@ -6018,6 +6019,9 @@ rb_features = rb_ary_new(); rb_define_readonly_variable("$\"", &rb_features); + rb_tt = rb_hash_new(); + rb_define_readonly_variable("$TT", &rb_tt); + rb_define_global_function("load", rb_f_load, -1); rb_define_global_function("require", rb_f_require, 1); rb_define_global_function("autoload", rb_f_autoload, 2); pigeon% pigeon% ruby -e 'p $TT' {} pigeon% K> (Both with and without the K> rb_global_variable(&rb_static_ext_hash) line too.) You don't need rb_global_variable() if you use rb_define_readonly_variable() Guy Decoux