logo       

Re: RFC: Possibly cleaner output for DBIC::Schema::Loader dumps: msg#00193

Subject: Re: RFC: Possibly cleaner output for DBIC::Schema::Loader dumps
On 7/21/06, Brandon Black <blblack@xxxxxxxxx> wrote:
> I'm not sure how I feel on this.  I haven't ever noticed this
> technique before.  My gut feeling is that I don't particularly like
> it, even though it does free up some line length.  I suspect there are
> cases where $pkg just can't replace __PACKAGE__, although probably not
> in this set of output :)

I only use it on my schema classes, where usually you'll have a lot of
__PACKAGE__ statements and its "format" won't change a lot.

> I don't actually use Schema::Loader on my own projects anymore, and
> haven't in quite some time, so I don't really have much personal stake
> in these things.

Well, I currently use Schema::Loader for its code generation
abilities. Due to my database modeling background I'm *really* used to
creating/altering tables using a visual tool. Thus, it's something
pretty handy for me if I'm able to create some tables on the database
and then have myapp_create.pl generate the schema classes. In fact, I
only really started using Schema::Loader recently, when I looked at a
more recent version and found out about "create=static".

> Things like using qw// where appropriate, and single-quotes where
> appropriate too.  Then again, I feel anyone who cares that much will
> probably just do a series of mechanical cleanups on their own source
> after generating.

Well, I still think that trying to improve it somehow will at least
make it an easier task to cleanup. I think the current output is
pretty sane. I just, honestly, truly, hate __PACKAGE__. It's probably
the ugliest thing in Perl, IMO. But, of course, this is just a
personal aesthetic preference. ;-)

I'll see if I can came up with two separate patches later: one with
line breaks and comments and another with __PACKAGE__  -> $pkg change.
And then you choose if you'll apply anything at all be either both of
them or only the line breaks + comments one.

-Nilson Santos F. Jr.



<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
science.linguis...    culture.sf.lite...    video.mplayer.c...    yellowdog.gener...    ietf.rfc822/199...    emacs.help/2002...    redhat.release....    kernel.speakup/...    java.openejb.de...    debian.devel.gt...    xfree86.newbie/...    bug-tracking.ma...    pam/2003-05/msg...    games.devel.ope...    user-groups.lin...    music.pancham/2...    network.mq.deve...    web.html.genera...    arklinux.bugs/2...    linux.ecasound/...    qnx.openqnx.dev...    org.user-groups...    file-systems.sf...    trustix.contrib...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe