[ruby-talk:02586] Re: Eat prefixing _ with names?

From: Yasushi Shoji <yashi@...>
Date: 2000-04-26 23:29:36 UTC
List: ruby-talk #2586
From: mrilu <mrilu@ale.cx>
Subject: [ruby-talk:02584] Eat prefixing _ with names?
Date: Thu, 27 Apr 2000 02:26:13 +0200 (CEST)

> 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.

IMVHO, '_' or '__' in C is used for kind of private functions.  OTOH,
class name is public thing.

[...]

> 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. 
> 
> I thought to rename my C-code, but don't know am I going around a good
> thing to have or just doing the Right Thing (tm).

if the c code is yours, i'd suggest renaming it if the function will
be exported.

regards,
--
            yashi

In This Thread

Prev Next