mrilu <mrilu / ale.cx> writes:

> Is there any idea to define _Foo to be as good class name as Foo? 
> Maybe this could be accomplished by stripping leading _ before 
> determining name applicability for class/method/constant/module/variable.

Ruby defines an underscore to be a lowercase letter, so this would
cause problems.

> Came up with this when tried to use some _C_code with this common, 
> yet ugly, prefixing idiom. I think one should provide clean interface Foo
> which calls _Foo_in_ugly_c. 

You could do this for yourself by adding 'method_missing' to your
target class, and simply reissuing the call after stripping the
leading underscore. You could make this behavior a module and mix it
in to classes you wanted to behave this way.


Regards


Dave