XS::MRO::Compat - Provides mro functions for XS modules
This document describes XS::MRO::Compat version 0.14.
# In your XS distribution use inc::Module::Install; # Add the following to your Makefile.PL use_ppport; requires_xs 'XS::MRO::Compat'; # see Module::Install::XSUtil /* Then put the "include" directive in your Module.xs */ /* ... */ #include "ppport.h" #include "mro_compat.h" /* Now you can use several mro functions in your Module.xs: mro_get_linear_isa() mro_get_pkg_gen() mro_method_changed_in() */ # And use XS::MRO::Compat in your module use XS::MRO::Compat;
XS::MRO::Compat provides several mro functions for XS modules.
XS::MRO::Compat
This feature is provided by Module::Install::XSUtil.
Module::Install::XSUtil
The same as mro::get_linear_isa() in Perl.
mro::get_linear_isa()
In 5.10 or later, it is just a public Perl API.
In 5.8.x, it calls mro::get_linear_isa provided by MRO::Compat. It has a cache mechanism as Perl 5.10 does, so it is much faster than the direct call of mro::get_linear_isa provided by MRO::Compat.
mro::get_linear_isa
MRO::Compat
The same as mro::method_changed_in() in Perl.
mro::method_changed_in()
The same as mro::get_pkg_gen() in Perl. This is not a Perl API.
mro::get_pkg_gen()
This may evaluate stash more than once.
Perl 5.8.1 or later, and a C compiler.
No bugs have been reported.
Please report any bugs or feature requests to the author.
Goro Fuji(gfx) <gfuji(at)cpan.org>.
mro.
"MRO Functions" in perlapi.
MRO::Compat.
Module::Install::XSUtil.
Copyright (c) 2008-2009, Goro Fuji (gfx). Some rights reserved.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install XS::MRO::Compat, copy and paste the appropriate command in to your terminal.
cpanm
cpanm XS::MRO::Compat
CPAN shell
perl -MCPAN -e shell install XS::MRO::Compat
For more information on module installation, please visit the detailed CPAN module installation guide.