Re: Naming of private functions

From: Derek (me_at_nowhere.special.com)
Date: 02/05/04


Date: Thu, 05 Feb 2004 14:58:38 -0500

Victor Bazarov wrote:
> Naming conventions are intended to give the reader a way
> to quickly understand something about the symbol, in your
> case it is probably the fact that the function is (a) a
> member and (b) a public or private/protected one. If in
> your project the access rights to the symbol make such
> a difference as to justify having a different naming
> convention for the functions, then the difference is only
> known to those who are involved in the project...

This a company-wide C++ naming rule. It applies to all
projects, from low-level system code to application-level
GUI code. There is no domain-, industry-, or project
specific need for it that I can see.

> Then you have to talk to those who established such
> naming convention.

As I said in my original post, they offer hand-waving and
"gut feelings" in the way of explanation. They just "like
it" and aren't sure who originally proposed it way back
when. They can't justify it rationally to me, which is why
I turned to this broader forum for opinions.

> And unless one of your colleagues reads this NG as well,
> you're better off off-line. Without seeing more of the
> code or even working on it for some time, how could any
> of us successfully guess the intentions of the author of
> the convention?

Again, there is no resident author the other developers
are just "used to it." I've been working with the code
for months with no clear benefit in sight. My goal wasn't
to solicit a psychic reading; just to possibly hear from
someone who can offer an objective justification for this
peculiar naming scheme.

> I can't say that I've _used_ such convention, but there
> is probably something there, otherwise why would people
> keep using it? But, alas, I can't say I see it. :-)

I can't see the benefit either. As for why they keep using
it, my theory is that it's a misguided convention (akin to
that used to differentiate access for data members) that
got used, gained critical mass, and now everyone keeps
doing it for no reason other than to keep the code looking
consistent. :)



Relevant Pages

  • Re: How to name variables in a program?
    ... The Java naming convention is pretty good on this. ... the symbol is with the first letter capitalized, ... I would also *HIGHLY* warn you against the hungarian notation. ...
    (comp.programming)
  • Re: Naming Standard
    ... The RVBA (Reddick VBA) naming conventions are available ... > Convention, derived from the Leszynski*-Reddick Naming Convention for ... > Microsoft has something on this in the Knowledge Base, ...
    (microsoft.public.access.gettingstarted)
  • Re: Questions about app design - OOP with python classes
    ... It's unreliable in the sense that the coder has to follow the naming ... convention, and must have some bare minimum of sense. ... I'd have expected the compiler to handle the conversions through casts ...
    (comp.lang.python)
  • Re: great idea -- explain own bids
    ... naming a convention is not illegal, ... give full disclosure. ... experienced players, you can just say "Inverted", the opps nod ...
    (rec.games.bridge)
  • Re: Scenes from the Thugocracy
    ... Interesting how Tea Party folks never used kids as human shields. ... After coming to the top of the escalator at the DC Convention Center's ... Shockingly the protesters had purposely placed two ... that's how the leftists in the Occupy movement justify themselves too. ...
    (rec.arts.tv)