On 11/21/05, Kieren Diment <[EMAIL PROTECTED]> wrote: > > On 19 Nov 2005, at 04:11, David Baird wrote: > > > On 11/16/05, Kieren Diment <[EMAIL PROTECTED]> wrote: > >> So the generic BeerDB looks like this: > >> > >> package BeerDB; > >> [snip] ...BeerDB::Pub->has_many(beers => [ BeerDB::Handpump => > >> 'beer' ]); > >> # ^^^ dies here > >> BeerDB::Beer->has_many(pubs => [ BeerDB::Handpump => 'pub' ]); > >> 1; > >> > > > > No. This error means you have a bare string, and you need to put it in > > quotes. Theoretically, the => should automagically enquote the string > > to its left, but in certain versions of Perl, I've seen this fail. So > > say "BeerDB::Handpump" instead of BeerDB::Handpump > > > > > Cheers. I"ll file that on RT. There are a couple of places in the > docs where the coding style could be clearer. This is one. >
I've got some code that turns snippets like this: my $rels = <<RELS; pattern <<-- pattern_category -->> category pattern <<-- pattern_source -->> source source <<-- source_author -->> author source --> website source --> book RELS into CDBI relationships (many_many, has_many, has_a). Don't know if I think it looks weird and hacky or what. Anyone like the looks of it? d. ------------------------------------------------------- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_idv28&alloc_id845&op=click _______________________________________________ Maypole-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/maypole-devel
