Is the lcl_LocalFunction naming convention useful?

Bjoern Michaelsen bjoern.michaelsen at canonical.com
Tue Oct 9 01:08:39 PDT 2012


On Tue, Oct 09, 2012 at 08:59:47AM +0300, Tor Lillqvist wrote:
> Where did this lcl_ convention come from?

http://wiki.openoffice.org/wiki/Writer_Code_Conventions#free_functions_and_methods

> The lcl_ prefix has no meaning to a compiler or linker. If the intent is to
> make such functions file-local, why not use the static keyword, or an
> anonymous namespace instead, so that they actually *are* local also to the
> tool-chain? (You can still keep the lcl_ prefix if you love it.)

Yes, those functions should be anonymous and static. When I write that page
above back in the days, I was just documenting what was there (hoping it would
improve consistancy), in this case I am not finding that convention to have a
deep purpose(*), though it might help some for tools like simple code-completion
or doxygen-style docs ...

Best,

Bjoern

(*) So its mostly: "any color you like as long as it's black".


More information about the LibreOffice mailing list