Show
Ignore:
Timestamp:
04/16/08 15:36:30 (20 months ago)
Author:
mpaschal
Message:

Land the new implementation of metadata based on narrow tables
BugzID: 68749

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • branches/release-35/lib/MT.pm.pre

    r1871 r1927  
    5858            no strict 'refs'; 
    5959            unless ( defined *{ $compat . '::' } ) { 
    60                 eval "require $compat;"; 
     60                eval "# line " . __LINE__ . " " . __FILE__ . "\nrequire $compat;"; 
    6161            } 
    6262        } 
     
    267267        return $object_types{$k} if exists $object_types{$k}; 
    268268 
     269        if ($k =~ m/^(.+):meta$/) { 
     270            my $ppkg = $pkg->model($1); 
     271            my $mpkg = $ppkg->meta_pkg; 
     272            return $mpkg ? $object_types{$k} = $mpkg : undef; 
     273        } 
     274 
    269275        my $model = $pkg->registry( 'object_types', $k ); 
    270276        if ( ref($model) eq 'ARRAY' ) { 
     
    287293        unless ( defined *{ $model . '::__properties' } ) { 
    288294            use strict 'refs'; 
    289             eval "require $model;"; 
     295            eval "# line " . __LINE__ . " " . __FILE__ . "\nrequire $model;"; 
    290296            if ( $@ && ( $k =~ m/^(.+)\./ ) ) { 
    291297 
     
    612618 
    613619    $cb->error();    # reset the error string 
    614     my $result = eval { $cb->invoke(@args) }; 
     620    my $result = eval { 
     621        # line __LINE__ __FILE__ 
     622        $cb->invoke(@args); 
     623    }; 
    615624    if ( my $err = $@ ) { 
    616625        $cb->error($err); 
     
    12621271                    $Plugins{$plugin_sig}{full_path} = $plugin_full_path; 
    12631272                    $timer->pause_partial if $timer; 
    1264                     eval { require $plugin }; 
     1273                    eval "# line " . __LINE__ . " " . __FILE__ . "\nrequire '$plugin';"; 
    12651274                    $timer->mark("Loaded plugin " . $sig) if $timer; 
    12661275                    if ($@) { 
     
    12701279                        # the database has been initialized... 
    12711280                        eval { 
     1281                            # line __LINE__ __FILE__ 
    12721282                            require MT::Log; 
    12731283                            $mt->log( 
     
    25882598            if ($method) { 
    25892599                return sub { 
    2590                     eval "require $hdlr_pkg;" 
     2600                    eval "# line " . __LINE__ . " " . __FILE__ . "\nrequire $hdlr_pkg;" 
    25912601                      or Carp::confess( 
    25922602                        "failed loading package $hdlr_pkg for routine $name: $@"); 
     
    25992609            else { 
    26002610                return sub { 
    2601                     eval "require $hdlr_pkg;" 
     2611                    eval "# line " . __LINE__ . " " . __FILE__ . "\nrequire $hdlr_pkg;" 
    26022612                      or Carp::confess( 
    26032613                        "failed loading package $hdlr_pkg for routine $name: $@"); 
     
    26132623        } 
    26142624        else { 
    2615             eval "require $hdlr_pkg;" 
     2625            eval "# line " . __LINE__ . " " . __FILE__ . "\nrequire $hdlr_pkg;" 
    26162626              or Carp::confess( 
    26172627                "failed loading package $hdlr_pkg for routine $name: $@");