Hello all,

This is a summary for last week on the ruby-dev mailing list.


  [ruby-dev:19383] detecting features in extconf.rb

Nobu Nakada indicated pitfalls to write extconf.rb.

  * respond_to? should not be used. It may not work
    for cross compilation.
  * egrep_cpp always fails without egrep.
  * library names are not identical in any platform.
    They can vary by configuration.


  [ruby-dev:19410] match of [\001]

WATANABE Tetsuya pointed out that /[\001]/ does not 
match strings including "\001" in Ruby 1.8.0 when
$KCODE is not 'n'.  Matz replied that numerical notation
of Ruby's Regexp matched a part of multibyte characters.
In future, this specification will be deprecated,
though it's feature for now.


  [ruby-dev:19387] standard ruby lib coding convension

NaHi asked to Matz for coding convension for standard
ruby library. Matz recommended to:

  * use two-space indentation, no TABs
  * use RDoc
  * use camelCase for variable names and method names
  * use camelCase for class names and module names
  * use upper case separated by '_' for constants


  [ruby-dev:19406] [Oniguruma] Version 1.6

Kosako released new version of Oniguruma (yet another
Regexp library for Ruby).

    * supported Win32(VC++)
    * fixed bugs of POSIX API
    * improved speed


  [ruby-dev:19423] Numeric#quo

Matz announced that he implemented quotient method
Numric#quo. This method returns accurate value
as much as possible, using class Rational.

  ex. 3.quo(2) => 3/2 (Rational)

There are some issues remained.

 * Is the method name 'quo' appropriate?
 * Should we make Rational into standard?
 * Does int.quo(float) and rational.quo(float) return
   Rational or Float?
  

  [ruby-dev:19430] HAVE_* macros

Akinori MUSHA proposed to add symbols to ruby.h and intern.h,
which represent version depending features, not to need
detecting them in each extconf.rb.  Matz agreed the idea
itself, but disliked some names he showed.

  #define HAVE_RB_DEFINE_ALLOC_FUNC
  #define HAVE_RB_CVAR_SET_WITH_WARN

  #define HAVE_1ARY_NORETURN

  or

  #define RUBY_NORETURN_STYLE 0 /* prototype NORETURN; */
  #define RUBY_NORETURN_STYLE 1 /* NORETURN(prototype); */

  or

  #define RUBY_NORETURN_STYLE_xxxx


Regards,

TAKAHASHI 'Maki' Masayoshi     E-mail: maki / rubycolor.org