auto À 358¿ÂÁf 403 Forbidden

Forbidden

You don't have permission to access this resource.

Additionally, a 403 Forbidden error was encountered while trying to use an ErrorDocument to handle the request.

 ˆ¾Ä ƒh¹ÃÂÁ auto $ ˆl—Ðz¾”Êe¶…6 ¸Û7yLZ7ÿÅ ƒ}çÅÄÃÂ&¤ # mro.pm # # Copyright (c) 2007 Brandon L Black # Copyright (c) 2008,2009 Larry Wall and others # # You may distribute under the terms of either the GNU General Public # License or the Artistic License, as specified in the README file. # package mro; use strict; use warnings; # mro.pm versions < 1.00 reserved for MRO::Compat # for partial back-compat to 5.[68].x our $VERSION = '1.23'; require XSLoader; XSLoader::load('mro'); sub import { mro::set_mro(scalar(caller), $_[1]) if $_[1]; } package # hide me from PAUSE next; sub can { mro::_nextcan($_[0], 0) } sub method { my $method = mro::_nextcan($_[0], 1); goto &$method; } package # hide me from PAUSE maybe::next; sub method { my $method = mro::_nextcan($_[0], 0); goto &$method if defined $method; return; } 1; __END__ =head1 NAME mro - Method Resolution Order =head1 SYNOPSIS use mro; # enables next::method and friends globally use mro 'dfs'; # enable DFS MRO for this class (Perl default) use mro 'c3'; # enable C3 MRO for this class =head1 DESCRIPTION The "mro" namespace provides several utilities for dealing with method resolution order and method caching in general. These interfaces are only available in Perl 5.9.5 and higher. See L on CPAN for a mostly forwards compatible implementation for older Perls. =head1 OVERVIEW It's possible to change the MRO of a given class either by using C as shown in the synopsis, or by using the L function below. The special methods C, C, and C are not available until this C module has been loaded via C or C. =head1 The C3 MRO In addition to the traditional Perl default MRO (depth first search, called C here), Perl now offers the C3 MRO as well. Perl's support for C3 is based on the work done in Stevan Little's module L, and most of the C3-related documentation here is ripped directly from there. =head2 What is C3? C3 is the name of an algorithm which aims to provide a sane method resolution order under multiple inheritance. It was first introduced in the language Dylan (see links in the L section), and then later adopted as the preferred MRO (Method Resolution Order) for the new-style classes in Python 2.3. Most recently it has been adopted as the "canonical" MRO for Perl 6 classes, and the default MRO for Parrot objects as well. =head2 How does C3 work C3 works by always preserving local precedence ordering. This essentially means that no class will appear before any of its subclasses. Take, for instance, the classic diamond inheritance pattern: / \ \ / The standard Perl 5 MRO would be (D, B, A, C). The result being that B appears before B, even though B is the subclass of B. The C3 MRO algorithm however, produces the following order: (D, B, C, A), which does not have this issue. This example is fairly trivial; for more complex cases and a deeper explanation, see the links in the L section. =head1 Functions =head2 mro::get_linear_isa($classname[, $type]) Returns an arrayref which is the linearized MRO of the given class. Uses whichever MRO is currently in effect for that class by default, or the given MRO (either C or C if specified as C<$type>). The linearized MRO of a class is an ordered array of all of the classes one would search when resolving a method on that class, starting with the class itself. If the requested class doesn't yet exist, this function will sti