comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Time to Fish or Cut Bait
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Time to Fish or Cut Bait [message #74835 is a reply to message #74711] Wed, 02 February 2011 20:21 Go to previous message
penteado is currently offline  penteado
Messages: 866
Registered: February 2018
Senior Member
Administrator
On Feb 3, 1:29 am, Jeremy Bailin <astroco...@gmail.com> wrote:
> I can see the argument, but I think the dominant convention is that the namespace comes at the beginning (how many people regularly use mg_... routines? and I certainly have lots of jb... calls in my code, whether or not anyone else does!). So I think convention comes first in this case.
>
> As for FSC_ vs. cg, I don't think cg is really much better, but I also don't really mind the change. What did FSC stand for anyways?

I use a prefix (pp_) for code I create. I only use a suffix (_pp) in
the very specific case of wrappers or edits I did to code written by
others (as in histogram_pp), so that it is clear that it is only a
small modification to something I did not write. Also, it keeps the
modification next to the original code alphabetically.

Besides being the common practice, and keeping a library's files
together alphabetically, prefixes make more obvious a name hierarchy:
first comes the root level (the developer or library name), which may
contain subgroups (the category of routine), which contain individual
routines.

I have not yet put my code into categories (which in hindsight I find
would have been good in some projects), so there is only the prefix
and the routine name (as in pp_isnumber). ITTVIS uses categories after
their prefix (as in IDLffShape and IDLanROI).
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Envi_get_slice error (subscript range error)
Next Topic: automatically changing focus to x-window /command line

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Thu Oct 09 13:18:00 PDT 2025

Total time taken to generate the page: 0.47865 seconds