Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.perl.misc > #8807
| From | Rainer Weikusat <rweikusat@mssgmbh.com> |
|---|---|
| Newsgroups | comp.lang.perl.misc, comp.lang.perl.modules |
| Subject | Re: Foo::Bar::Libfoobar vs. Libfoobar? |
| Date | 2013-07-22 14:18 +0100 |
| Message-ID | <87bo5un36e.fsf@sapphire.mobileactivedefense.com> (permalink) |
| References | <87li4ztu17.fsf@violet.siamics.net> |
Cross-posted to 2 groups.
Ivan Shmakov <oneingray@gmail.com> writes: > I'm curious, what's the current preferred naming scheme for Perl > bindings to C libraries? Given such modules as GD or > Image::Magick, I'd assume that the bindings for Libfoobar are > ought to live in a module named Libfoobar. > > Somehow, however, I'd find it tempting to use a longer, yet more > descriptive, Foo::Bar::Libfoobar; especially if there's a > related Foo::Bar module already on CPAN, and that Foo::Bar would > be the "proper" name for Libfoobar, should it be (re)implemented > as a native Perl library. > > Perhaps there's anything else to consider? First, I would drop the lib-prefix: If it is a standalone Perl module, 'we' already know that it is a library and putting lib in front of the name is just keeping a convention of so dubious value alive that the linker has actually contained code to work around it 'for ages' (intepreting an argument a la -lbarfoo as request to link with a file named libbarfoo). For the remaining part "it depends": Is 'foobar' an 'unstructured' term in its own right or is 'foo' something which denotes a class of similar things with bar being a specimen belonging to it? For the former case, it should be Foobar, integrated in a suitable 'abstract top-level namespace' ie, Metasyntatic::Foobar, in the latter case, it should become Foo::Bar.
Back to comp.lang.perl.misc | Previous | Next — Previous in thread | Next in thread | Find similar
Foo::Bar::Libfoobar vs. Libfoobar? Ivan Shmakov <oneingray@gmail.com> - 2013-07-21 22:41 +0000
Re: Foo::Bar::Libfoobar vs. Libfoobar? George Mpouras <nospam.gravitalsun.noadsplease@hotmail.noads.com> - 2013-07-22 09:33 +0300
Re: Foo::Bar::Libfoobar vs. Libfoobar? Rainer Weikusat <rweikusat@mssgmbh.com> - 2013-07-22 14:18 +0100
Re: Foo::Bar::Libfoobar vs. Libfoobar? Ivan Shmakov <oneingray@gmail.com> - 2013-07-22 13:49 +0000
csiph-web